Doctrine 2 - ORM
  1. Doctrine 2 - ORM
  2. DDC-3

Support for CASE expressions in DQL

    Details

    • Type: Improvement Improvement
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.1
    • Fix Version/s: 2.2
    • Component/s: ORM
    • Security Level: All
    • Labels:
      None

      Description

      CASE expressions should be supported in DQL similarly to the definition found in 4.6.17.3 of the JPA 2.0 specification.

      Steps: 1) Adjust the BNF
      2) Adjust the Parser according to the changed BNF
      3) Adjust the SqlWalker? to produce the correct SQL

        Issue Links

          Activity

          Hide
          Roman S. Borschel added a comment -

          test

          Show
          Roman S. Borschel added a comment - test
          Hide
          Roman S. Borschel added a comment -

          The BNF and Parser has already been largely prepared for that.

          Show
          Roman S. Borschel added a comment - The BNF and Parser has already been largely prepared for that.
          Hide
          Guilherme Blanco added a comment -

          Added all Lexer keywords to it. It was breaking some use cases.

          Parsing can be easily done. How far is Walker generation far from an acceptable state?

          Show
          Guilherme Blanco added a comment - Added all Lexer keywords to it. It was breaking some use cases. Parsing can be easily done. How far is Walker generation far from an acceptable state?
          Hide
          Benjamin Eberlei added a comment -

          its a 2.1 change, so we can delay that for now or not? adding the keyword is a good idea though, maybe we should think about some other keywords that we potentially need in the future?

          Show
          Benjamin Eberlei added a comment - its a 2.1 change, so we can delay that for now or not? adding the keyword is a good idea though, maybe we should think about some other keywords that we potentially need in the future?
          Hide
          Roman S. Borschel added a comment -

          I will try to finish this for 2.1.

          Show
          Roman S. Borschel added a comment - I will try to finish this for 2.1.
          Show
          Guilherme Blanco added a comment - In this commit: https://github.com/doctrine/doctrine2/commit/816ce41f638d28934c79a12ef27f954124b2639e And documented in this commit: https://github.com/doctrine/orm-documentation/commit/189c729f15d2fafecf92662cad9553c2ec3dccd7 This support was FINALLY included. =)

            People

            • Assignee:
              Guilherme Blanco
              Reporter:
              Roman S. Borschel
            • Votes:
              2 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: