Doctrine 1
  1. Doctrine 1
  2. DC-49

Wrong query parameter order when using limit() on PostgreSQL

    Details

    • Type: Bug Bug
    • Status: Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: 1.1.4
    • Fix Version/s: None
    • Component/s: Query
    • Labels:
      None
    • Environment:
      latest doctrine 1.1 revision, linux x64, PostgeSQL 8.4, php 5.2.10

      Description

      Trying to add limit() to complex query with many where's and some joins. In pgsql it causes nested limit subquery and in some cases parameter order (when limit subquery exists params array just merges with itself, i. e. (1,2) becomes (1,2,1,2)) makes result query wrong, i. e. params array order doesn't correspond placeholders order in query.

      With named query parameters all ok.

      Testcase attached.

      1. Doctrine_Query_Abstract.diff
        0.6 kB
        Daniel Bojdo
      2. PostgresParamsBugTestCase.php
        4 kB
        Nicholas Kasyanov

        Activity

          People

          • Assignee:
            Guilherme Blanco
            Reporter:
            Nicholas Kasyanov
          • Votes:
            2 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated: