<!--
RSS generated by JIRA (5.2.7#850-sha1:b2af0c8dc8537b36121c6a579fabbdf79fc919e5) at Fri May 24 21:41:42 UTC 2013

It is possible to restrict the fields that are returned in this document by specifying the 'field' parameter in your request.
For example, to request only the issue key and summary add field=key&field=summary to the URL of your request.
For example:
http://www.doctrine-project.org/jira/sr/jira.issueviews:searchrequest-xml/temp/SearchRequest.xml?jqlQuery=project+%3D+DC+AND+fixVersion+%3D+%221.2.4%22+AND+resolution+%3D+Unresolved+ORDER+BY+due+ASC%2C+priority+DESC%2C+created+ASC&tempMax=1000&field=key&field=summary
-->
<!-- If you wish to do custom client-side styling of RSS, uncomment this:
<?xml-stylesheet href="http://www.doctrine-project.org/jira/styles/jiraxml2html.xsl" type="text/xsl"?>
-->
<rss version="0.92">
    <channel>
        <title>Doctrine Project</title>
        <link>http://www.doctrine-project.org/jira/secure/IssueNavigator.jspa?reset=true&amp;jqlQuery=project+%3D+DC+AND+fixVersion+%3D+%221.2.4%22+AND+resolution+%3D+Unresolved+ORDER+BY+due+ASC%2C+priority+DESC%2C+created+ASC</link>
        <description>An XML representation of a search request</description>
                <language>en-us</language>
                        <issue start="0" end="30" total="30"/>
                <build-info>
            <version>5.2.7</version>
            <build-number>850</build-number>
            <build-date>21-02-2013</build-date>
        </build-info>
<item>
            <title>[DC-701] Aggregates functions do not return proper values when using many relationships and limits</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-701</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;Hi All&lt;/p&gt;

&lt;p&gt;I have encountered a problem that seems very core to the way that doctrine works &amp;#8211; if you apply an aggregate function to a column in a table and then join to another table via a many relationship while also using a limit, like so:&lt;/p&gt;

&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;$q = Doctrine_Query::create();
$q-&amp;gt;from(&apos;Customer Customer&apos;); 
$q-&amp;gt;addSelect(&apos;COUNT(Customer.id) as COUNT_customer_id&apos;);
$q-&amp;gt;addSelect(&apos;Customer_Order.id as order_id&apos;); 
$q-&amp;gt;leftJoin(&apos;Customer.Order Customer_Order&apos;); &lt;span class=&quot;code-comment&quot;&gt;// Many relationship here
&lt;/span&gt;$q-&amp;gt;limit(20);
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;It produces this correct DQL:&lt;/p&gt;
&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;SELECT COUNT(Customer.id) as COUNT_customer_id, Customer_Order.id as order_id 
FROM Customer Customer 
  LEFT JOIN Customer.Order Customer_Order 
LIMIT 20
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;However the SQL it produces will not return an accurate count &amp;#8211; the count is restricted by the limit:&lt;/p&gt;

&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;SELECT COUNT(p.id) AS p__0, p2.id AS p2__1 
FROM product_customers p 
  LEFT JOIN product_orders p2 ON p.id = p2.customer_id 
WHERE p.id IN (&apos;1&apos;, &apos;2&apos;, &apos;3&apos;, &apos;4&apos;, &apos;5&apos;, &apos;6&apos;, &apos;7&apos;, &apos;8&apos;, &apos;9&apos;, &apos;10&apos;, &apos;11&apos;, &apos;12&apos;, &apos;13&apos;, &apos;14&apos;, &apos;15&apos;, &apos;16&apos;, &apos;17&apos;, &apos;18&apos;, &apos;19&apos;, &apos;20&apos;)
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;This produces a count of 21 instead of what it should be (1000).&lt;/p&gt;

&lt;p&gt;The reason for this is because Doctrine&apos;s internal functionality does an intermediary query where it gets gets the ids needed from the customer table in order to use them as the IN portion of the constraints on the final query &amp;#8211; like so:&lt;/p&gt;

&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;SELECT DISTINCT p3.id FROM product_customers p3 LIMIT 20
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;It may seem strange that I am applying a limit to a query which will aggregate to 1 to row . In the actual queries that alerted me to this problem I am using a group by. The reason I am not reporting this bug with a group by in my example however is that you can not use a group by with a many relationship and a limit in doctrine 1.2.2 as it works currently (see bug: &lt;a href=&quot;http://www.doctrine-project.org/jira/browse/DC-594&quot; title=&quot;When using a combination of: a group by field referencing a table in a relation, a join to a different table via a many type relation and a limit clause, doctrine creates a broken query then throws an exception&quot;&gt;&lt;del&gt;DC-594&lt;/del&gt;&lt;/a&gt;). However I am personally able to use a limit with a group by and many relationship since I am using a version of the code I patched my self to repair bug &lt;a href=&quot;http://www.doctrine-project.org/jira/browse/DC-594&quot; title=&quot;When using a combination of: a group by field referencing a table in a relation, a join to a different table via a many type relation and a limit clause, doctrine creates a broken query then throws an exception&quot;&gt;&lt;del&gt;DC-594&lt;/del&gt;&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Here is my sample schema in case its helpful.&lt;/p&gt;

&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;detect_relations: &lt;span class=&quot;code-keyword&quot;&gt;false&lt;/span&gt;
&lt;span class=&quot;code-keyword&quot;&gt;package&lt;/span&gt;: Example
options:
  type: INNODB
  charset: utf8
Order:
  tableName: orders
  columns:
    order_id:
      type: integer(4)
      primary: &lt;span class=&quot;code-keyword&quot;&gt;true&lt;/span&gt;
      notnull: &lt;span class=&quot;code-keyword&quot;&gt;true&lt;/span&gt;
    customer_id:
      type: integer(4)
    order_date: timestamp
  relations:
    Customer:
      type: one
      local: customer_id
      foreign: customer_id
  options:
    type: InnoDB
Customer:
  tableName: customers
  columns:
    customer_id:
      type: integer(4)
      primary: &lt;span class=&quot;code-keyword&quot;&gt;true&lt;/span&gt;
      notnull: &lt;span class=&quot;code-keyword&quot;&gt;true&lt;/span&gt;
      autoincrement: &lt;span class=&quot;code-keyword&quot;&gt;true&lt;/span&gt;
    firstname:
      type: string(45)
    lastname:
      type: string(45)
    streetaddress:
      type: string(45)
    city:
      type: string(45)
    state:
      type: string(45)
    postalcode:
      type: string(45)
  relations:
    Order:
      type: many
      local: customer_id
      foreign: customer_id
  options:
    type: InnoDB
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Thanks much.&lt;/p&gt;

&lt;p&gt;Will Ferrer&lt;/p&gt;

&lt;p&gt;&lt;sub&gt;edit: split SQL code to make the discussion readable without huge horizontal scrolling...&lt;/sub&gt;&lt;/p&gt;</description>
                <environment>XP Xamp</environment>
            <key id="11409">DC-701</key>
            <summary>Aggregates functions do not return proper values when using many relationships and limits</summary>
                <type id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/bug.png">Bug</type>
                                <priority id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/blocker.png">Blocker</priority>
                    <status id="4" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/reopened.png">Reopened</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="jwage">Jonathan H. Wage</assignee>
                                <reporter username="willf1976">will ferrer</reporter>
                        <labels>
                    </labels>
                <created>Mon, 24 May 2010 20:28:27 +0000</created>
                <updated>Mon, 1 Nov 2010 20:12:17 +0000</updated>
                                    <version>1.2.2</version>
                                <fixVersion>1.2.4</fixVersion>
                                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                        <comments>
                    <comment id="13153" author="jwage" created="Tue, 8 Jun 2010 10:27:47 +0000"  >&lt;p&gt;Is this still a problem? I am not sure if this can be patched easily. The limit subquery algorithm is flawed deeply but also a core part of the current way Doctrine 1 works.&lt;/p&gt;</comment>
                    <comment id="13237" author="willf1976" created="Tue, 8 Jun 2010 19:06:56 +0000"  >&lt;p&gt;Hi Jon&lt;/p&gt;

&lt;p&gt;This bug is still an issue for me but I think it may be VERY hard to patch since it seems very core to the way Doctrine 1 works.&lt;/p&gt;

&lt;p&gt;The project I am working on at the moment is a visual query builder that is highly reliant on Doctrine. In order to prevent users from making queries that would trigger this bug I am currently giving an alert when ever a query that would trigger this bug is created.&lt;/p&gt;

&lt;p&gt;It would be great if this were patchable but if not I should be able to get by.&lt;/p&gt;

&lt;p&gt;Does Doctrine 2 fix this problem?&lt;/p&gt;

&lt;p&gt;Thanks for the help.&lt;/p&gt;

&lt;p&gt;Will Ferrer&lt;/p&gt;</comment>
                    <comment id="13240" author="jwage" created="Tue, 8 Jun 2010 20:34:37 +0000"  >&lt;p&gt;In Doctrine 2 the limit subquery algorithm does not exist. It is now up to the developer to write the query to handle the scenario instead of Doctrine &quot;trying&quot; to automate it for you. Since the situation where it is needed it is so rare, and each case can be slightly different it is better to let the developer handle it in those cases.&lt;/p&gt;</comment>
                    <comment id="13241" author="willf1976" created="Tue, 8 Jun 2010 21:07:17 +0000"  >&lt;p&gt;Hi Jon&lt;/p&gt;

&lt;p&gt;Does that mean that Doctrine 2 can no longer intelligently handle limits with many relationships, and doesn&apos;t have the ability to hydrate a return with sub arrays in it for many relationships?&lt;/p&gt;

&lt;p&gt;Thanks again for your help.&lt;/p&gt;

&lt;p&gt;Will Ferrer&lt;/p&gt;</comment>
                    <comment id="13256" author="jwage" created="Wed, 9 Jun 2010 13:06:48 +0000"  >&lt;p&gt;That is correct. We do not automatically try and limit the relationships with a &quot;limit subquery&quot; as it causes more problems then it helps.&lt;/p&gt;</comment>
                    <comment id="13265" author="willf1976" created="Thu, 10 Jun 2010 05:05:53 +0000"  >&lt;p&gt;Hi Jon&lt;/p&gt;

&lt;p&gt;I was thinking about what you said here &amp;#8211; that the &quot;limit subquery&quot; causes more harm than good. It occur to me that I really do like being able to use this method (it comes in very handy very often) but some times it would really help to be able to turn it off (the bug in this thread is a good example such a time). So I figured why not just make an option to turn it off and have the best of both worlds? I looked at the code and found it was really very easy to put in a property which can be set on the query object to enable or disable the use of the limit subquery.&lt;/p&gt;

&lt;p&gt;I made the change in my code base and found it very useful for several situations I was dealing with in my own project.&lt;/p&gt;

&lt;p&gt;The one thing I couldn&apos;t do is make a test case for this new feature &amp;#8211; I couldn&apos;t find an existing test case that was actually triggering the limit subquery as I understood it to work (I couldn&apos;t find a test case that would put an WHERE IN constraint with all the ids gathered in the limit subquery.  I tried some test cases that I THOUGHT would activate this feature but it didn&apos;t seem that they did).&lt;/p&gt;

&lt;p&gt;After adding this feature to my code base I also wanted a new hydrator &amp;#8211; one that worked like scalar but would put in array key names that were the same as the ones you would see in HYDRATE_ARRAY. I noticed that HYDRATE_SCALAR already had the ability to do this but it required that a value of false be passed into the $aliasPrefix argument of the _gatherRowData function. I made a custom hydrator I call HYDRATE_ARRAY_SHALLOW that passes in this false value. I then realized this might be handy to add to doctrine so I integrated it into my code base and made a few test cases for it.&lt;/p&gt;

&lt;p&gt;There are 2 patches I am now attaching this to thread:&lt;/p&gt;

&lt;p&gt;disableLimitSubquery_2010-06-10_Doctrine_1.2_SVN.patch &amp;#8211; this patch adds the disableLimitSubquery property to query objects so that users can turn off the use of the subquery for those times when they don&apos;t want to use that behavior (fixing the bug in this thread and probably others)&lt;/p&gt;

&lt;p&gt;and&lt;/p&gt;

&lt;p&gt;disableLimitSubquery_and_HYDRATE_ARRAY_SHALLOW_2010-06-10_Doctrine_1.2_SVN.patch &amp;#8211; this is the same as the first patch but also contains the HYDRATE_ARRAY_SHALLOW hydration type I mentioned above (which tends to go well with disableLimitSubquery turned on).&lt;/p&gt;

&lt;p&gt;I put these in 2 patches incase you liked 1 feature but disliked the other.&lt;/p&gt;

&lt;p&gt;If you like either of this features I would be very happy to see them added to doctrine.&lt;/p&gt;

&lt;p&gt;Also if you have any advice on how to improve these features (or info on how to make a good test case for disableLimitSubquery) please let me know.&lt;/p&gt;

&lt;p&gt;Hope you are well.&lt;/p&gt;

&lt;p&gt;Will Ferrer&lt;/p&gt;</comment>
                    <comment id="13266" author="willf1976" created="Thu, 10 Jun 2010 05:07:31 +0000"  >&lt;p&gt;Reopened because I added a patch that I think in essence fixes the issues.&lt;/p&gt;</comment>
                    <comment id="14221" author="jwage" created="Wed, 1 Sep 2010 14:09:17 +0000"  >&lt;p&gt;Thanks for the issue and patches.&lt;/p&gt;

&lt;p&gt;Fixed here &lt;a href=&quot;http://github.com/doctrine/doctrine1/commit/2ad78e62e360133efc04bf6897bf679c7f3d833b&quot; class=&quot;external-link&quot;&gt;http://github.com/doctrine/doctrine1/commit/2ad78e62e360133efc04bf6897bf679c7f3d833b&lt;/a&gt;&lt;/p&gt;</comment>
                    <comment id="14228" author="willf1976" created="Wed, 1 Sep 2010 19:24:16 +0000"  >&lt;p&gt;individual patch for this issue with out other features included&lt;/p&gt;</comment>
                    <comment id="14655" author="willf1976" created="Mon, 1 Nov 2010 20:11:40 +0000"  >&lt;p&gt;adding test cases for these features&lt;/p&gt;</comment>
                    <comment id="14656" author="willf1976" created="Mon, 1 Nov 2010 20:12:17 +0000"  >&lt;p&gt;reopened because I posted some test cases to add to doctrine along with the patchs previously posted&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                    <attachment id="10835" name="DC_701_adds_disbaleLimitSubquery_testcase.patch" size="2398" author="willf1976" created="Mon, 1 Nov 2010 20:11:40 +0000" />
                    <attachment id="10836" name="DC_701_adds_hydrateArrayShallow_testcase.patch" size="2117" author="willf1976" created="Mon, 1 Nov 2010 20:11:40 +0000" />
                    <attachment id="10767" name="DC_701_fix_adds_arrayShallow.patch" size="7909" author="willf1976" created="Wed, 1 Sep 2010 19:24:16 +0000" />
                    <attachment id="10766" name="DC_701_fix_adds_disableLimitSubQuery.patch" size="2267" author="willf1976" created="Wed, 1 Sep 2010 19:24:16 +0000" />
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-791] [PostgreSQL] In case model is build from existing database sequence name is invalid and doctrine throw exception</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-791</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;Firstly I created database directly in postgresql.&lt;br/&gt;
After that I generated schema from existsing database and after all i built model.&lt;/p&gt;

&lt;p&gt;When I try to insert new record to database I received following error:&lt;/p&gt;

&lt;p&gt;sequence &quot;Category_id_seq&quot; does not exist&lt;/p&gt;

&lt;p&gt;In schema file sequence name is defined like this:  sequence: &apos;&quot;Address_id_seq&quot;&apos;&lt;br/&gt;
There&apos;s are apostrophes and quotes.&lt;/p&gt;

&lt;p&gt;In Category model file is same like above, apostrophes and quotes.&lt;/p&gt;

&lt;p&gt;When I remove quotes from sequence in model files everything is ok and there&apos;re no problems with insert new row to database.&lt;/p&gt;</description>
                <environment>symfony 1.4.5, postgresql 8.4, debian lenny, nginx</environment>
            <key id="11633">DC-791</key>
            <summary>[PostgreSQL] In case model is build from existing database sequence name is invalid and doctrine throw exception</summary>
                <type id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/bug.png">Bug</type>
                                <priority id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/blocker.png">Blocker</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="jwage">Jonathan H. Wage</assignee>
                                <reporter username="kacperix">Przemys&#322;aw Ci&#261;&#263;ka</reporter>
                        <labels>
                    </labels>
                <created>Fri, 16 Jul 2010 08:42:43 +0000</created>
                <updated>Wed, 25 Aug 2010 02:40:04 +0000</updated>
                                    <version>1.2.2</version>
                                <fixVersion>1.2.4</fixVersion>
                                <component>Schema Files</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                        <comments>
                    <comment id="13943" author="enrico" created="Fri, 13 Aug 2010 12:51:22 +0000"  >&lt;p&gt;There are 2 solutions to your problem. The first is to change the sequence name in the schema, the second is to change the doctrine configuration.&lt;/p&gt;

&lt;p&gt;The default behavior of doctrine is to add a &quot;_seq&quot; to each sequence name. If you remove this part from you sequence name then it sould work as expected. The second option is to change the behavior of doctrine with the following configuration parameter:&lt;/p&gt;

&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt; 
Doctrine_Manager::getInstance()-&amp;gt;setAttribute(Doctrine_Core::ATTR_SEQNAME_FORMAT, &apos;%s&apos;); 
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;b&gt;default:&lt;/b&gt; Doctrine_Manager::getInstance()-&amp;gt;setAttribute(Doctrine_Core::ATTR_SEQNAME_FORMAT, &apos;%s_seq&apos;); &lt;/p&gt;</comment>
                    <comment id="14063" author="kacperix" created="Wed, 25 Aug 2010 02:40:04 +0000"  >&lt;p&gt;Problem are quotes in sequence name.&lt;br/&gt;
Sequence names in schema built from existing database have quotes in their names, e.g &apos; &quot;Address_seq&quot; &apos; and Doctrine try to execute sequence with quotes but in database names exist without quotes.&lt;/p&gt;

&lt;p&gt;Temporarly I fixed it by add str_replace() into importer from PostgreSQL - now in schema sequence names are without quotes.&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                    <attachment id="10697" name="doctrine.png" size="40004" author="kacperix" created="Fri, 16 Jul 2010 08:42:43 +0000" />
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-1021] i am executing doctrine type query i am geting error  please gave me reply</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-1021</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;$query = new Doctrine_Query();&lt;br/&gt;
$query-&amp;gt;select(&apos;e.entity_name,e.entity_id,s.id,s.parent_id,e.ffc_entity_id,c.country_id,c.country_name&apos;)&lt;br/&gt;
//$query-&amp;gt;select(&apos;e.entity_name,e.entity_id,s.id,s.parent_id,e.ffc_entity_id,ea.Country&apos;)&lt;br/&gt;
-&amp;gt;from(&apos;Entities e&apos;)&lt;br/&gt;
-&amp;gt;leftJoin(&apos;e.EntityAddresses ea ON ea.entity_id = e.entity_id AND ea.address_type =&quot;M&quot;&apos;)&lt;br/&gt;
-&amp;gt;leftJoin(&apos;ea.Country c ON ea.country = c.country_id&apos;)&lt;br/&gt;
-&amp;gt;leftJoin(&apos;e.ActiveFactories s&apos;)&lt;br/&gt;
-&amp;gt;where(&apos;e.status=1&apos;);&lt;br/&gt;
if(!empty($alpha))&lt;br/&gt;
{&lt;br/&gt;
$query-&amp;gt;andWhere(&quot;e.entity_name like &apos;&quot;.$alpha.&quot;%&apos;&quot;);&lt;br/&gt;
}&lt;br/&gt;
$query-&amp;gt;andWhere(&quot;s.company_id=&quot;.$parentId)&lt;br/&gt;
-&amp;gt;andWhere(&quot;e.entity_type=2&quot;)&lt;br/&gt;
-&amp;gt;andWhere(&apos;s.status=1&apos;)&lt;br/&gt;
-&amp;gt;groupBy(&apos;e.entity_id&apos;);&lt;/p&gt;</description>
                <environment>windows ,wamp,php</environment>
            <key id="12849">DC-1021</key>
            <summary>i am executing doctrine type query i am geting error  please gave me reply</summary>
                <type id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/bug.png">Bug</type>
                                <priority id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/blocker.png">Blocker</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="jwage">Jonathan H. Wage</assignee>
                                <reporter username="rajani">cherukuri</reporter>
                        <labels>
                    </labels>
                <created>Sun, 24 Jul 2011 15:05:33 +0000</created>
                <updated>Sun, 24 Jul 2011 15:05:33 +0000</updated>
                                    <version>1.2.3</version>
                                <fixVersion>1.2.4</fixVersion>
                                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                                <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-1034] ORA-00904 in Doctrine_Connection_Oracle</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-1034</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;When i execute this code:&lt;/p&gt;
&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt; 
$q = Doctrine_Query::create()
            -&amp;gt;from(&apos;AGENT ag&apos;)
            -&amp;gt;leftJoin(&apos;ag.CHANTIER_AGENT cag)
            -&amp;gt;orderBy(&apos;ag.nom&apos;)
            -&amp;gt;limit(10)
            -&amp;gt;offset(10)
            -&amp;gt;execute();
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Doctrine executes :&lt;/p&gt;
&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt; 
SELECT a.pk AS a__pk, a.ts AS a__ts, a.ck_agent AS a__ck_agent, a.matricule AS a__matricule, a.nom AS a__nom, a.prenom AS a__prenom, a.agent_maitrise AS a__agent_maitrise, 
c.pk AS c__pk, c.ts AS c__ts, c.ck_chantier_agent AS c__ck_chantier_agent, c.ek_chantier AS c__ek_chantier, c.fk_chantier AS c__fk_chantier, c.ek_agent AS c__ek_agent, c.fk_agent AS c__fk_agent 
FROM AGENT a 
LEFT JOIN CHANTIER_AGENT c ON a.ck_agent = c.ek_agent 
WHERE a.ck_agent IN 
(SELECT b.ck_agent 
FROM ( SELECT a.*, ROWNUM AS doctrine_rownum 
FROM ( SELECT DISTINCT a2.ck_agent, a2.nom FROM AGENT a2 LEFT JOIN CHANTIER_AGENT c2 ON a2.ck_agent = c2.ek_agent ORDER BY a2.nom ) 
a2 ) 
b 
WHERE doctrine_rownum BETWEEN 11 AND 20) 
ORDER BY a.nom
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt; 

&lt;p&gt;The problem is in function _createLimitSubquery in Doctrine_Connection_Oracle :&lt;/p&gt;
&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt; 
                    $query= &apos;SELECT &apos;.$&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;quoteIdentifier(&apos;b&apos;).&apos;.&apos;.$column.&apos; FROM ( &apos;.
                                 &apos;SELECT &apos;.$&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;quoteIdentifier(&apos;a&apos;).&apos;.*, ROWNUM AS doctrine_rownum FROM ( &apos;
                                   . $query . &apos; ) &apos; . $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;quoteIdentifier(&apos;a&apos;) . &apos; &apos;.
                              &apos; ) &apos; . $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;quoteIdentifier(&apos;b&apos;) . &apos; &apos;.
                              &apos;WHERE doctrine_rownum BETWEEN &apos; . $min .  &apos; AND &apos; . $max;
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt; 

&lt;p&gt;Error occures, because table name is  AGENT and Doctrine give the first letter of the table name for identifier. &lt;br/&gt;
To correct this. Use more than one letter in the quoteIdentifier.&lt;/p&gt;
&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt; 
                    $query = &apos;SELECT &apos;.$&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;quoteIdentifier(&apos;limb&apos;).&apos;.&apos;.$column.&apos; FROM ( &apos;.
                                 &apos;SELECT &apos;.$&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;quoteIdentifier(&apos;lima&apos;).&apos;.*, ROWNUM AS doctrine_rownum FROM ( &apos;
                                   . $query . &apos; ) &apos; . $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;quoteIdentifier(&apos;lima&apos;) . &apos; &apos;.
                              &apos; ) &apos; . $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;quoteIdentifier(&apos;limb&apos;) . &apos; &apos;.
                              &apos;WHERE doctrine_rownum BETWEEN &apos; . $min .  &apos; AND &apos; . $max;
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt; </description>
                <environment>Windows 7 64 bits, PHP 5.2.11, Oracle Database 10g Enterprise Edition Release 10.2.0.5.0 - 64bi, Symfony 1.4.13&lt;br/&gt;
</environment>
            <key id="12987">DC-1034</key>
            <summary>ORA-00904 in Doctrine_Connection_Oracle</summary>
                <type id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/bug.png">Bug</type>
                                <priority id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/blocker.png">Blocker</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="jwage">Jonathan H. Wage</assignee>
                                <reporter username="jayson">Jayson LE PAPE</reporter>
                        <labels>
                    </labels>
                <created>Thu, 1 Sep 2011 08:43:20 +0000</created>
                <updated>Thu, 1 Sep 2011 08:43:20 +0000</updated>
                                    <version>1.2.4</version>
                                <fixVersion>1.2.4</fixVersion>
                                <component>Connection</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                                <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-1035] ORA-01791 due to bad driver name in Doctrine_Adapter_Oracle</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-1035</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;When i execute this code:&lt;/p&gt;
&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt; 
$q = Doctrine_Query::create()
            -&amp;gt;from(&apos;AGENT ag&apos;)
            -&amp;gt;leftJoin(&apos;ag.CHANTIER_AGENT cag)
            -&amp;gt;orderBy(&apos;ag.nom&apos;)
            -&amp;gt;limit(10)
            -&amp;gt;execute();
$q2 = Doctrine_Query::create()
            -&amp;gt;from(&apos;AGENT ag&apos;)
            -&amp;gt;leftJoin(&apos;ag.CHANTIER_AGENT cag)
            -&amp;gt;orderBy(&apos;ag.nom&apos;)
            -&amp;gt;limit(10)
            -&amp;gt;execute();
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Doctrine executes :&lt;/p&gt;
&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt; 
SELECT a.pk AS a__pk, a.ts AS a__ts, a.ck_agent AS a__ck_agent, a.matricule AS a__matricule, a.nom AS a__nom, 
a.prenom AS a__prenom, a.agent_maitrise AS a__agent_maitrise, c.pk AS c__pk, c.ts AS c__ts, c.ck_chantier_agent AS c__ck_chantier_agent, 
c.ek_chantier AS c__ek_chantier, c.fk_chantier AS c__fk_chantier, c.ek_agent AS c__ek_agent, c.fk_agent AS c__fk_agent 
FROM AGENT a 
LEFT JOIN CHANTIER_AGENT c ON a.ck_agent = c.ek_agent 
WHERE a.ck_agent IN (
SELECT a2.ck_agent FROM ( 
SELECT DISTINCT a2.ck_agent, a2.nom FROM AGENT a2 LEFT JOIN CHANTIER_AGENT c2 ON a2.ck_agent = c2.ek_agent ORDER BY a2.nom ) 
a2 WHERE ROWNUM &amp;lt;= 10) ORDER BY a.nom

SELECT a.pk AS a__pk, a.ts AS a__ts, a.ck_agent AS a__ck_agent, a.matricule AS a__matricule, a.nom AS a__nom, 
a.prenom AS a__prenom, a.agent_maitrise AS a__agent_maitrise, c.pk AS c__pk, c.ts AS c__ts, c.ck_chantier_agent AS c__ck_chantier_agent, 
c.ek_chantier AS c__ek_chantier, c.fk_chantier AS c__fk_chantier, c.ek_agent AS c__ek_agent, c.fk_agent AS c__fk_agent 
FROM AGENT a 
LEFT JOIN CHANTIER_AGENT c ON a.ck_agent = c.ek_agent 
WHERE a.ck_agent IN (
SELECT a2.ck_agent FROM ( 
SELECT DISTINCT a2.ck_agent FROM AGENT a2 LEFT JOIN CHANTIER_AGENT c2 ON a2.ck_agent = c2.ek_agent ORDER BY a2.nom ) 
a2 WHERE ROWNUM &amp;lt;= 10) ORDER BY a.nom
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt; 

&lt;p&gt;This causes &quot;Oracle DB Error ORA-01791 not a SELECTed expression&quot; because the sql query don&apos;t have a2.nom in SELECT DISTINCT and it&apos;s indispensable for ORDER BY a2.nom&lt;br/&gt;
The problem is caused by the variable $attributes in Doctrine_Adapter_Oracle :&lt;/p&gt;
&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt; 
&lt;span class=&quot;code-keyword&quot;&gt;protected&lt;/span&gt; $attributes = array(Doctrine_Core::ATTR_DRIVER_NAME    =&amp;gt; &lt;span class=&quot;code-quote&quot;&gt;&quot;oci8&quot;&lt;/span&gt;,
                                  Doctrine_Core::ATTR_ERRMODE        =&amp;gt; Doctrine_Core::ERRMODE_SILENT);
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;The problem is in Query.php line 1417 : &lt;/p&gt;
&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;	&lt;span class=&quot;code-keyword&quot;&gt;if&lt;/span&gt; ($driverName == &apos;pgsql&apos; || $driverName == &apos;oracle&apos; || $driverName == &apos;oci&apos; || $driverName == &apos;mssql&apos; || $driverName == &apos;odbc&apos;) {
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;The driver name declared in Doctrine_Adapter_Oracle not in this conditional. &lt;br/&gt;
To resolve this we have to modify the declaration of $attributes in Doctrine_Adapter_Oracle to :&lt;/p&gt;
&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;&lt;span class=&quot;code-keyword&quot;&gt;protected&lt;/span&gt; $attributes = array(Doctrine_Core::ATTR_DRIVER_NAME    =&amp;gt; &lt;span class=&quot;code-quote&quot;&gt;&quot;oracle&quot;&lt;/span&gt;,
                                  Doctrine_Core::ATTR_ERRMODE        =&amp;gt; Doctrine_Core::ERRMODE_SILENT);
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;An other problem is probably located at line 1409 &lt;/p&gt;
&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt; &lt;span class=&quot;code-keyword&quot;&gt;if&lt;/span&gt; (($driverName == &apos;oracle&apos; || $driverName == &apos;oci&apos;) &amp;amp;&amp;amp; $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;_isOrderedByJoinedColumn()) {
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;and 1497&lt;/p&gt;
&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;        &lt;span class=&quot;code-keyword&quot;&gt;if&lt;/span&gt; (($driverName == &apos;oracle&apos; || $driverName == &apos;oci&apos;) &amp;amp;&amp;amp; $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;_isOrderedByJoinedColumn()) {
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;if don&apos;t correct the declaration of $attributes in Doctrine_Adapter_Oracle.&lt;/p&gt;</description>
                <environment>Windows 7 64 bits, PHP 5.2.11, Oracle Database 10g Enterprise Edition Release 10.2.0.5.0 - 64bi, Symfony 1.4.13</environment>
            <key id="12988">DC-1035</key>
            <summary>ORA-01791 due to bad driver name in Doctrine_Adapter_Oracle</summary>
                <type id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/bug.png">Bug</type>
                                <priority id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/blocker.png">Blocker</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="jwage">Jonathan H. Wage</assignee>
                                <reporter username="jayson">Jayson LE PAPE</reporter>
                        <labels>
                    </labels>
                <created>Thu, 1 Sep 2011 09:30:57 +0000</created>
                <updated>Thu, 1 Sep 2011 09:31:24 +0000</updated>
                                    <version>1.2.4</version>
                                <fixVersion>1.2.4</fixVersion>
                                <component>Connection</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>1</watches>
                                <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-1007] Cannot update a field to NULL with MSSQL connection</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-1007</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;When trying to update a field to NULL in a MSSQL database, Doctrine generates the following request:&lt;/p&gt;
&lt;div class=&quot;preformatted panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;preformattedContent panelContent&quot;&gt;
&lt;pre&gt;    UPDATE table SET fieldThatMustBeNull = , anotherField = &apos;blabla&apos;;
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;therefore generating a syntax error.&lt;/p&gt;

&lt;p&gt;A fix would be to override the update method in the Doctrine_Connection_Mssql and add the following behavior:&lt;/p&gt;

&lt;div class=&quot;code panel&quot; style=&quot;border-style: solid;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeHeader panelHeader&quot; style=&quot;border-bottom-width: 1px;border-bottom-style: solid;&quot;&gt;&lt;b&gt;Doctrine_Connection_Mssql&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;    &lt;span class=&quot;code-keyword&quot;&gt;public&lt;/span&gt; function update(Doctrine_Table $table, array $fields, array $identifier)
    {
        &lt;span class=&quot;code-keyword&quot;&gt;if&lt;/span&gt; (empty($fields)) {
            &lt;span class=&quot;code-keyword&quot;&gt;return&lt;/span&gt; &lt;span class=&quot;code-keyword&quot;&gt;false&lt;/span&gt;;
        }

        $set = array();
        foreach ($fields as $fieldName =&amp;gt; $value) {
            &lt;span class=&quot;code-keyword&quot;&gt;if&lt;/span&gt; ($value &lt;span class=&quot;code-keyword&quot;&gt;instanceof&lt;/span&gt; Doctrine_Expression) {
                $set[] = $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;quoteIdentifier($table-&amp;gt;getColumnName($fieldName)) . &apos; = &apos; . $value-&amp;gt;getSql();
                unset($fields[$fieldName]);
            } &lt;span class=&quot;code-keyword&quot;&gt;else&lt;/span&gt; &lt;span class=&quot;code-keyword&quot;&gt;if&lt;/span&gt; (is_null($value)) {
                $set[] = $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;quoteIdentifier($table-&amp;gt;getColumnName($fieldName)) . &apos; = NULL&apos;;
                unset($fields[$fieldName]);
            } &lt;span class=&quot;code-keyword&quot;&gt;else&lt;/span&gt; {
                $set[] = $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;quoteIdentifier($table-&amp;gt;getColumnName($fieldName)) . &apos; = ?&apos;;
            }
        }

        $params = array_merge(array_values($fields), array_values($identifier));

        $sql  = &apos;UPDATE &apos; . $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;quoteIdentifier($table-&amp;gt;getTableName())
              . &apos; SET &apos; . implode(&apos;, &apos;, $set)
              . &apos; WHERE &apos; . implode(&apos; = ? AND &apos;, $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;quoteMultipleIdentifier($table-&amp;gt;getIdentifierColumnNames()))
              . &apos; = ?&apos;;

        &lt;span class=&quot;code-keyword&quot;&gt;return&lt;/span&gt; $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;exec($sql, $params);
    }
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;</description>
                <environment>Windows 7 32 bits with Apache 2.2.x, PHP 5.2.17, Sql Server 2008, Symfony 1.4.11 and Doctrine 1.2.4</environment>
            <key id="12667">DC-1007</key>
            <summary>Cannot update a field to NULL with MSSQL connection</summary>
                <type id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/bug.png">Bug</type>
                                <priority id="2" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/critical.png">Critical</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="jwage">Jonathan H. Wage</assignee>
                                <reporter username="guitio2002">guitio2002</reporter>
                        <labels>
                    </labels>
                <created>Wed, 25 May 2011 19:37:07 +0000</created>
                <updated>Wed, 25 May 2011 19:43:52 +0000</updated>
                                                    <fixVersion>1.2.4</fixVersion>
                                <component>Connection</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                                <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-1050] Doctrine_Relation_ForeignKey ignores ATTR_COLL_KEY attribute</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-1050</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;Doctrine_Relation_ForeignKey::fetchRelatedFor() executes the following code at line 70:&lt;/p&gt;

&lt;p&gt;$coll = $this-&amp;gt;getTable()&lt;del&gt;&amp;gt;getConnection()&lt;/del&gt;&amp;gt;query($dql, $id);&lt;br/&gt;
$related = $coll&lt;span class=&quot;error&quot;&gt;&amp;#91;0&amp;#93;&lt;/span&gt;;&lt;/p&gt;

&lt;p&gt;As you can see it accesses the first element by using index &quot;0&quot; in $coll and hence ignores a modified ATTR_COLL_KEY-setting, for instance:&lt;/p&gt;

&lt;p&gt;$this-&amp;gt;setAttribute(Doctrine_Core::ATTR_COLL_KEY, &apos;id&apos;);&lt;/p&gt;

&lt;p&gt;Fortunately I had two models (ForeignA and ForeignB) in my project which both have an one-to-one relation to a third model (Main). That helped me finding this bug which causes the following strange behavior:&lt;/p&gt;

&lt;p&gt;// program 1:&lt;/p&gt;

&lt;p&gt;$m = new Main();&lt;br/&gt;
$m-&amp;gt;name = &apos;M1&apos;;&lt;br/&gt;
$m-&amp;gt;setForeignA(new ForeignA()); // has ATTR_COLL_KEY changed to &apos;id&apos;&lt;br/&gt;
$m-&amp;gt;setForeignB(new ForeignB());&lt;br/&gt;
$m-&amp;gt;save();&lt;/p&gt;

&lt;p&gt;// program 2:&lt;/p&gt;

&lt;p&gt;$m = Doctrine_Core::getTable(&apos;M1&apos;)-&amp;gt;findOneBy(&apos;name&apos;, &apos;M1&apos;);&lt;br/&gt;
$m-&amp;gt;getForeignA()-&amp;gt;exists(); // false&lt;br/&gt;
$m-&amp;gt;getForeignB()-&amp;gt;exists(); // true&lt;/p&gt;

&lt;p&gt;-------------------------&lt;/p&gt;

&lt;p&gt;The big problem about this issue is that behavior is inconsistent. If you don&apos;t split the example above into two separate programs/processes you won&apos;t have problems, since Doctrine accesses the reference which was stored when calling save().&lt;/p&gt;

&lt;p&gt;You will get into trouble using functional tests in Symfony. Since there is only a single process for all requests I wasn&apos;t able to reproduce a problem caused by this bug which appeared in the production environment.&lt;/p&gt;

&lt;p&gt;-------------------------&lt;/p&gt;

&lt;p&gt;Edit:&lt;/p&gt;

&lt;p&gt;Doctrine_Connection::queryOne() is affected as well!&lt;/p&gt;

&lt;p&gt;A solution is to replace&lt;/p&gt;

&lt;p&gt;$coll = $this-&amp;gt;getTable()&lt;del&gt;&amp;gt;getConnection()&lt;/del&gt;&amp;gt;query($dql, $id);&lt;br/&gt;
$related = $coll&lt;span class=&quot;error&quot;&gt;&amp;#91;0&amp;#93;&lt;/span&gt;;&lt;/p&gt;

&lt;p&gt;by&lt;/p&gt;

&lt;p&gt;$related = $this-&amp;gt;getTable()&lt;del&gt;&amp;gt;getConnection()&lt;/del&gt;&amp;gt;query($dql, $id)-&amp;gt;getFirst();&lt;/p&gt;</description>
                <environment>Windows 7 64Bit&lt;br/&gt;
PHP 5.3&lt;br/&gt;
Symfony 1.4</environment>
            <key id="13506">DC-1050</key>
            <summary>Doctrine_Relation_ForeignKey ignores ATTR_COLL_KEY attribute</summary>
                <type id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/bug.png">Bug</type>
                                <priority id="2" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/critical.png">Critical</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="jwage">Jonathan H. Wage</assignee>
                                <reporter username="fishbone">Uli Hecht</reporter>
                        <labels>
                    </labels>
                <created>Tue, 6 Mar 2012 22:55:02 +0000</created>
                <updated>Wed, 7 Mar 2012 13:02:40 +0000</updated>
                                    <version>1.2.3</version>
                                <fixVersion>1.2.4</fixVersion>
                                <component>Attributes</component>
                <component>Relations</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>1</watches>
                        <comments>
                    <comment id="17534" author="fishbone" created="Wed, 7 Mar 2012 13:02:40 +0000"  >&lt;p&gt;Suggested patch&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                    <attachment id="11167" name="ForeignKey.php.patch" size="642" author="fishbone" created="Wed, 7 Mar 2012 13:02:40 +0000" />
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-651] [PATCH] Doctrine_Record::option(&apos;orderBy&apos;, ...) of join&apos;s right side being applied to refTable in m2m relationship</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-651</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;When using the &lt;tt&gt;Doctrine_Record::option(&apos;orderBy&apos;, ...)&lt;/tt&gt; feature on a table definition, where that table is the target of a many-to-many join, the specified orderBy columns are applied to the relation table&apos;s alias. So for example, given the following definitions:&lt;/p&gt;

&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;class User &lt;span class=&quot;code-keyword&quot;&gt;extends&lt;/span&gt; Doctrine_Record {
  &lt;span class=&quot;code-keyword&quot;&gt;public&lt;/span&gt; function setTableDefinition() {
    $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;hasColumn(&apos;uid&apos;, &apos;integer&apos;, &lt;span class=&quot;code-keyword&quot;&gt;null&lt;/span&gt;, array(&apos;primary&apos; =&amp;gt; &lt;span class=&quot;code-keyword&quot;&gt;true&lt;/span&gt;));
    $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;option(&apos;orderBy&apos;, &apos;uid&apos;);
  }

  &lt;span class=&quot;code-keyword&quot;&gt;public&lt;/span&gt; function setUp() {
    $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;hasMany(&apos;Group as groups&apos;, array(&apos;refClass&apos; =&amp;gt; &apos;UserGroup&apos;, &apos;local&apos; =&amp;gt; &apos;user_uid&apos;, &apos;foreign&apos; =&amp;gt; &apos;group_id&apos;));
  }
}

class Group &lt;span class=&quot;code-keyword&quot;&gt;extends&lt;/span&gt; Doctrine_Record {
  &lt;span class=&quot;code-keyword&quot;&gt;public&lt;/span&gt; function setTableDefinition() {
    $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;hasColumn(&apos;gid&apos;, &apos;integer&apos;, &lt;span class=&quot;code-keyword&quot;&gt;null&lt;/span&gt;, array(&apos;primary&apos; =&amp;gt; &lt;span class=&quot;code-keyword&quot;&gt;true&lt;/span&gt;));
  }

  &lt;span class=&quot;code-keyword&quot;&gt;public&lt;/span&gt; function setUp() {
    $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;hasMany(&apos;User as users&apos;, array(&apos;refClass&apos; =&amp;gt; &apos;UserGroup&apos;, &apos;local&apos; =&amp;gt; &apos;group_gid&apos;, &apos;foreign&apos; =&amp;gt; &apos;user_id&apos;));
  }
}

class UserGroup &lt;span class=&quot;code-keyword&quot;&gt;extends&lt;/span&gt; Doctrine_Record {
  &lt;span class=&quot;code-keyword&quot;&gt;public&lt;/span&gt; function setTableDefinition() {
    $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;hasColumn(&apos;user_uid&apos;, &apos;integer&apos;, &lt;span class=&quot;code-keyword&quot;&gt;null&lt;/span&gt;, array(&apos;primary&apos; =&amp;gt; &lt;span class=&quot;code-keyword&quot;&gt;true&lt;/span&gt;));
    $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;hasColumn(&apos;group_gid&apos;, &apos;integer&apos;, &lt;span class=&quot;code-keyword&quot;&gt;null&lt;/span&gt;, array(&apos;primary&apos; =&amp;gt; &lt;span class=&quot;code-keyword&quot;&gt;true&lt;/span&gt;));
  }

  &lt;span class=&quot;code-keyword&quot;&gt;public&lt;/span&gt; function setUp() {
    $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;hasOne(&apos;User as user&apos;, array(&apos;local&apos; =&amp;gt; &apos;user_uid&apos;, &apos;foreign&apos; =&amp;gt; &apos;uid&apos;));
    $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;hasOne(&apos;Group as group&apos;, array(&apos;local&apos; =&amp;gt; &apos;group_gid&apos;, &apos;foreign&apos; =&amp;gt; &apos;gid&apos;));
  }
}
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;the following queries:&lt;/p&gt;

&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;$query = Doctrine_Query::create()
  -&amp;gt;select(&apos;u.*&apos;)
  -&amp;gt;from(&apos;User u&apos;)
  -&amp;gt;leftJoin(&apos;u.groups g WITH g.gid=?&apos;, 1);
echo $query-&amp;gt;getSqlQuery() . &lt;span class=&quot;code-quote&quot;&gt;&quot;\n&quot;&lt;/span&gt;;

$query = Doctrine_Query::create()
  -&amp;gt;select(&apos;g.*&apos;)
  -&amp;gt;from(&apos;Group g&apos;)
  -&amp;gt;leftJoin(&apos;g.users u WITH u.uid=?&apos;, 1);
echo $query-&amp;gt;getSqlQuery() . &lt;span class=&quot;code-quote&quot;&gt;&quot;\n&quot;&lt;/span&gt;;
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;will output the following:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;SELECT u.uid AS u__uid FROM user u LEFT JOIN user_group u2 ON (u.uid = u2.user_uid) LEFT JOIN group g ON g.gid = u2.group_id AND (g.gid = ?) ORDER BY u.uid&lt;br/&gt;
SELECT g.gid AS g__gid FROM group g LEFT JOIN user_group u2 ON (g.gid = u2.group_gid) LEFT JOIN user u ON u.uid = u2.user_id AND (u.uid = ?) ORDER BY u.uid, u2.uid&lt;/p&gt;&lt;/blockquote&gt;

&lt;p&gt;The &lt;tt&gt;orderBy&lt;/tt&gt; &lt;tt&gt;option()&lt;/tt&gt; call is applied to the &lt;tt&gt;User&lt;/tt&gt; definition. The SQL for the first query is correct (where &lt;tt&gt;User&lt;/tt&gt; is on the left side of the join). The SQL for the second query (where &lt;tt&gt;User&lt;/tt&gt; is on the right-most side of the join), however, is obviously incorrect (&lt;tt&gt;UserGroup&lt;/tt&gt; doesn&apos;t even have a &lt;tt&gt;uid&lt;/tt&gt; column). Basically, &lt;tt&gt;User&lt;/tt&gt;&apos;s &lt;tt&gt;orderBy&lt;/tt&gt; option is being applied to both the &lt;tt&gt;User&lt;/tt&gt; table and its respective reference table, &lt;tt&gt;UserGroup&lt;/tt&gt;, when it is the target of a join.&lt;/p&gt;

&lt;p&gt;After digging through the source for a while, I believe I&apos;ve come up with a patch for this issue (which should be checked by someone more knowledgeable of Doctrine&apos;s internals). Basically, in the &lt;tt&gt;Doctrine_Query::buildSqlQuery()&lt;/tt&gt; function, a call is made to &lt;tt&gt;Doctrine_Relation::getOrderByStatement()&lt;/tt&gt; with the reference table (&lt;tt&gt;UserGroup&lt;/tt&gt;)&apos;s alias (&lt;tt&gt;u2&lt;/tt&gt;), which in turn makes a call to &lt;tt&gt;Doctrine_Table::getOrderByStatement()&lt;/tt&gt; on the referenced table (&lt;tt&gt;User&lt;/tt&gt;), filling in the &lt;tt&gt;ORDER BY&lt;/tt&gt; clause with &lt;tt&gt;User&lt;/tt&gt; columns using &lt;tt&gt;UserGroup&lt;/tt&gt;&apos;s alias. My solution was to reorder the logic so that the test for a reference class is made before the initial call to &lt;tt&gt;getOrderByStatement()&lt;/tt&gt; is made. It seems to work against my test case and the test cases in the repository. I&apos;ll post my patch momentarily.&lt;/p&gt;

&lt;p&gt;This bug was first mentioned in the comments in &lt;a href=&quot;http://www.doctrine-project.org/jira/browse/DC-313&quot; title=&quot;Ordering m2m relationship with column from related table (with orderBy option)&quot;&gt;DC-313&lt;/a&gt;, but the original ticket comes across as more of a feature request for the &lt;tt&gt;hasMany()&lt;/tt&gt; &lt;tt&gt;orderBy&lt;/tt&gt; feature.&lt;/p&gt;</description>
                <environment>CentOS 5.4&lt;br/&gt;
PHP 5.3.2&lt;br/&gt;
MySQL 5.1.44, for unknown-linux-gnu (x86_64)</environment>
            <key id="11270">DC-651</key>
            <summary>[PATCH] Doctrine_Record::option(&apos;orderBy&apos;, ...) of join&apos;s right side being applied to refTable in m2m relationship</summary>
                <type id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/bug.png">Bug</type>
                                <priority id="3" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/major.png">Major</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="guilhermeblanco">Guilherme Blanco</assignee>
                                <reporter username="suhock">suhock</reporter>
                        <labels>
                    </labels>
                <created>Mon, 26 Apr 2010 12:22:21 +0000</created>
                <updated>Wed, 31 Aug 2011 12:43:09 +0000</updated>
                                    <version>1.2.2</version>
                <version>1.2.3</version>
                                <fixVersion>1.2.2</fixVersion>
                <fixVersion>1.2.3</fixVersion>
                <fixVersion>1.2.4</fixVersion>
                                <component>Query</component>
                <component>Relations</component>
                        <due></due>
                    <votes>2</votes>
                        <watches>4</watches>
                        <comments>
                    <comment id="12750" author="suhock" created="Mon, 26 Apr 2010 12:45:12 +0000"  >&lt;p&gt;attached a test case for this bug&lt;/p&gt;</comment>
                    <comment id="12751" author="suhock" created="Mon, 26 Apr 2010 13:01:03 +0000"  >&lt;p&gt;patch against /branches/1.2 HEAD (should also work apply to 1.2.2 tag)&lt;/p&gt;</comment>
                    <comment id="14179" author="dordille" created="Mon, 30 Aug 2010 17:22:44 +0000"  >&lt;p&gt;I can confirm this as an issue.  However I don&apos;t think the above patch adequately fixes the problem it seems like with it an order by is still added for the ref column however the relation alias is lost.&lt;/p&gt;

&lt;p&gt;My query with the patch became&lt;br/&gt;
SELECT g.gid AS g__gid FROM group g LEFT JOIN user_group u2 ON (g.gid = u2.group_gid) LEFT JOIN user u ON u.uid = u2.user_id AND (u.uid = ?) ORDER BY u.uid, uid &lt;/p&gt;

&lt;p&gt;I made an another patch that prevents this extra order by clause from being added and have attached it.&lt;/p&gt;
</comment>
                    <comment id="14428" author="suhock" created="Tue, 21 Sep 2010 08:53:25 +0000"  >&lt;p&gt;I tried out the new patch (Query_orderby_relation.diff), but it provides a reversed diff (patching goes from a patched version to the original). After applying it manually, it fails the provided test case and several additional test cases from the repository.&lt;/p&gt;

&lt;p&gt;The original patch DOES pass the provided test case, when applied against 1.2.2, 1.2.3, or the 1.2 branch from the repository. It does not pass, however, Doctrine_Query_Orderby_TestCase. As the previous poster mentioned, it fails to resolve aliases in instances where the &apos;orderBy&apos; option is specified in a relation definition.&lt;/p&gt;

&lt;p&gt;I deleted the original patch and am providing a revised patch (Ticket_DC651.patch) against branch 1.2 HEAD (also works with 1.2.3), which fixes this issue. It passes all working test cases, including Doctrine_Query_Orderby_TestCase and DC651TestCase.&lt;/p&gt;</comment>
                    <comment id="16406" author="deraujoj" created="Wed, 31 Aug 2011 12:43:08 +0000"  >&lt;p&gt;I had this issue recently on a application I&apos;m working on as described the oderBy option was applied on the joined table on a column that even doesn&apos;t exist in it. I used the DC651 patch provided and it solved the issue, so far I haven&apos;t seen any side effect to it. &lt;/p&gt;</comment>
                </comments>
                    <attachments>
                    <attachment id="10585" name="DC651TestCase.php" size="3335" author="suhock" created="Mon, 26 Apr 2010 12:45:12 +0000" />
                    <attachment id="10751" name="Query_orderBy_relation.diff" size="1122" author="dordille" created="Mon, 30 Aug 2010 17:22:56 +0000" />
                    <attachment id="10806" name="Ticket_DC651.patch" size="1448" author="suhock" created="Tue, 21 Sep 2010 08:53:25 +0000" />
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-741] Sort of Migration Class Problem With More Than 9 Classes</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-741</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;I have problem when do a migration with more than 9 classes. (Version1, Version2, Version3, ..., Version10)&lt;/p&gt;

&lt;p&gt;php doctrine-cli.php migrate 10&lt;/p&gt;

&lt;p&gt;When migration class lower than 10, migration well done.&lt;br/&gt;
The migration always return another class, not Version10.&lt;/p&gt;

&lt;p&gt;I have do a simple research, and found the problem is on the sort of the class name.&lt;br/&gt;
It use SORT_NUMERIC, and it is not suitable to sort them.&lt;/p&gt;

&lt;p&gt;So, I change the sort method to Natural Sort, to fix this issue.&lt;/p&gt;</description>
                <environment>Ubuntu 10.04, PHP 5.3.2, Doctrine 1.2.2</environment>
            <key id="11505">DC-741</key>
            <summary>Sort of Migration Class Problem With More Than 9 Classes</summary>
                <type id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/bug.png">Bug</type>
                                <priority id="3" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/major.png">Major</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="jwage">Jonathan H. Wage</assignee>
                                <reporter username="dollyaswin">Dolly Aswin Harahap</reporter>
                        <labels>
                    </labels>
                <created>Wed, 16 Jun 2010 08:50:45 +0000</created>
                <updated>Tue, 24 Aug 2010 12:30:40 +0000</updated>
                                    <version>1.2.2</version>
                                <fixVersion>1.2.4</fixVersion>
                                <component>Cli</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                        <comments>
                    <comment id="13340" author="dollyaswin" created="Wed, 16 Jun 2010 08:52:22 +0000"  >&lt;p&gt;Here I attach patch to fix this issue. Please check it.&lt;/p&gt;</comment>
                    <comment id="14053" author="jwage" created="Tue, 24 Aug 2010 12:30:40 +0000"  >&lt;p&gt;I am not able to produce the error, things are always in the correct order. I added a test here: &lt;a href=&quot;http://trac.doctrine-project.org/changeset/7683&quot; class=&quot;external-link&quot;&gt;http://trac.doctrine-project.org/changeset/7683&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Can you help me with how to reproduce the error?&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                    <attachment id="10661" name="DC-741.patch" size="808" author="dollyaswin" created="Wed, 16 Jun 2010 08:52:22 +0000" />
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-756] Cannot use named parameters in a &apos;limit(&apos;:max&apos;) clause</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-756</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;$modulus=5;&lt;br/&gt;
$offset=2;&lt;br/&gt;
$this-&amp;gt;Statuses&lt;span class=&quot;error&quot;&gt;&amp;#91;&amp;#39;ready&amp;#39;&amp;#93;&lt;/span&gt;=1;&lt;/p&gt;

&lt;p&gt;This works&lt;br/&gt;
---------------------------------&lt;br/&gt;
   $DetailsList=&lt;br/&gt;
     Doctrine_Query::create()-&amp;gt;from(&apos;Data s&apos;)&lt;br/&gt;
                             -&amp;gt;where(&apos;s.status_id=:status_id&apos;)&lt;br/&gt;
                             -&amp;gt;andWhere(&apos;((s.id % :modulus) - :offset)=0&apos;)&lt;br/&gt;
                             -&amp;gt;orderBy(&apos;s.id&apos;)&lt;br/&gt;
                             -&amp;gt;limit($maxDaysDetailsToProcess)&lt;br/&gt;
                             &lt;del&gt;&amp;gt;execute(array(&apos;:status_id&apos;=&amp;gt;$this&lt;/del&gt;&amp;gt;Statuses&lt;span class=&quot;error&quot;&gt;&amp;#91;&amp;#39;ready&amp;#39;&amp;#93;&lt;/span&gt;,&lt;br/&gt;
                                              &apos;:modulus&apos;=&amp;gt;$modulus,&lt;br/&gt;
                                              &apos;:offset&apos;=&amp;gt;$offset), Doctrine::HYDRATE_ARRAY);&lt;/p&gt;




&lt;p&gt;This does not, it gets the whole table&lt;br/&gt;
---------------------------------&lt;br/&gt;
   $DetailsList=&lt;br/&gt;
     Doctrine_Query::create()-&amp;gt;from(&apos;Data s&apos;)&lt;br/&gt;
                             -&amp;gt;where(&apos;s.status_id=:status_id&apos;)&lt;br/&gt;
                             -&amp;gt;andWhere(&apos;((s.id % :modulus) - :offset)=0&apos;)&lt;br/&gt;
                             -&amp;gt;orderBy(&apos;s.id&apos;)&lt;br/&gt;
                             -&amp;gt;limit(&apos;:max&apos;)&lt;br/&gt;
                             &lt;del&gt;&amp;gt;execute(array(&apos;:status_id&apos;=&amp;gt;$this&lt;/del&gt;&amp;gt;Statuses&lt;span class=&quot;error&quot;&gt;&amp;#91;&amp;#39;ready&amp;#39;&amp;#93;&lt;/span&gt;,&lt;br/&gt;
                                              &apos;:modulus&apos;=&amp;gt;$modulus,&lt;br/&gt;
                                              &apos;:offset&apos;=&amp;gt;$offset,&lt;br/&gt;
                                              &apos;:max&apos;=&amp;gt;$maxDaysDetailsToProcess), Doctrine::HYDRATE_ARRAY);&lt;/p&gt;

</description>
                <environment>ubuntu, apache, symfony version 1.4.4</environment>
            <key id="11532">DC-756</key>
            <summary>Cannot use named parameters in a &apos;limit(&apos;:max&apos;) clause</summary>
                <type id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/bug.png">Bug</type>
                                <priority id="3" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/major.png">Major</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="jwage">Jonathan H. Wage</assignee>
                                <reporter username="gearond">Dennis Gearon</reporter>
                        <labels>
                    </labels>
                <created>Mon, 21 Jun 2010 01:01:11 +0000</created>
                <updated>Tue, 7 Sep 2010 17:10:38 +0000</updated>
                                                    <fixVersion>1.2.4</fixVersion>
                                        <due></due>
                    <votes>0</votes>
                        <watches>1</watches>
                        <comments>
                    <comment id="13410" author="gearond" created="Thu, 24 Jun 2010 20:58:58 +0000"  >&lt;p&gt;I noticed an error in the code, which does not solve the problem, only confuse whomever works on it &lt;img class=&quot;emoticon&quot; src=&quot;http://www.doctrine-project.org/jira/images/icons/emoticons/smile.gif&quot; height=&quot;20&quot; width=&quot;20&quot; align=&quot;absmiddle&quot; alt=&quot;&quot; border=&quot;0&quot;/&gt;  Please add &lt;/p&gt;

&lt;p&gt;$maxDaysDetailsToProcess=3;&lt;/p&gt;

&lt;p&gt;as the fourth line in the code.&lt;/p&gt;</comment>
                    <comment id="14302" author="jagalan" created="Tue, 7 Sep 2010 17:10:20 +0000"  >&lt;p&gt;I think I found a solution but it&apos;s making some tests fail. Let me explain you what I did:&lt;/p&gt;

&lt;p&gt;First I removed any casting to int of the limit value, in order to keep the named parameter in the LIMIT part of the query. Actually this named parameters were converted to 0 due to those int castings.&lt;/p&gt;

&lt;p&gt;Then I realized that the params are bound as strings so the resulting query looks like ... LIMIT &quot;2&quot; or whatever you put in the limit value, and mysql throws and error. Then I tryed to modify the function that binds the paramters to bind them as integers when they&apos;re not strings. Everything seems to work fine and you could put named parameters in the limit clause, but some tests are failing. If you look at the tests that are failing you&apos;ll see that they&apos;re failing because of a wrong phone number, the test it&apos;s expecting a number large number like 6155139185 but the result array has a number like 1860171889. I&apos;m wondering if there&apos;s something wrong when binding numbers bigger than mysql INT as integers.&lt;/p&gt;

&lt;p&gt;I attach a diff file with the changes I did, hope it helps&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                    <attachment id="10779" name="DC-756.partial.patch" size="2068" author="jagalan" created="Tue, 7 Sep 2010 17:10:38 +0000" />
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-758] CascadeDelete not work properly on Versionable and on the AuditLog</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-758</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt; 
Schema:

Personal:
  actAs:
    Versionable:
      deleteVersions: &lt;span class=&quot;code-keyword&quot;&gt;false&lt;/span&gt;
      cascadeDelete: &lt;span class=&quot;code-keyword&quot;&gt;false&lt;/span&gt;
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt; 

&lt;p&gt;When you use this configuration and try to delete one of the record linked with the versionned one, an exception about foreign key is raised because the id of the versioned record has a foreign key to the id of the record.&lt;/p&gt;

&lt;p&gt;It&apos;s necessary to could work with cascadeDelete: false... because like that it&apos;s needed to use softDelete and the deleted record&apos;s will be stored on the version table, but with the advantage that you don&apos;t have the performance problem of soft delete behaviour.&lt;/p&gt;

&lt;p&gt;Thanks!&lt;/p&gt;</description>
                <environment>Mac OS X Snow Leopard, LAMP and Macports</environment>
            <key id="11535">DC-758</key>
            <summary>CascadeDelete not work properly on Versionable and on the AuditLog</summary>
                <type id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/bug.png">Bug</type>
                                <priority id="3" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/major.png">Major</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="jwage">Jonathan H. Wage</assignee>
                                <reporter username="jaimesuez">Jaime Suez</reporter>
                        <labels>
                    </labels>
                <created>Mon, 21 Jun 2010 13:54:37 +0000</created>
                <updated>Tue, 24 Aug 2010 12:55:48 +0000</updated>
                                    <version>1.2.3</version>
                                <fixVersion>1.2.4</fixVersion>
                                <component>Behaviors</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>1</watches>
                                <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-769] Variable type different for return value from Doctrine_Record-&gt;toArray() depending on whether the object is from a select, or a save.</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-769</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;With a object that is created via a save(),  and the record&apos;s primary key is a INT fed by a SEQUENCE, the type of the variable is an INT.&lt;/p&gt;

&lt;p&gt;With an object that is hydrated from the database via a SELECT, the record&apos;s primary key INT will come back in &apos;toArray()&apos; as a STRING.&lt;/p&gt;

&lt;p&gt;That means that checking for type has to know what context it came from, user, INSERT, or SELECT. Not fun.&lt;/p&gt;

&lt;p&gt;This also screws up converting arrays to JSON, &apos;cause the STRINGS get quotation marks and the INTS do not.&lt;/p&gt;

&lt;p&gt;As a general rule, everything FROM the database seems to be strings. Yes, I know, everything &apos;on the wire&apos; or &apos;through a socket&apos; comes out as text. And it&apos;s a lot faster to leave it that way.&lt;/p&gt;

&lt;p&gt;But having the type be different depending on the database operation? Not sure I like that.&lt;/p&gt;</description>
                <environment>Ubuntu9.10, PHP 5.2.6, Symfony 1.4.1, Postgres8.4</environment>
            <key id="11557">DC-769</key>
            <summary>Variable type different for return value from Doctrine_Record-&gt;toArray() depending on whether the object is from a select, or a save.</summary>
                <type id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/bug.png">Bug</type>
                                <priority id="3" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/major.png">Major</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="jwage">Jonathan H. Wage</assignee>
                                <reporter username="gearond">Dennis Gearon</reporter>
                        <labels>
                    </labels>
                <created>Sun, 27 Jun 2010 00:55:48 +0000</created>
                <updated>Tue, 24 Aug 2010 12:55:48 +0000</updated>
                                    <version>1.2.1</version>
                                <fixVersion>1.2.1</fixVersion>
                <fixVersion>1.2.2</fixVersion>
                <fixVersion>1.2.4</fixVersion>
                                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                        <comments>
                    <comment id="14050" author="jwage" created="Tue, 24 Aug 2010 12:02:06 +0000"  >&lt;p&gt;Can you provide a test case so that we can see if we can come up with a patch?&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-825] Versionable does not work with column alias on primary keys [+patch]</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-825</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;Using the Versionable behavior on a model which has a column with an alias and which is also primary causes the generation of a wrong version of the versionable table.&lt;/p&gt;

&lt;p&gt;Example:&lt;/p&gt;

&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt; 
ModelFoo:
  model_id as id
  username
  password
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt; 

&lt;p&gt;Generates tables:&lt;br/&gt;
model_foo (model_id, username, password, version)&lt;br/&gt;
model_foo_version (id, model_id, userrname, password, version)&lt;/p&gt;

&lt;p&gt;It should be:&lt;br/&gt;
model_foo (model_id, username, password, version)&lt;br/&gt;
model_foo_version (model_id, userrname, password, version)&lt;/p&gt;</description>
                <environment></environment>
            <key id="11768">DC-825</key>
            <summary>Versionable does not work with column alias on primary keys [+patch]</summary>
                <type id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/bug.png">Bug</type>
                                <priority id="3" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/major.png">Major</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="jwage">Jonathan H. Wage</assignee>
                                <reporter username="enrico">Enrico Stahn</reporter>
                        <labels>
                    </labels>
                <created>Fri, 13 Aug 2010 07:42:28 +0000</created>
                <updated>Wed, 25 Aug 2010 11:26:56 +0000</updated>
                                    <version>1.2.2</version>
                                <fixVersion>1.2.4</fixVersion>
                                <component>Behaviors</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                        <comments>
                    <comment id="13942" author="enrico" created="Fri, 13 Aug 2010 08:52:55 +0000"  >&lt;p&gt;TestCase and Fix&lt;br/&gt;
&lt;a href=&quot;http://github.com/estahn/doctrine1/tree/DC-825&quot; class=&quot;external-link&quot;&gt;http://github.com/estahn/doctrine1/tree/DC-825&lt;/a&gt;&lt;/p&gt;</comment>
                    <comment id="13996" author="enrico" created="Wed, 18 Aug 2010 06:55:47 +0000"  >&lt;p&gt;The supplied patches are not up-to-date. Pls use &lt;a href=&quot;http://github.com/estahn/doctrine1/tree/DC-825&quot; class=&quot;external-link&quot;&gt;http://github.com/estahn/doctrine1/tree/DC-825&lt;/a&gt;&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                    <attachment id="10738" name="0001-TestCase-for-issue-DC-825.patch" size="3855" author="enrico" created="Fri, 13 Aug 2010 12:42:14 +0000" />
                    <attachment id="10739" name="0002-DC-825-fix-generation-of-the-versionable-table.patch" size="8407" author="enrico" created="Fri, 13 Aug 2010 12:42:14 +0000" />
                    <attachment id="10740" name="0003-DC-825-fix-generation-of-model-classes-with-column-a.patch" size="1356" author="enrico" created="Fri, 13 Aug 2010 12:42:14 +0000" />
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-828] MSSQL - ORDER BY on text columns throws mssql error 306 [+patch]</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-828</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;ul&gt;
	&lt;li&gt;Table: foo (id:integer, title:text)&lt;/li&gt;
	&lt;li&gt;Created Query: SELECT &lt;span class=&quot;error&quot;&gt;&amp;#91;id&amp;#93;&lt;/span&gt;, &lt;span class=&quot;error&quot;&gt;&amp;#91;title&amp;#93;&lt;/span&gt; FROM &lt;span class=&quot;error&quot;&gt;&amp;#91;foo&amp;#93;&lt;/span&gt; ORDER BY &lt;span class=&quot;error&quot;&gt;&amp;#91;title&amp;#93;&lt;/span&gt;&lt;/li&gt;
&lt;/ul&gt;


&lt;p&gt;Throws:&lt;/p&gt;
&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;Server: Msg 306, Level 16, State 2, Line 1
The text, ntext, and image data types cannot be compared or sorted, except when using IS NULL or LIKE &lt;span class=&quot;code-keyword&quot;&gt;operator&lt;/span&gt;.
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Solution:&lt;/p&gt;
&lt;ul&gt;
	&lt;li&gt;Created Query: SELECT &lt;span class=&quot;error&quot;&gt;&amp;#91;id&amp;#93;&lt;/span&gt;, &lt;span class=&quot;error&quot;&gt;&amp;#91;title&amp;#93;&lt;/span&gt; FROM &lt;span class=&quot;error&quot;&gt;&amp;#91;foo&amp;#93;&lt;/span&gt; ORDER BY CAST(&lt;span class=&quot;error&quot;&gt;&amp;#91;title&amp;#93;&lt;/span&gt; AS VARCHAR(8000))&lt;/li&gt;
&lt;/ul&gt;


&lt;p&gt;References:&lt;/p&gt;
&lt;ul&gt;
	&lt;li&gt;&lt;a href=&quot;http://msdn.microsoft.com/en-us/library/aa276838(v=SQL.80).aspx&quot; class=&quot;external-link&quot;&gt;http://msdn.microsoft.com/en-us/library/aa276838(v=SQL.80).aspx&lt;/a&gt;&lt;/li&gt;
	&lt;li&gt;&lt;a href=&quot;http://msdn.microsoft.com/en-us/library/cc645611.aspx&quot; class=&quot;external-link&quot;&gt;http://msdn.microsoft.com/en-us/library/cc645611.aspx&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;


&lt;p&gt;Patch will be supplied soon ...&lt;/p&gt;</description>
                <environment></environment>
            <key id="11774">DC-828</key>
            <summary>MSSQL - ORDER BY on text columns throws mssql error 306 [+patch]</summary>
                <type id="4" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/improvement.png">Improvement</type>
                                <priority id="3" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/major.png">Major</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="guilhermeblanco">Guilherme Blanco</assignee>
                                <reporter username="enrico">Enrico Stahn</reporter>
                        <labels>
                    </labels>
                <created>Mon, 16 Aug 2010 07:36:30 +0000</created>
                <updated>Thu, 2 Sep 2010 08:02:33 +0000</updated>
                                    <version>1.2.2</version>
                                <fixVersion>1.2.4</fixVersion>
                                <component>Query</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>1</watches>
                        <comments>
                    <comment id="14021" author="enrico" created="Fri, 20 Aug 2010 14:44:03 +0000"  >&lt;p&gt;&lt;a href=&quot;http://github.com/estahn/doctrine1/compare/DC-828&quot; class=&quot;external-link&quot;&gt;http://github.com/estahn/doctrine1/compare/DC-828&lt;/a&gt;&lt;br/&gt;
&lt;a href=&quot;http://github.com/estahn/doctrine1/tree/DC-828&quot; class=&quot;external-link&quot;&gt;http://github.com/estahn/doctrine1/tree/DC-828&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;I guess we need more TestCases for the SubQuery stuff.&lt;/p&gt;</comment>
                    <comment id="14234" author="enrico" created="Thu, 2 Sep 2010 08:02:33 +0000"  >&lt;p&gt;I made a mistake with github, the updated branch can be found at&lt;br/&gt;
&lt;a href=&quot;http://github.com/estahn/doctrine1/tree/DC-828-2&quot; class=&quot;external-link&quot;&gt;http://github.com/estahn/doctrine1/tree/DC-828-2&lt;/a&gt;&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-831] Importing fixtures fails when GoogleI18n used with &quot;Couldn&apos;t create collection index. Record field &apos;lang&apos; was null.&quot;</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-831</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;There&apos;s a problem with Doctrine_Data_Import. When trying to load a fixture record with translations, and GoogleI18n (or similar) instead of I18n is used (via actAs()), the following crash happens:&lt;br/&gt;
Couldn&apos;t create collection index. Record field &apos;lang&apos; was null.&lt;/p&gt;

&lt;p&gt;#0 /Users/argasek/Sites/fwm/library/doctrine/Doctrine/Access.php(131): Doctrine_Collection-&amp;gt;add(Object(Fwm_Shop_Catalog_CategoryTranslation))&lt;br/&gt;
#1 /Users/argasek/Sites/test/library/doctrine/Doctrine/Data/Import.php(241): Doctrine_Access-&amp;gt;offsetSet(NULL, Object(Test_Shop_Catalog_CategoryTranslation))&lt;br/&gt;
#2 /Users/argasek/Sites/test/library/doctrine/Doctrine/Data/Import.php(335): Doctrine_Data_Import-&amp;gt;_processRow(&apos;(catalog_catego...&apos;, Array)&lt;br/&gt;
#3 /Users/argasek/Sites/test/library/doctrine/Doctrine/Data/Import.php(118): Doctrine_Data_Import-&amp;gt;_loadData(Array)&lt;br/&gt;
#4 /Users/argasek/Sites/test/library/doctrine/Doctrine/Data.php(222): Doctrine_Data_Import-&amp;gt;doImport(false)&lt;br/&gt;
#5 /Users/argasek/Sites/test/library/doctrine/Doctrine/Core.php(1011): Doctrine_Data-&amp;gt;importData(&apos;/Users/argasek/...&apos;, &apos;yml&apos;, Array, false)&lt;br/&gt;
#6 /Users/argasek/Sites/test/library/doctrine/Doctrine/Task/LoadData.php(43): Doctrine_Core::loadData(&apos;/Users/argasek/...&apos;, false)&lt;br/&gt;
#7 /Users/argasek/Sites/test/library/doctrine/Doctrine/Cli.php(516): Doctrine_Task_LoadData-&amp;gt;execute()&lt;br/&gt;
#8 /Users/argasek/Sites/test/library/doctrine/Doctrine/Cli.php(498): Doctrine_Cli-&amp;gt;executeTask(Object(Doctrine_Task_LoadData), Array)&lt;br/&gt;
#9 /Users/argasek/Sites/test/library/doctrine/Doctrine/Cli.php(452): Doctrine_Cli-&amp;gt;_run(Array)&lt;br/&gt;
#10 /Users/argasek/Sites/test/scripts/doctrine-cli.php(29): Doctrine_Cli-&amp;gt;run(Array)&lt;br/&gt;
#11 &lt;/p&gt;
{main}

&lt;p&gt;I have narrowed down the problem to the line 135 of Doctrine/Data/Import.php, ie.&lt;/p&gt;

&lt;p&gt;if ($table-&amp;gt;hasRelation($key) &amp;amp;&amp;amp; is_array($value) &amp;amp;&amp;amp; ! $table-&amp;gt;hasTemplate(&apos;Doctrine_Template_I18n&apos;)) {&lt;/p&gt;

&lt;p&gt;In case of GoogleI18n, $table-&amp;gt;hasTemplate(&apos;Doctrine_Template_I18n&apos;) returns false.&lt;/p&gt;

&lt;p&gt;I have no idea how to patch this in a sane way. Adding another condition (&amp;amp;&amp;amp; ! $table-&amp;gt;hasTemplate(&apos;Doctrine_Template_GoogleI18n&apos;) serves well as a workaround, but such condition would be required for any class similar to Doctrine_Template_GoogleI18n. I guess the condition should check if it&apos;s a Doctrine_Template_I18n template or any template iherited from this class?...&lt;/p&gt;</description>
                <environment>Mac OS X 10.6.4, Zend Server CE 5.0.2 (irrelevant, I guess)</environment>
            <key id="11784">DC-831</key>
            <summary>Importing fixtures fails when GoogleI18n used with &quot;Couldn&apos;t create collection index. Record field &apos;lang&apos; was null.&quot;</summary>
                <type id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/bug.png">Bug</type>
                                <priority id="3" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/major.png">Major</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="jwage">Jonathan H. Wage</assignee>
                                <reporter username="argasek">Jakub Argasi&#324;ski</reporter>
                        <labels>
                    </labels>
                <created>Tue, 17 Aug 2010 06:55:40 +0000</created>
                <updated>Wed, 13 Oct 2010 08:02:30 +0000</updated>
                                    <version>1.2.2</version>
                <version>1.2.3</version>
                                <fixVersion>1.2.4</fixVersion>
                                <component>Data Fixtures</component>
                <component>I18n</component>
                <component>Import/Export</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>1</watches>
                        <comments>
                    <comment id="13975" author="argasek" created="Tue, 17 Aug 2010 07:40:42 +0000"  >&lt;p&gt;I have provided a quick workaround patch for this problem, with an approach described in my report, ie. checking whether table has a template being an instance of or a child of Doctrine_Template_I18n.&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                    <attachment id="10743" name="fix_google18n_and_similiar_import_problem.patch" size="1387" author="argasek" created="Tue, 17 Aug 2010 07:40:42 +0000" />
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-856] Doctrine_Core::getPath() not working when inside phar, due to a bug in php</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-856</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;It seems that there is a bug in php, and realpath doesn&apos;t work when path is inside of phar archive.&lt;br/&gt;
function Doctrine_Core::getPath()&lt;br/&gt;
        if ( ! self::$_path) &lt;/p&gt;
{
          self::$_path = realpath(dirname(__FILE__) . &apos;/..&apos;);
        }

&lt;p&gt;can be easily changed to &lt;br/&gt;
        if ( ! self::$_path) &lt;/p&gt;
{
          self::$_path = dirname(dirname(__FILE__));
        }</description>
                <environment></environment>
            <key id="11877">DC-856</key>
            <summary>Doctrine_Core::getPath() not working when inside phar, due to a bug in php</summary>
                <type id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/bug.png">Bug</type>
                                <priority id="3" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/major.png">Major</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="jwage">Jonathan H. Wage</assignee>
                                <reporter username="mvrhov">Miha Vrhovnik</reporter>
                        <labels>
                    </labels>
                <created>Fri, 3 Sep 2010 06:36:39 +0000</created>
                <updated>Tue, 4 Jan 2011 06:19:21 +0000</updated>
                                    <version>1.2.3</version>
                                <fixVersion>1.2.4</fixVersion>
                                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                        <comments>
                    <comment id="15105" author="ishtanzar" created="Tue, 4 Jan 2011 06:19:21 +0000"  >&lt;p&gt;&lt;a href=&quot;http://bugs.php.net/bug.php?id=52769&quot; class=&quot;external-link&quot;&gt;http://bugs.php.net/bug.php?id=52769&lt;/a&gt;&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-881] Doctrine_Manager::parsePdoDsn() doesn&apos;t work properly [+patch]</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-881</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;Doctrine_Manager::parsePdoDsn(&apos;dblib:host=127.0.0.1:1433;dbname=foo&apos;) does not return proper results.&lt;/p&gt;

&lt;p&gt;patch and test case @ github&lt;/p&gt;</description>
                <environment></environment>
            <key id="11989">DC-881</key>
            <summary>Doctrine_Manager::parsePdoDsn() doesn&apos;t work properly [+patch]</summary>
                <type id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/bug.png">Bug</type>
                                <priority id="3" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/major.png">Major</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="jwage">Jonathan H. Wage</assignee>
                                <reporter username="enrico">Enrico Stahn</reporter>
                        <labels>
                    </labels>
                <created>Fri, 8 Oct 2010 12:46:04 +0000</created>
                <updated>Fri, 8 Oct 2010 12:46:04 +0000</updated>
                                    <version>1.2.3</version>
                                <fixVersion>1.2.4</fixVersion>
                                <component>Connection</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                                <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-898] (PATCH) Migration fails when addColumn with type &apos;boolean&apos; used with default value, resulting in incorrect &apos;ALTER TABLE&apos; query in MySQL</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-898</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;I use MySQL. In my up() method in migration class, I have:&lt;/p&gt;

&lt;p&gt;$this-&amp;gt;addColumn($table, &apos;is_master&apos;, &apos;boolean&apos;, null, array(&apos;notnull&apos; =&amp;gt; true, &apos;default&apos; =&amp;gt; false));&lt;/p&gt;

&lt;p&gt;Running &apos;migrate&apos; results in a following exception:&lt;br/&gt;
 Error #1 - SQLSTATE&lt;span class=&quot;error&quot;&gt;&amp;#91;42000&amp;#93;&lt;/span&gt;: Syntax error or access violation: 1067 Invalid default value for &apos;is_master&apos;. Failing Query: &quot;ALTER TABLE books_authors ADD is_master TINYINT(1) DEFAULT &apos;&apos; NOT NULL&quot;&lt;br/&gt;
#0 /usr/local/zend/share/pear/Doctrine/Connection.php(1025): Doctrine_Connection-&amp;gt;rethrowException(Object(PDOException), Object(Doctrine_Connection_Mysql), &apos;ALTER TABLE boo...&apos;)&lt;br/&gt;
#1 /usr/local/zend/share/pear/Doctrine/Export.php(621): Doctrine_Connection-&amp;gt;execute(&apos;ALTER TABLE boo...&apos;)&lt;br/&gt;
#2 /usr/local/zend/share/pear/Doctrine/Migration/Process.php(89): Doctrine_Export-&amp;gt;alterTable(&apos;books_authors&apos;, Array)&lt;br/&gt;
#3 /usr/local/zend/share/pear/Doctrine/Migration.php(522): Doctrine_Migration_Process-&amp;gt;processCreatedColumn(Array)&lt;br/&gt;
#4 /usr/local/zend/share/pear/Doctrine/Migration.php(479): Doctrine_Migration-&amp;gt;_doMigrateStep(&apos;up&apos;, 1)&lt;br/&gt;
#5 /usr/local/zend/share/pear/Doctrine/Migration.php(328): Doctrine_Migration-&amp;gt;_doMigrate(1)&lt;br/&gt;
#6 /usr/local/zend/share/pear/Doctrine/Core.php(1016): Doctrine_Migration-&amp;gt;migrate(NULL)&lt;br/&gt;
#7 /usr/local/zend/share/pear/Doctrine/Task/Migrate.php(41): Doctrine_Core::migrate(&apos;/Users/argasek/...&apos;, NULL)&lt;br/&gt;
#8 /usr/local/zend/share/pear/Doctrine/Cli.php(516): Doctrine_Task_Migrate-&amp;gt;execute()&lt;br/&gt;
#9 /usr/local/zend/share/pear/Doctrine/Cli.php(498): Doctrine_Cli-&amp;gt;executeTask(Object(Doctrine_Task_Migrate), Array)&lt;br/&gt;
#10 /usr/local/zend/share/pear/Doctrine/Cli.php(452): Doctrine_Cli-&amp;gt;_run(Array)&lt;br/&gt;
#11 /Users/argasek/Sites/blipoteka/scripts/doctrine-cli.php(28): Doctrine_Cli-&amp;gt;run(Array)&lt;br/&gt;
#12 &lt;/p&gt;
{main}

&lt;p&gt;However, I would expect ALTER query to look like this:&lt;/p&gt;

&lt;p&gt;ALTER TABLE books_authors ADD is_master TINYINT(1) DEFAULT 0 NOT NULL&lt;/p&gt;

&lt;p&gt;I guess there&apos;s a problem with getDefaultFieldDeclaration() in Doctrine_Export_Mysql, it lacks convertBooleans() call being present at Doctrine_Export.&lt;/p&gt;</description>
                <environment>Mac OS X 10.6 Snow Leopard / Zend Server CE 5.0.3 (irrelevant)</environment>
            <key id="12026">DC-898</key>
            <summary>(PATCH) Migration fails when addColumn with type &apos;boolean&apos; used with default value, resulting in incorrect &apos;ALTER TABLE&apos; query in MySQL</summary>
                <type id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/bug.png">Bug</type>
                                <priority id="3" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/major.png">Major</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="jwage">Jonathan H. Wage</assignee>
                                <reporter username="argasek">Jakub Argasi&#324;ski</reporter>
                        <labels>
                    </labels>
                <created>Fri, 22 Oct 2010 08:02:33 +0000</created>
                <updated>Fri, 22 Oct 2010 08:02:33 +0000</updated>
                                    <version>1.2.3</version>
                                <fixVersion>1.2.4</fixVersion>
                                <component>Import/Export</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                                <attachments>
                    <attachment id="10830" name="fix_boolean_default_mysql_column_migration.patch" size="525" author="argasek" created="Fri, 22 Oct 2010 08:02:33 +0000" />
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-944] Precedence problem in SQL generation allows bypass of pending joins</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-944</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;&apos;Pending join conditions&apos; are used by listeners to inject extra SQL conditions into a query. They are often used to add basic constraints on every query. An example is the bundled &lt;b&gt;SoftDelete&lt;/b&gt; template. Its listener adds extra constraints such as &lt;b&gt;s.deleted_at IS NULL&lt;/b&gt; to a query, to make sure that deleted rows are never retrieved on a query.&lt;/p&gt;

&lt;p&gt;However, in the emitted SQL, &lt;b&gt;Doctrine_Query&lt;/b&gt; does not use parentheses to group normal SQL conditions together. The pending join condition is simply added to the string without encapsulating existing expressions. This makes it possible to bypass the pending join conditions entirely by using the OR operator.&lt;/p&gt;

&lt;p&gt;&lt;b&gt;Example&lt;/b&gt;&lt;/p&gt;

&lt;p&gt;For instance, the following query exhibits this problem:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;$query = Doctrine_Query::create()&lt;br/&gt;
        -&amp;gt;from(&quot;SoftDeleteTest&quot;)&lt;br/&gt;
        -&amp;gt;where(&quot;name=?&quot;, &quot;faulty&quot;)&lt;br/&gt;
        -&amp;gt;orWhere(&quot;name=?&quot;, &quot;faulty&quot;);&lt;/p&gt;&lt;/blockquote&gt;

&lt;p&gt;This query emits the following SQL:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;SELECT s.name AS s_&lt;em&gt;name, s.deleted_at AS s&lt;/em&gt;_deleted_at FROM soft_delete_test s WHERE (s.name = &apos;faulty&apos; OR s.name = &apos;faulty&apos; AND (s.deleted_at IS NULL))&lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;which returns also a deleted row.&lt;/p&gt;

&lt;p&gt;&lt;b&gt;Expected behavior&lt;/b&gt;&lt;/p&gt;

&lt;p&gt;One would expect the pending join conditions always to hold, and to have precedence over regularly added SQL conditions. This could be accomplished in the most simple fashion by:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;SELECT s.name AS s_&lt;em&gt;name, s.deleted_at AS s&lt;/em&gt;_deleted_at FROM soft_delete_test s WHERE ( ( s.name = &apos;faulty&apos; OR s.name = &apos;faulty&apos; ) AND (s.deleted_at IS NULL));&lt;/p&gt;&lt;/blockquote&gt;

&lt;p&gt;As the existing expressions are now encapsulated by parentheses, it is no longer possible to bypass the pending join conditions injected by the query listener.&lt;/p&gt;

&lt;p&gt;&lt;b&gt;Full test case details:&lt;/b&gt;&lt;/p&gt;

&lt;p&gt;&lt;b&gt;init.sql&lt;/b&gt;&lt;/p&gt;
&lt;div class=&quot;preformatted panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;preformattedContent panelContent&quot;&gt;
&lt;pre&gt;create database softdelete;
grant all privileges on softdelete.* to softdelete@localhost identified by &apos;uahwqeruwer&apos;;

use softdelete;
CREATE TABLE soft_delete_test (name VARCHAR(255), 
    deleted_at DATETIME DEFAULT NULL, 
    PRIMARY KEY(name)) ENGINE = INNODB;

insert into soft_delete_test values (&apos;fine&apos;, null);
insert into soft_delete_test values (&apos;faulty&apos;, now());
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;b&gt;run.php&lt;/b&gt;&lt;/p&gt;
&lt;div class=&quot;preformatted panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;preformattedContent panelContent&quot;&gt;
&lt;pre&gt;&amp;lt;?php

require &quot;./1.2.3/lib/Doctrine.php&quot;;

spl_autoload_register(array(&apos;Doctrine&apos;, &apos;autoload&apos;));

require &quot;SoftDeleteTest.php&quot;;

$conn = Doctrine_Manager::connection(&quot;mysql://softdelete:uahwqeruwer@localhost/softdelete&quot;);
$conn-&amp;gt;setAttribute(Doctrine::ATTR_USE_DQL_CALLBACKS, true);

$query = Doctrine_Query::create()
    -&amp;gt;from(&quot;SoftDeleteTest&quot;)
    -&amp;gt;where(&quot;name=?&quot;, &quot;faulty&quot;)
    -&amp;gt;orWhere(&quot;name=?&quot;, &quot;faulty&quot;);

$found = $query-&amp;gt;execute();
foreach ($found as $f) {
    echo &quot;ERROR! Found a deleted row: $f-&amp;gt;name\n&quot;;
}
echo &quot;Done.\n&quot;;
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;b&gt;SoftDeleteTest.php&lt;/b&gt; (copied from Doctrine manual)&lt;/p&gt;
&lt;div class=&quot;preformatted panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;preformattedContent panelContent&quot;&gt;
&lt;pre&gt;&amp;lt;?php

class SoftDeleteTest extends Doctrine_Record
{
    public function setTableDefinition()
    {
        $this-&amp;gt;hasColumn(&apos;name&apos;, &apos;string&apos;, null, array(
                &apos;primary&apos; =&amp;gt; true
            )
        );
    }

    public function setUp()
    {
        $this-&amp;gt;actAs(&apos;SoftDelete&apos;);
    }
}
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;</description>
                <environment>PHP 5.2, 5.3</environment>
            <key id="12189">DC-944</key>
            <summary>Precedence problem in SQL generation allows bypass of pending joins</summary>
                <type id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/bug.png">Bug</type>
                                <priority id="3" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/major.png">Major</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="guilhermeblanco">Guilherme Blanco</assignee>
                                <reporter username="walter">Walter Hop</reporter>
                        <labels>
                    </labels>
                <created>Fri, 3 Dec 2010 12:01:34 +0000</created>
                <updated>Sat, 10 Dec 2011 12:44:25 +0000</updated>
                                    <version>1.2.3</version>
                                <fixVersion>1.2.4</fixVersion>
                                <component>Query</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>1</watches>
                        <comments>
                    <comment id="14900" author="walter" created="Fri, 3 Dec 2010 12:02:23 +0000"  >&lt;p&gt;Fixing quote formatting&lt;/p&gt;</comment>
                    <comment id="14903" author="walter" created="Fri, 3 Dec 2010 12:06:05 +0000"  >&lt;p&gt;Final formatting fixes. &lt;img class=&quot;emoticon&quot; src=&quot;http://www.doctrine-project.org/jira/images/icons/emoticons/smile.gif&quot; height=&quot;20&quot; width=&quot;20&quot; align=&quot;absmiddle&quot; alt=&quot;&quot; border=&quot;0&quot;/&gt;&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                    <attachment id="11127" name="Query.pendingjoin.diff" size="1878" author="walter" created="Sat, 10 Dec 2011 12:44:25 +0000" />
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-951] Error in generating the field size and error in the generation of the date fields  for postgres</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-951</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;collaboration of vtamara@pasosdejesus.org    and  jeronimo0000@gmail.com           &lt;/p&gt;


&lt;p&gt;While we developed a tool with symfony 1.4 and postgresql database we found errors in the generated schema.yml which I describe below&lt;/p&gt;

&lt;p&gt;1 - Error in generating of field size of varchars&lt;br/&gt;
2 - Error in the generation of date fields&lt;/p&gt;

&lt;p&gt;We found the following solution&lt;/p&gt;


&lt;p&gt;&amp;#8212; Doctrine/Import/Pgsql.php.orig      2010-12-23 17:48:00.160271000 -0500&lt;br/&gt;
+++ Doctrine/Import/Pgsql.php   2010-12-23 18:01:59.252271002 -0500&lt;br/&gt;
@@ -168,11 +168,14 @@&lt;br/&gt;
         $columns     = array();&lt;br/&gt;
         foreach ($result as $key =&amp;gt; $val) {&lt;br/&gt;
             $val = array_change_key_case($val, CASE_LOWER);&lt;/p&gt;
&lt;ul class=&quot;alternate&quot; type=&quot;square&quot;&gt;
	&lt;li&gt;if (strtolower($val&lt;span class=&quot;error&quot;&gt;&amp;#91;&amp;#39;type&amp;#39;&amp;#93;&lt;/span&gt;) === &apos;character varying&apos;) {&lt;br/&gt;
+            if (strtolower($val&lt;span class=&quot;error&quot;&gt;&amp;#91;&amp;#39;type&amp;#39;&amp;#93;&lt;/span&gt;) === &apos;varchar&apos;) 
{
                 // get length from varchar definition
                 $length = preg_replace(&apos;~.*\(([0-9]*)\).*~&apos;, &apos;$1&apos;, $val[&apos;complete_type&apos;]);
                 $val[&apos;length&apos;] = $length;
             }
&lt;p&gt;+           if ($val&lt;span class=&quot;error&quot;&gt;&amp;#91;&amp;#39;type&amp;#39;&amp;#93;&lt;/span&gt; == &apos;date&apos;) &lt;/p&gt;
{
+               $val[&apos;type&apos;] = $val[&apos;complete_type&apos;] = &apos;timestamp&apos;; 
+            }&lt;/li&gt;
&lt;/ul&gt;


&lt;p&gt;             $decl = $this-&amp;gt;conn-&amp;gt;dataDict-&amp;gt;getPortableDeclaration($val);&lt;/p&gt;





</description>
                <environment>apacha2, linux, Symfony 1.4</environment>
            <key id="12252">DC-951</key>
            <summary>Error in generating the field size and error in the generation of the date fields  for postgres</summary>
                <type id="2" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/newfeature.png">New Feature</type>
                                <priority id="3" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/major.png">Major</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="jwage">Jonathan H. Wage</assignee>
                                <reporter username="jeronimo0000">fernando guerrero</reporter>
                        <labels>
                    </labels>
                <created>Fri, 24 Dec 2010 12:16:23 +0000</created>
                <updated>Fri, 24 Dec 2010 12:16:23 +0000</updated>
                                    <version>1.2.2</version>
                                <fixVersion>1.2.4</fixVersion>
                                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                                <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-1004] ATTR_TBLNAME_FORMAT not used when creating models from database</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-1004</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;if you set prefix to &quot;xyz_%s&quot; and have the model &quot;BackgroundColor&quot; it will become the table =&amp;gt; &quot;xyz_background_color&quot;&lt;br/&gt;
if you have the table &quot;xyz_background_color&quot; with unknown model and create the the model from the table, you will get =&amp;gt; &quot;XyzBackgroundColor&quot;.&lt;/p&gt;

&lt;p&gt;The fix (diff):&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;368a369,370&lt;br/&gt;
&amp;gt;         $tablePrefix = $manager-&amp;gt;getAttribute(Doctrine_Core::ATTR_TBLNAME_FORMAT);&lt;br/&gt;
&amp;gt;         &lt;br/&gt;
381d382&lt;br/&gt;
&amp;lt; &lt;br/&gt;
385c386&lt;br/&gt;
&amp;lt;               $definition&lt;span class=&quot;error&quot;&gt;&amp;#91;&amp;#39;className&amp;#39;&amp;#93;&lt;/span&gt; = Doctrine_Inflector::classify(Doctrine_Inflector::tableize($table));&lt;br/&gt;
&amp;#8212;&lt;br/&gt;
&amp;gt;               $definition&lt;span class=&quot;error&quot;&gt;&amp;#91;&amp;#39;className&amp;#39;&amp;#93;&lt;/span&gt; = Doctrine_Inflector::classify(Doctrine_Inflector::tableize(preg_replace(sprintf(&apos;/\A%s\z/&apos;, str_replace(&apos;%s&apos;, &apos;(.*?)&apos;, $tablePrefix)), &apos;$1&apos;, $table)));&lt;br/&gt;
396c397&lt;br/&gt;
&amp;lt;                       $class = Doctrine_Inflector::classify(Doctrine_Inflector::tableize($table));&lt;br/&gt;
&amp;#8212;&lt;br/&gt;
&amp;gt;                       $class = Doctrine_Inflector::classify(Doctrine_Inflector::tableize(preg_replace(sprintf(&apos;/\A%s\z/&apos;, str_replace(&apos;%s&apos;, &apos;(.*?)&apos;, $tablePrefix)), &apos;$1&apos;, $table)));&lt;/p&gt;&lt;/blockquote&gt;</description>
                <environment></environment>
            <key id="12621">DC-1004</key>
            <summary>ATTR_TBLNAME_FORMAT not used when creating models from database</summary>
                <type id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/bug.png">Bug</type>
                                <priority id="3" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/major.png">Major</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="jwage">Jonathan H. Wage</assignee>
                                <reporter username="to-rparker">Robin Parker</reporter>
                        <labels>
                    </labels>
                <created>Sun, 8 May 2011 04:34:20 +0000</created>
                <updated>Sun, 8 May 2011 04:34:52 +0000</updated>
                                    <version>1.2.3</version>
                                <fixVersion>1.2.3</fixVersion>
                <fixVersion>1.2.4</fixVersion>
                                <component>Import/Export</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                        <comments>
                    <comment id="15814" author="to-rparker" created="Sun, 8 May 2011 04:34:52 +0000"  >&lt;p&gt;The diff output as .diff&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                    <attachment id="10990" name="doctrine_bug_diff.diff" size="746" author="to-rparker" created="Sun, 8 May 2011 04:34:52 +0000" />
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-1022] Doctrine migration does not set version when MySQL autocommit is false</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-1022</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;With autocommit set to off in mysqld, &lt;tt&gt;Doctrine_Migration::setCurrentVersion()&lt;/tt&gt; does not have any effect.  This is because the method uses raw PDO calls, which are discarded without either autocommit or an explicit &lt;tt&gt;COMMIT;&lt;/tt&gt;.&lt;/p&gt;

&lt;p&gt;We patched Doctrine as in the attachment.  It works for us, but may not be the best general solution.&lt;/p&gt;

&lt;p&gt;The patch only fixes this one issue.  There are likely many areas in Doctrine that rely upon autocommit behavior in MySQL.  We will continue to look for them, and supply patches as we find them.  However, as we are only concerned about MySQL, our solutions will probably not apply to other PDO drivers.&lt;/p&gt;</description>
                <environment>RHEL 6.0, mysql 5.1.52</environment>
            <key id="12856">DC-1022</key>
            <summary>Doctrine migration does not set version when MySQL autocommit is false</summary>
                <type id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/bug.png">Bug</type>
                                <priority id="3" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/major.png">Major</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="jwage">Jonathan H. Wage</assignee>
                                <reporter username="afineman">Adam Fineman</reporter>
                        <labels>
                    </labels>
                <created>Tue, 26 Jul 2011 01:02:48 +0000</created>
                <updated>Tue, 26 Jul 2011 01:41:01 +0000</updated>
                                                    <fixVersion>1.2.4</fixVersion>
                                <component>Migrations</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>1</watches>
                                <attachments>
                    <attachment id="11040" name="migration.patch" size="501" author="afineman" created="Tue, 26 Jul 2011 01:02:48 +0000" />
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-1046] Connection MSSQL replaceBoundParamsWithInlineValuesInQuery</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-1046</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;Hello,&lt;/p&gt;

&lt;p&gt;We found a bug in Doctrine1 MSSQL Connection.&lt;br/&gt;
When you would like to use the following functionality: find(One)By(p1,p2)&lt;br/&gt;
if you use the old functionality (Symfony 1.4 support it) like this: findBy(&quot;idAnddata&quot;, array(&quot;id&quot; =&amp;gt; ..., &quot;date&quot; =&amp;gt; ..)), you got an MSSQL error, because the values wasn&apos;t changed.&lt;/p&gt;

&lt;p&gt;Please find the patch for it, I hope it helps to you as well.&lt;/p&gt;

&lt;p&gt;Kind regards&lt;br/&gt;
Peter&lt;/p&gt;</description>
                <environment>Revision: 104&lt;br/&gt;
</environment>
            <key id="13272">DC-1046</key>
            <summary>Connection MSSQL replaceBoundParamsWithInlineValuesInQuery</summary>
                <type id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/bug.png">Bug</type>
                                <priority id="3" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/major.png">Major</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="jwage">Jonathan H. Wage</assignee>
                                <reporter username="eisi">Peter Eisenberg</reporter>
                        <labels>
                    </labels>
                <created>Thu, 15 Dec 2011 13:01:23 +0000</created>
                <updated>Thu, 15 Dec 2011 13:39:29 +0000</updated>
                                                    <fixVersion>1.2.4</fixVersion>
                                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                        <comments>
                    <comment id="16988" author="eisi" created="Thu, 15 Dec 2011 13:39:29 +0000"  >&lt;p&gt;Small changes:&lt;br/&gt;
Unfortunately the notice wasn&apos;t set in my test environment, and I didn&apos;t realized this small error:&lt;/p&gt;

&lt;p&gt;please use the following instead of the original: &lt;br/&gt;
$replacement = &apos;is_null(\$value) ? \&apos;NULL\&apos; : \$this-&amp;gt;quote(\$params&lt;span class=&quot;error&quot;&gt;&amp;#91;\&amp;#39;\\1\&amp;#39;&amp;#93;&lt;/span&gt;)&apos;;&lt;/p&gt;

&lt;p&gt;another case you got the following error: Use of undefined constant xxx - assumed xxx. &lt;/p&gt;

&lt;p&gt;Kind regards,&lt;br/&gt;
Peter&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                    <attachment id="11130" name="replaceBoundParamsWithInlineValuesInQuery.patch" size="660" author="eisi" created="Thu, 15 Dec 2011 13:01:23 +0000" />
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-1048] MSSQL Connection</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-1048</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;Function spliti(); is deprecated.&lt;br/&gt;
It need to be change to (in my own opinion):&lt;/p&gt;

&lt;p&gt;$field_array = str_ireplace(&apos; as &apos;, &apos; as &apos;, $field_array);&lt;br/&gt;
$aux2 = explode(&apos; as &apos;, $field_array);&lt;/p&gt;

&lt;p&gt;thnx.&lt;/p&gt;</description>
                <environment>Microsoft Windows Server 2008 R2; IIS 7; PHP 2.3.8; Doctrine 1.2.4; Symfony 1.4.16</environment>
            <key id="13363">DC-1048</key>
            <summary>MSSQL Connection</summary>
                <type id="4" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/improvement.png">Improvement</type>
                                <priority id="3" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/major.png">Major</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="jwage">Jonathan H. Wage</assignee>
                                <reporter username="psycho-coder">Constantine Tkachenko</reporter>
                        <labels>
                    </labels>
                <created>Mon, 16 Jan 2012 08:35:40 +0000</created>
                <updated>Mon, 16 Jan 2012 08:35:40 +0000</updated>
                                    <version>1.2.4</version>
                                <fixVersion>1.2.4</fixVersion>
                                <component>Connection</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>1</watches>
                                <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-843] MSSQL - Equal-to Operator doesn&apos;t work with columns of type text in where condition [+patch]</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-843</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;Example:&lt;/p&gt;

&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;Doctrine::getTable(&apos;Ticket_DCXXX2_Model&apos;)-&amp;gt;findByUsernameAndFoo(&apos;foo&apos;, &apos;bar&apos;);
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;tt&gt;foo&lt;/tt&gt; is of type &quot;text&quot;. Doctrine generates &quot;&lt;tt&gt;where .... foo = &apos;bar&apos;&lt;/tt&gt;&quot;, but this will throw an mssql exception because you cant use the equal to operator in mssql for text and varchar types. Doctrine should consider this database related behavoir, shouldn&apos;t it?&lt;/p&gt;</description>
                <environment></environment>
            <key id="11831">DC-843</key>
            <summary>MSSQL - Equal-to Operator doesn&apos;t work with columns of type text in where condition [+patch]</summary>
                <type id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/bug.png">Bug</type>
                                <priority id="4" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/minor.png">Minor</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="jwage">Jonathan H. Wage</assignee>
                                <reporter username="enrico">Enrico Stahn</reporter>
                        <labels>
                    </labels>
                <created>Thu, 26 Aug 2010 11:16:51 +0000</created>
                <updated>Thu, 2 Sep 2010 08:21:23 +0000</updated>
                                    <version>1.2.2</version>
                <version>1.2.3</version>
                                <fixVersion>1.2.4</fixVersion>
                                <component>Connection</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                        <comments>
                    <comment id="14091" author="enrico" created="Thu, 26 Aug 2010 11:20:59 +0000"  >&lt;p&gt;TestCase added &lt;a href=&quot;http://github.com/estahn/doctrine1/compare/master...DC-843&quot; class=&quot;external-link&quot;&gt;http://github.com/estahn/doctrine1/compare/master...DC-843&lt;/a&gt;&lt;/p&gt;</comment>
                    <comment id="14114" author="enrico" created="Fri, 27 Aug 2010 11:23:57 +0000"  >&lt;p&gt;Patch added to github (see above)&lt;/p&gt;

&lt;p&gt;commit msg: &lt;a href=&quot;http://www.doctrine-project.org/jira/browse/DC-843&quot; title=&quot;MSSQL - Equal-to Operator doesn&amp;#39;t work with columns of type text in where condition [+patch]&quot;&gt;DC-843&lt;/a&gt; fix (TestCase need fix for &lt;a href=&quot;http://www.doctrine-project.org/jira/browse/DC-841&quot; title=&quot;Doctrine_Connection_Mssql::replaceBoundParamsWithInlineValuesInQuery regex failing to replace all &amp;#39;?&amp;#39; instances [patch+]&quot;&gt;DC-841&lt;/a&gt; to run successfully)&lt;/p&gt;</comment>
                    <comment id="14237" author="enrico" created="Thu, 2 Sep 2010 08:21:23 +0000"  >&lt;p&gt;I made a mistake with github, the updated branch can be found at&lt;br/&gt;
&lt;a href=&quot;http://github.com/estahn/doctrine1/tree/DC-843-2&quot; class=&quot;external-link&quot;&gt;http://github.com/estahn/doctrine1/tree/DC-843-2&lt;/a&gt;&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-852] CLONE -Fix returned type value : SQL integers to PHP integers when getting a value from the database.</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-852</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;Hi Jon,&lt;/p&gt;

&lt;p&gt;I have a request for you to improve Doctrine. When declaring a column as an integer, it seems that Doctrine returns a string when getting the value of that column. For example, if I have a &quot;status&quot; column, which can take 0, 1 or 2 as its value, Doctrine will return these values as string, which is not really logical and returning the good PHP type is the goal of an ORM. I&apos;m fond of the triple equal symbol to test a value and I did not understand why this did not work at start :&lt;/p&gt;

&lt;p&gt;// in my myModel class&lt;br/&gt;
class myModel extends Doctrine_Record&lt;br/&gt;
{&lt;br/&gt;
  const STATUS_VALIDATED = 1;&lt;/p&gt;

&lt;p&gt;  public function isValidated()&lt;/p&gt;
  {
    return self::STATUS_VALIDATED === $this-&amp;gt;getStatus();
  }
&lt;p&gt;}&lt;/p&gt;

&lt;p&gt;That&apos;s why getStatus() gives me a string instead of an integer, whereas the column is declared as an integer in my schema. I&apos;m forced to cast myself the returned value of getStatus() in my model.&lt;/p&gt;</description>
                <environment></environment>
            <key id="11863">DC-852</key>
            <summary>CLONE -Fix returned type value : SQL integers to PHP integers when getting a value from the database.</summary>
                <type id="4" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/improvement.png">Improvement</type>
                                <priority id="4" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/minor.png">Minor</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="jwage">Jonathan H. Wage</assignee>
                                <reporter username="enrico">Enrico Stahn</reporter>
                        <labels>
                    </labels>
                <created>Wed, 1 Sep 2010 08:19:12 +0000</created>
                <updated>Thu, 2 Sep 2010 08:11:23 +0000</updated>
                                    <version>1.2.3</version>
                                <fixVersion>1.2.4</fixVersion>
                                <component>Attributes</component>
                <component>Data Fixtures</component>
                <component>Native SQL</component>
                <component>Query</component>
                <component>Record</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                        <comments>
                    <comment id="14214" author="enrico" created="Wed, 1 Sep 2010 11:38:05 +0000"  >&lt;p&gt;Proposal for a solution: &lt;a href=&quot;http://github.com/estahn/doctrine1/compare/master...DC-852&quot; class=&quot;external-link&quot;&gt;http://github.com/estahn/doctrine1/compare/master...DC-852&lt;/a&gt;&lt;/p&gt;</comment>
                    <comment id="14225" author="jwage" created="Wed, 1 Sep 2010 14:46:04 +0000"  >&lt;p&gt;So if you enable this attribute you live with the fact that casting a string to an integer that is longer than php max integer will give weird results?&lt;/p&gt;</comment>
                    <comment id="14235" author="enrico" created="Thu, 2 Sep 2010 08:11:23 +0000"  >&lt;p&gt;i&apos;m far from happy with this solution. if an integer that is greater than php max int gets casted it will be casted into a value of type double. if you enable that attribute only values that could successfully casted into an integer will be casted otherwise an exception will be thrown.&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-879] MSSQL - missing function date_part() in Expression/Mssql.php [+patch]</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-879</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;Missing function date_part() in Expression/Mssql.php. I don&apos;t know why the set of expressions is different for each driver. This makes it hard to develop database independent.&lt;/p&gt;</description>
                <environment></environment>
            <key id="11977">DC-879</key>
            <summary>MSSQL - missing function date_part() in Expression/Mssql.php [+patch]</summary>
                <type id="4" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/improvement.png">Improvement</type>
                                <priority id="4" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/minor.png">Minor</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="jwage">Jonathan H. Wage</assignee>
                                <reporter username="enrico">Enrico Stahn</reporter>
                        <labels>
                    </labels>
                <created>Tue, 5 Oct 2010 04:34:09 +0000</created>
                <updated>Tue, 5 Oct 2010 04:50:00 +0000</updated>
                                    <version>1.2.2</version>
                <version>1.2.3</version>
                                <fixVersion>1.2.4</fixVersion>
                                <component>Connection</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                                <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-883] Help for Test CLI does not list available test groups</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-883</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;The CLI Test Runner is supposed to print a list of available test groups when used with the --help parameter, but this fails as the Doctrine_Test::run() method erroneously expects php sort() to return an array rather than a boolean.&lt;/p&gt;

&lt;p&gt;Fixed by &lt;a href=&quot;http://github.com/acoulton/doctrine1/tree/DC-883&quot; class=&quot;external-link&quot;&gt;http://github.com/acoulton/doctrine1/tree/DC-883&lt;/a&gt;&lt;/p&gt;</description>
                <environment></environment>
            <key id="11993">DC-883</key>
            <summary>Help for Test CLI does not list available test groups</summary>
                <type id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/bug.png">Bug</type>
                                <priority id="4" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/minor.png">Minor</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="jwage">Jonathan H. Wage</assignee>
                                <reporter username="andrewcoulton">Andrew Coulton</reporter>
                        <labels>
                    </labels>
                <created>Sun, 10 Oct 2010 18:44:36 +0000</created>
                <updated>Sun, 10 Oct 2010 18:51:17 +0000</updated>
                                    <version>1.2.3</version>
                                <fixVersion>1.2.4</fixVersion>
                                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                                <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-1003] _processWhereIn does not allow the use of named query parameters</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-1003</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;When writing a query such as &lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;$query = $query-&amp;gt;where(&apos;entity.myValue = :value&apos;, array(&apos;:value&apos;=&amp;gt;5));&lt;/p&gt;&lt;/blockquote&gt;

&lt;p&gt;you are unable to then&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;$query = $query-&amp;gt;whereIn(&apos;entity.otherValue&apos;, array(&apos;:otherValues&apos;=&amp;gt;array(1,2,3)));&lt;/p&gt;&lt;/blockquote&gt;

&lt;p&gt;Doctrine complains that you may not mix positional and named query parameters.&lt;/p&gt;

&lt;p&gt;The attached patch fixes this by checking if the key of the passed in parameter is non numeric and if so setting the &quot;value&quot; of the parameter place holder to the value of the key.&lt;/p&gt;</description>
                <environment>karmic, php 5.2.10, apache2</environment>
            <key id="12615">DC-1003</key>
            <summary>_processWhereIn does not allow the use of named query parameters</summary>
                <type id="4" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/improvement.png">Improvement</type>
                                <priority id="4" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/minor.png">Minor</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="guilhermeblanco">Guilherme Blanco</assignee>
                                <reporter username="alex.pilon">alex pilon</reporter>
                        <labels>
                    </labels>
                <created>Thu, 5 May 2011 21:22:56 +0000</created>
                <updated>Fri, 6 May 2011 00:06:42 +0000</updated>
                                                    <fixVersion>1.2.4</fixVersion>
                                <component>Query</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>1</watches>
                        <comments>
                    <comment id="15809" author="alex.pilon" created="Thu, 5 May 2011 21:59:01 +0000"  >&lt;p&gt;I discovered an issue with the above patch. I am working on a better version.&lt;/p&gt;</comment>
                    <comment id="15810" author="alex.pilon" created="Fri, 6 May 2011 00:06:42 +0000"  >&lt;p&gt;Here is a second version.. it is a little bit sloppy. Is there a resource I can find on here that will help me to improve code quality/unit test this?&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                    <attachment id="10987" name="_processWhereIn-named-parameter-v2.patch" size="884" author="alex.pilon" created="Fri, 6 May 2011 00:06:42 +0000" />
                    <attachment id="10986" name="_processWhereIn-named-parameter.patch" size="581" author="alex.pilon" created="Thu, 5 May 2011 21:22:56 +0000" />
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DC-840] MSSQL - strange behavior with multiple addWhere conditions and &quot;&gt;&quot; [+patch]</title>
                <link>http://www.doctrine-project.org/jira/browse/DC-840</link>
                <project id="10031" key="DC">Doctrine 1</project>
                        <description>&lt;p&gt;In the first example below the second parameter wasn&apos;t replaced by the given value. I tracked it down and i suppose it&apos;s because of the &quot;&amp;gt;&quot; sign. It&apos;s the same for &quot;&amp;lt;&quot;. Equal-Operator (=) works fine.&lt;/p&gt;

&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;        $q = Doctrine_Query::create()
            -&amp;gt;select(&apos;password, modified_at&apos;)
            -&amp;gt;from(&apos;Ticket_DCXXX_Model&apos;)
            -&amp;gt;andWhere(&apos;password = ?&apos;, &apos;abc&apos;)
            -&amp;gt;andWhere(&apos;modified_at &amp;gt; ?&apos;, &apos;2010-01-01&apos;)
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;
&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-sql&quot;&gt;&lt;span class=&quot;code-keyword&quot;&gt;SELECT&lt;/span&gt; [t].[id] AS [t__id], [t].[password] AS [t__password], [t].[modified_at] AS [t__modified_at]
&lt;span class=&quot;code-keyword&quot;&gt;FROM&lt;/span&gt; [ticket__d_c_x_x_x__model] [t]
&lt;span class=&quot;code-keyword&quot;&gt;WHERE&lt;/span&gt; ([t].[password] =  &apos;abc&apos; AND [t].[modified_at] &amp;gt; ?)
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;        $q = Doctrine_Query::create()
            -&amp;gt;select(&apos;password, modified_at&apos;)
            -&amp;gt;from(&apos;Ticket_DCXXX_Model&apos;)
            -&amp;gt;andWhere(&apos;modified_at &amp;gt; ?&apos;, &apos;2010-01-01&apos;)
            -&amp;gt;andWhere(&apos;password = ?&apos;, &apos;abc&apos;)
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;
&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-sql&quot;&gt;&lt;span class=&quot;code-keyword&quot;&gt;SELECT&lt;/span&gt; [t].[id] AS [t__id], [t].[password] AS [t__password], [t].[modified_at] AS [t__modified_at]
&lt;span class=&quot;code-keyword&quot;&gt;FROM&lt;/span&gt; [ticket__d_c_x_x_x__model] [t]
&lt;span class=&quot;code-keyword&quot;&gt;WHERE&lt;/span&gt; ([t].[modified_at] &amp;gt;  &apos;2010-01-01&apos; AND [t].[password] =  &apos;abc&apos;)
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;</description>
                <environment></environment>
            <key id="11823">DC-840</key>
            <summary>MSSQL - strange behavior with multiple addWhere conditions and &quot;&gt;&quot; [+patch]</summary>
                <type id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/bug.png">Bug</type>
                                <priority id="5" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/trivial.png">Trivial</priority>
                    <status id="1" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/open.png">Open</status>
                    <resolution id="-1">Unresolved</resolution>
                                <assignee username="jwage">Jonathan H. Wage</assignee>
                                <reporter username="enrico">Enrico Stahn</reporter>
                        <labels>
                    </labels>
                <created>Wed, 25 Aug 2010 11:33:42 +0000</created>
                <updated>Fri, 27 Aug 2010 11:57:19 +0000</updated>
                                    <version>1.2.2</version>
                <version>1.2.3</version>
                                <fixVersion>1.2.4</fixVersion>
                                <component>Connection</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                        <comments>
                    <comment id="14066" author="enrico" created="Wed, 25 Aug 2010 11:49:02 +0000"  >&lt;p&gt;&lt;a href=&quot;http://github.com/estahn/doctrine1/compare/master...DC-840&quot; class=&quot;external-link&quot;&gt;http://github.com/estahn/doctrine1/compare/master...DC-840&lt;/a&gt;&lt;/p&gt;</comment>
                    <comment id="14117" author="enrico" created="Fri, 27 Aug 2010 11:57:19 +0000"  >&lt;p&gt;see &lt;a href=&quot;http://www.doctrine-project.org/jira/browse/DC-841&quot; title=&quot;Doctrine_Connection_Mssql::replaceBoundParamsWithInlineValuesInQuery regex failing to replace all &amp;#39;?&amp;#39; instances [patch+]&quot;&gt;DC-841&lt;/a&gt;&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>
</channel>
</rss>