Doctrine 2 - ORM
  1. Doctrine 2 - ORM
  2. DDC-2188

DQL arithmetic priority is not considered in expression 'a/(b*c)'

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.3
    • Fix Version/s: 2.4
    • Component/s: DQL, ORM
    • Security Level: All
    • Labels:

      Description

      A DQL query that contains an arithmetic expression like 'a/(b*c)' will be compiled to 'a/b*c' in SQL and therefore the result of '100/(2*2)' will be 100, instead of 25.

      Note: I have tested it by mysql only

        Activity

        Mahdi Dehghani created issue -
        Benjamin Eberlei made changes -
        Field Original Value New Value
        Assignee Benjamin Eberlei [ beberlei ] Guilherme Blanco [ guilhermeblanco ]
        Fabio B. Silva made changes -
        Assignee Guilherme Blanco [ guilhermeblanco ] Fabio B. Silva [ fabio.bat.silva ]
        Benjamin Eberlei made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Fix Version/s 2.4 [ 10321 ]
        Resolution Fixed [ 1 ]

          People

          • Assignee:
            Fabio B. Silva
            Reporter:
            Mahdi Dehghani
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: