<!--
RSS generated by JIRA (5.2.7#850-sha1:b2af0c8dc8537b36121c6a579fabbdf79fc919e5) at Mon May 20 22:31:59 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=fixVersion+%3D+%222.1.7%22+AND+project+%3D+DDC&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=fixVersion+%3D+%222.1.7%22+AND+project+%3D+DDC</link>
        <description>An XML representation of a search request</description>
                <language>en-us</language>
                        <issue start="0" end="15" total="15"/>
                <build-info>
            <version>5.2.7</version>
            <build-number>850</build-number>
            <build-date>21-02-2013</build-date>
        </build-info>
<item>
            <title>[DDC-1836] [GH-356] [DDC-1835] Fix clone side effects in PersistentCollection</title>
                <link>http://www.doctrine-project.org/jira/browse/DDC-1836</link>
                <project id="10032" key="DDC">Doctrine 2 - ORM</project>
                        <description>&lt;p&gt;This issue is created automatically through a Github pull request on behalf of kdambekalns:&lt;/p&gt;

&lt;p&gt;  Url: &lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/356&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/356&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Message:&lt;/p&gt;

</description>
                <environment></environment>
            <key id="13726">DDC-1836</key>
            <summary>[GH-356] [DDC-1835] Fix clone side effects in PersistentCollection</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="5" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/resolved.png">Resolved</status>
                    <resolution id="1">Fixed</resolution>
                    <security id="10000">All</security>
                        <assignee username="beberlei">Benjamin Eberlei</assignee>
                                <reporter username="beberlei">Benjamin Eberlei</reporter>
                        <labels>
                    </labels>
                <created>Thu, 24 May 2012 16:56:24 +0000</created>
                <updated>Sun, 27 May 2012 08:18:59 +0000</updated>
                    <resolved>Sun, 27 May 2012 08:18:59 +0000</resolved>
                                            <fixVersion>2.1.7</fixVersion>
                <fixVersion>2.2.3</fixVersion>
                                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                        <comments>
                    <comment id="17988" author="beberlei" created="Sun, 27 May 2012 08:12:45 +0000"  >&lt;p&gt;A related Github Pull-Request &lt;span class=&quot;error&quot;&gt;&amp;#91;GH-356&amp;#93;&lt;/span&gt; was closed&lt;br/&gt;
&lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/356&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/356&lt;/a&gt;&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DDC-1835] Cloning PersistentCollection affects internal collection of clone source</title>
                <link>http://www.doctrine-project.org/jira/browse/DDC-1835</link>
                <project id="10032" key="DDC">Doctrine 2 - ORM</project>
                        <description>&lt;p&gt;When a PersistentCollection (PC) is loaded and is cloned before it is initialized, anything that is already in that collection will be duplicated if the collection is initialized after it has been marked dirty. The cause is a too late clone operation on the internal (Array)Collection (AC) in the PC.&lt;/p&gt;

&lt;ol&gt;
	&lt;li&gt;PC is loaded, but not initialized. The internal AC is empty.&lt;/li&gt;
	&lt;li&gt;PC is cloned. PC&apos; calls initialize() in __clone()&lt;/li&gt;
	&lt;li&gt;PC&apos; fills AC (as that has not been cloned yet)&lt;/li&gt;
	&lt;li&gt;PC&apos; clones AC&lt;/li&gt;
&lt;/ol&gt;


&lt;p&gt;As a result the AC in PC now contains elements, but PC still is uninitialized. If PC is afterwards initialized and dirty, the elements already in AC will be considered new and added again to the AC.&lt;/p&gt;

&lt;p&gt;The effect will be constraint violations in join tables due to duplicate entries.&lt;/p&gt;

&lt;p&gt;The clone method causing this has been introduced with commit &lt;a href=&quot;https://github.com/doctrine/doctrine2/commit/647bd2b2f295d2cbe7d0ee67f21be8a48bae3db5&quot; class=&quot;external-link&quot;&gt;647bd2b2f295d2cbe7d0ee67f21be8a48bae3db5&lt;/a&gt; on February 17th.&lt;/p&gt;</description>
                <environment></environment>
            <key id="13725">DDC-1835</key>
            <summary>Cloning PersistentCollection affects internal collection of clone source</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="5" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/resolved.png">Resolved</status>
                    <resolution id="1">Fixed</resolution>
                    <security id="10000">All</security>
                        <assignee username="beberlei">Benjamin Eberlei</assignee>
                                <reporter username="k-fish">Karsten Dambekalns</reporter>
                        <labels>
                    </labels>
                <created>Thu, 24 May 2012 15:27:44 +0000</created>
                <updated>Sun, 27 May 2012 08:19:11 +0000</updated>
                    <resolved>Sun, 27 May 2012 08:19:11 +0000</resolved>
                            <version>2.2</version>
                                <fixVersion>2.1.7</fixVersion>
                <fixVersion>2.2.3</fixVersion>
                                <component>ORM</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                        <comments>
                    <comment id="17980" author="k-fish" created="Thu, 24 May 2012 16:56:57 +0000"  >&lt;p&gt;Test and fix: &lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/356&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/356&lt;/a&gt;&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DDC-1801] PostgreSQL - quoting identifiers also quotes aliases</title>
                <link>http://www.doctrine-project.org/jira/browse/DDC-1801</link>
                <project id="10032" key="DDC">Doctrine 2 - ORM</project>
                        <description>&lt;p&gt;First of all, I fully agree with Roman Borshell&apos;s concept that if you want identifier to be quoted you need to do it manually in Entity by back-ticking ` ` it. &lt;/p&gt;

&lt;p&gt;That&apos;s what I did:&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;var&lt;/span&gt; string $name
     *
     * @ORM\Column(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;`Name`&quot;&lt;/span&gt;, type=&lt;span class=&quot;code-quote&quot;&gt;&quot;string&quot;&lt;/span&gt;, length=50, nullable=&lt;span class=&quot;code-keyword&quot;&gt;false&lt;/span&gt;)
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $name;

    /**
     * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; string $surname
     *
     * @ORM\Column(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;`Surname`&quot;&lt;/span&gt;, type=&lt;span class=&quot;code-quote&quot;&gt;&quot;string&quot;&lt;/span&gt;, length=50, nullable=&lt;span class=&quot;code-keyword&quot;&gt;false&lt;/span&gt;)
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $surname;
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;But when I ran a simple query&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;        $qb = $repository-&amp;gt;createQueryBuilder(&apos;p&apos;);
        $query = $qb
        -&amp;gt;select(&apos;p.name, p.surname, p.photographerguid&apos;)
        -&amp;gt;where(&lt;span class=&quot;code-quote&quot;&gt;&quot;p.name = &apos;Peter&apos;&quot;&lt;/span&gt;);
        
        echo $query-&amp;gt;getQuery()-&amp;gt;getSQL();
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;what I get is TERRIBLE output&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 p0_.&lt;span class=&quot;code-quote&quot;&gt;&quot;Name&quot;&lt;/span&gt; AS &lt;span class=&quot;code-quote&quot;&gt;&quot;Name&quot;&lt;/span&gt;0, p0_.&lt;span class=&quot;code-quote&quot;&gt;&quot;Surname&quot;&lt;/span&gt; AS &lt;span class=&quot;code-quote&quot;&gt;&quot;Surname&quot;&lt;/span&gt;1, p0_.&lt;span class=&quot;code-quote&quot;&gt;&quot;PhotographerGUID&quot;&lt;/span&gt; AS &lt;span class=&quot;code-quote&quot;&gt;&quot;PhotographerGUID&quot;&lt;/span&gt;2 FROM &lt;span class=&quot;code-quote&quot;&gt;&quot;Photographers&quot;&lt;/span&gt; p0_ WHERE p0_.&lt;span class=&quot;code-quote&quot;&gt;&quot;Name&quot;&lt;/span&gt; = &apos;Peter&apos; 
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt; 

&lt;p&gt;It also quoted identifiers like &quot;Surname&quot;1, &quot;Name&quot;0.&lt;/p&gt;

&lt;p&gt;I spent 3 hours digging your code, and finally found in Doctrine\ORM\Query\SqlWalker.php Ln: 969&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;
                $columnName = $class-&amp;gt;getQuotedColumnName($fieldName, $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;_platform);

                $columnAlias =  $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;getSQLColumnAlias($columnName);
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;You quote column and then pass it to getSQLColumnAlias which appends some number to the end.&lt;/p&gt;

&lt;p&gt;Is there a fix already in newer versions? Where can i find it then - will definitely make a port to this one.&lt;/p&gt;
</description>
                <environment>Symfony2</environment>
            <key id="13667">DDC-1801</key>
            <summary>PostgreSQL - quoting identifiers also quotes aliases</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="5" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/resolved.png">Resolved</status>
                    <resolution id="3">Duplicate</resolution>
                    <security id="10000">All</security>
                        <assignee username="beberlei">Benjamin Eberlei</assignee>
                                <reporter username="rivaros">ross neacoders</reporter>
                        <labels>
                    </labels>
                <created>Sun, 29 Apr 2012 17:50:18 +0000</created>
                <updated>Sun, 29 Apr 2012 20:30:44 +0000</updated>
                    <resolved>Sun, 29 Apr 2012 20:30:44 +0000</resolved>
                            <version>2.1.6</version>
                                <fixVersion>2.1.7</fixVersion>
                                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                        <comments>
                    <comment id="17896" author="rivaros" created="Sun, 29 Apr 2012 20:30:44 +0000"  >&lt;p&gt;Duplicate of 	&lt;a href=&quot;http://www.doctrine-project.org/jira/browse/DDC-1695&quot; title=&quot;SQLs for PostgreSQL case sensite tables/fields are wrongly generated&quot;&gt;&lt;del&gt;DDC-1695&lt;/del&gt;&lt;/a&gt;&lt;br/&gt;
(will report there)&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DDC-1799] Doctrine&apos;s Reverse Engineering 1-n (one to many) association misunderstood as 1-1 (one to one)</title>
                <link>http://www.doctrine-project.org/jira/browse/DDC-1799</link>
                <project id="10032" key="DDC">Doctrine 2 - ORM</project>
                        <description>&lt;p&gt;I found an odd behaviour of Doctrine&apos;s reverse engineering process, just create two simple tables tied by a simple 1-n relationship, take a look at the snap of the folowing SQL code:&lt;/p&gt;
&lt;div class=&quot;code panel&quot; style=&quot;border-style: solid;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;    SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0;
    SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0;
    SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE=&apos;TRADITIONAL&apos;;
    
    DROP SCHEMA IF EXISTS `ACME` ;
    CREATE SCHEMA IF NOT EXISTS `ACME` DEFAULT CHARACTER SET latin1 COLLATE latin1_swedish_ci ;
    USE `ACME` ;
    
    -- -----------------------------------------------------
    -- Table `ACME`.`task`
    -- -----------------------------------------------------
    DROP TABLE IF EXISTS `ACME`.`task` ;
    
    CREATE  TABLE IF NOT EXISTS `ACME`.`task` (
      `id_task` INT UNSIGNED NOT NULL AUTO_INCREMENT ,
      `description` VARCHAR(45) NULL ,
      PRIMARY KEY (`id_task`) )
    ENGINE = InnoDB;
    
    
    -- -----------------------------------------------------
    -- Table `ACME`.`tag`
    -- -----------------------------------------------------
    DROP TABLE IF EXISTS `ACME`.`tag` ;
    
    CREATE  TABLE IF NOT EXISTS `ACME`.`tag` (
      `id_tag` INT UNSIGNED NOT NULL AUTO_INCREMENT ,
      `name` VARCHAR(50) NULL ,
      `task_id` INT UNSIGNED NOT NULL ,
      PRIMARY KEY (`id_tag`) ,
      INDEX `fk_tag_task` (`task_id` ASC) ,
      CONSTRAINT `fk_tag_task`
        FOREIGN KEY (`task_id` )
        REFERENCES `ACME`.`task` (`id_task` )
        ON DELETE NO ACTION
        ON UPDATE NO ACTION)
    ENGINE = InnoDB;
    
    
    
    SET SQL_MODE=@OLD_SQL_MODE;
    SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS;
    SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS;
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;I have a Symfony2 netbeans project at &lt;/p&gt;

&lt;p&gt;&amp;gt; /Applications/MAMP/htdocs/Acme&lt;/p&gt;

&lt;p&gt; and from that location, according to &lt;/p&gt;

&lt;p&gt;&amp;gt; &lt;a href=&quot;http://symfony.com/doc/current/cookbook/doctrine/reverse_engineering.html&quot; class=&quot;external-link&quot;&gt;http://symfony.com/doc/current/cookbook/doctrine/reverse_engineering.html&lt;/a&gt;&lt;/p&gt;

&lt;p&gt; in a terminal I did:&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;    $ ./../../bin/php/php5.3.6/bin/php app/console doctrine:mapping:convert yml ./src/Acme/TaskBundle/Resources/config/doctrine/ --from-database --force
    Processing entity &lt;span class=&quot;code-quote&quot;&gt;&quot;Tag&quot;&lt;/span&gt;
    Processing entity &lt;span class=&quot;code-quote&quot;&gt;&quot;Task&quot;&lt;/span&gt;
    
    Exporting &lt;span class=&quot;code-quote&quot;&gt;&quot;yml&quot;&lt;/span&gt; mapping information to &lt;span class=&quot;code-quote&quot;&gt;&quot;/Applications/MAMP/htdocs/Acme/src/Acme/TaskBundle/Resources/config/doctrine&quot;&lt;/span&gt;
    
    $ ./../../bin/php/php5.3.6/bin/php app/console doctrine:mapping:&lt;span class=&quot;code-keyword&quot;&gt;import&lt;/span&gt; Acme\TaskBundle yml
    Importing mapping information from &lt;span class=&quot;code-quote&quot;&gt;&quot;&lt;span class=&quot;code-keyword&quot;&gt;default&lt;/span&gt;&quot;&lt;/span&gt; entity manager
      &amp;gt; writing /Applications/MAMP/htdocs/Acme/src/Acme/TaskBundle/Resources/config/doctrine/Tag.orm.yml
      &amp;gt; writing /Applications/MAMP/htdocs/Acme/src/Acme/TaskBundle/Resources/config/doctrine/Task.orm.yml
    
    $ ./../../bin/php/php5.3.6/bin/php app/console doctrine:generate:entities Acme\TaskBundle
    Generating entities &lt;span class=&quot;code-keyword&quot;&gt;for&lt;/span&gt; bundle &lt;span class=&quot;code-quote&quot;&gt;&quot;AcmeTaskBundle&quot;&lt;/span&gt;
      &amp;gt; backing up Tag.php to Tag.php~
      &amp;gt; generating Acme\TaskBundle\Entity\Tag
      &amp;gt; backing up Task.php to Task.php~
      &amp;gt; generating Acme\TaskBundle\Entity\Task
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;The fact is that it only seems ok, because if you take a look at &quot;Tag.orm.yml&quot;: &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;Tag.orm.yml&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;    Acme\TaskBundle\Entity\Tag:
      type: entity
      table: tag
      fields:
        idTag:
          id: &lt;span class=&quot;code-keyword&quot;&gt;true&lt;/span&gt;
          type: integer
          unsigned: &lt;span class=&quot;code-keyword&quot;&gt;false&lt;/span&gt;
          nullable: &lt;span class=&quot;code-keyword&quot;&gt;false&lt;/span&gt;
          column: id_tag
          generator:
            strategy: IDENTITY
        name:
          type: string
          length: 50
          fixed: &lt;span class=&quot;code-keyword&quot;&gt;false&lt;/span&gt;
          nullable: &lt;span class=&quot;code-keyword&quot;&gt;true&lt;/span&gt;
      oneToOne:
        task:
          targetEntity: Task
          cascade: {  }
          mappedBy: &lt;span class=&quot;code-keyword&quot;&gt;null&lt;/span&gt;
          inversedBy: &lt;span class=&quot;code-keyword&quot;&gt;null&lt;/span&gt;
          joinColumns:
            task_id:
              referencedColumnName: id_task
          orphanRemoval: &lt;span class=&quot;code-keyword&quot;&gt;false&lt;/span&gt;
      lifecycleCallbacks: {  }
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;It created a *&lt;b&gt;oneToOne&lt;/b&gt;* relationship and not a *&lt;b&gt;oneToMany&lt;/b&gt;* !&lt;/p&gt;

&lt;p&gt;If you need any more confirmation, here are **&lt;b&gt;Task.php&lt;/b&gt;** and **&lt;b&gt;Tag.php&lt;/b&gt;**:&lt;/p&gt;

&lt;p&gt;**&lt;b&gt;Task.php&lt;/b&gt;**&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;Task.php&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;    &amp;lt;?php
    
    namespace Acme\TaskBundle\Entity;
    
    use Doctrine\ORM\Mapping as ORM;
    
    /**
     * Acme\TaskBundle\Entity\Task
     */
    class Task
    {
        /**
         * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; integer $idTask
         */
        &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $idTask;
    
        /**
         * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; string $description
         */
        &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $description;
    
    
        /**
         * Get idTask
         *
         * @&lt;span class=&quot;code-keyword&quot;&gt;return&lt;/span&gt; integer 
         */
        &lt;span class=&quot;code-keyword&quot;&gt;public&lt;/span&gt; function getIdTask()
        {
            &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;idTask;
        }
    
        /**
         * Set description
         *
         * @param string $description
         */
        &lt;span class=&quot;code-keyword&quot;&gt;public&lt;/span&gt; function setDescription($description)
        {
            $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;description = $description;
        }
    
        /**
         * Get description
         *
         * @&lt;span class=&quot;code-keyword&quot;&gt;return&lt;/span&gt; string 
         */
        &lt;span class=&quot;code-keyword&quot;&gt;public&lt;/span&gt; function getDescription()
        {
            &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;description;
        }
    }
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&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;Tag.php&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;***Tag.php***

    &amp;lt;?php
    
    namespace Acme\TaskBundle\Entity;
    
    use Doctrine\ORM\Mapping as ORM;
    
    /**
     * Acme\TaskBundle\Entity\Tag
     */
    class Tag
    {
        /**
         * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; integer $idTag
         */
        &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $idTag;
    
        /**
         * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; string $name
         */
        &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $name;
    
        /**
         * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; Acme\TaskBundle\Entity\Task
         */
        &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $task;
    
    
        /**
         * Get idTag
         *
         * @&lt;span class=&quot;code-keyword&quot;&gt;return&lt;/span&gt; integer 
         */
        &lt;span class=&quot;code-keyword&quot;&gt;public&lt;/span&gt; function getIdTag()
        {
            &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;idTag;
        }
    
        /**
         * Set name
         *
         * @param string $name
         */
        &lt;span class=&quot;code-keyword&quot;&gt;public&lt;/span&gt; function setName($name)
        {
            $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;name = $name;
        }
    
        /**
         * Get name
         *
         * @&lt;span class=&quot;code-keyword&quot;&gt;return&lt;/span&gt; string 
         */
        &lt;span class=&quot;code-keyword&quot;&gt;public&lt;/span&gt; function getName()
        {
            &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;name;
        }
    
        /**
         * Set task
         *
         * @param Acme\TaskBundle\Entity\Task $task
         */
        &lt;span class=&quot;code-keyword&quot;&gt;public&lt;/span&gt; function setTask(\Acme\TaskBundle\Entity\Task $task)
        {
            $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;task = $task;
        }
    
        /**
         * Get task
         *
         * @&lt;span class=&quot;code-keyword&quot;&gt;return&lt;/span&gt; Acme\TaskBundle\Entity\Task 
         */
        &lt;span class=&quot;code-keyword&quot;&gt;public&lt;/span&gt; function getTask()
        {
            &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;task;
        }
    }
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;linuxatico&lt;/p&gt;</description>
                <environment>MAC OS X 10.6.8, Symfony 2.0.12, PHP 5.3.6, mysql server 5.5.9</environment>
            <key id="13663">DDC-1799</key>
            <summary>Doctrine&apos;s Reverse Engineering 1-n (one to many) association misunderstood as 1-1 (one to one)</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="5" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/resolved.png">Resolved</status>
                    <resolution id="1">Fixed</resolution>
                    <security id="10000">All</security>
                        <assignee username="beberlei">Benjamin Eberlei</assignee>
                                <reporter username="linuxatico">simone adami</reporter>
                        <labels>
                    </labels>
                <created>Fri, 27 Apr 2012 10:46:30 +0000</created>
                <updated>Sun, 27 May 2012 08:02:46 +0000</updated>
                    <resolved>Sun, 27 May 2012 08:02:46 +0000</resolved>
                            <version>2.1.6</version>
                                <fixVersion>2.1.7</fixVersion>
                <fixVersion>2.2.3</fixVersion>
                                <component>ORM</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>1</watches>
                        <comments>
                    <comment id="17897" author="linuxatico" created="Mon, 30 Apr 2012 07:55:50 +0000"  >&lt;p&gt;This problem is encountered only in this case, 1-1 and n-m relationship are handled in the right way, has anyone else faced this problem too?&lt;/p&gt;

&lt;p&gt;linuxatico&lt;/p&gt;</comment>
                    <comment id="17931" author="linuxatico" created="Mon, 7 May 2012 12:41:27 +0000"  >&lt;p&gt;Hi all,&lt;br/&gt;
I wanna give the Doctrine community my full support to help fixing this bug, but I need someone who can give me an answer.....&lt;br/&gt;
I couldn&apos;t figure out in the source code which is the method executed when given the command &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;$ ./../../bin/php/php5.3.6/bin/php app/console doctrine:mapping:convert yml ./src/Acme/TaskBundle/Resources/config/doctrine/ --from-database --force&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;I will keep on looking for it, but some help will be appreciated,&lt;/p&gt;

&lt;p&gt;linuxatico&lt;/p&gt;</comment>
                    <comment id="17932" author="linuxatico" created="Mon, 7 May 2012 12:52:21 +0000"  >&lt;p&gt;Found in vendor/doctrine/lib/Doctrine/ORM/Tools/Console/Command/ConvertMappingCommand.php&lt;br/&gt;
I&apos;ll see what I can do.&lt;/p&gt;

&lt;p&gt;linuxatico&lt;/p&gt;</comment>
                    <comment id="17936" author="linuxatico" created="Wed, 9 May 2012 10:43:38 +0000"  >&lt;p&gt;Even if I keep being ignored, I want to report a very useful discovery about this annoying bug: it&apos;s 100% related to the YAML conversion, because if you execute the first command &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; $ ./../../bin/php/php5.3.6/bin/php app/console doctrine:mapping:convert xml ./src/Acme/TaskBundle/Resources/config/doctrine/ --from-database --force&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Using XML instead of YML it works in the expected way. I wonder if the author of this code have written a unit test before integrating this function in the official release of Doctrine.... (ironic question)&lt;/p&gt;

&lt;p&gt;linuxatico&lt;/p&gt;</comment>
                    <comment id="17984" author="beberlei" created="Sun, 27 May 2012 08:02:46 +0000"  >&lt;p&gt;This case was indeed not unit-tested, many-to-one and one-to-one were handled the same in YAML Exporter. No need to get picky about it though, we are investing our free time here.&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DDC-1770] Select from multiple subclassed entities generates SQL syntax error</title>
                <link>http://www.doctrine-project.org/jira/browse/DDC-1770</link>
                <project id="10032" key="DDC">Doctrine 2 - ORM</project>
                        <description>&lt;p&gt;I have 2 entities subclassing a &quot;master&quot; entity using single table inheritance:&lt;/p&gt;

&lt;p&gt;HistoryItem:&lt;br/&gt;
     createdAt  datetime&lt;/p&gt;

&lt;p&gt;PhotoHistoryItem extends HistoryItem&lt;br/&gt;
    photo: (foreign key to Photo entity)&lt;/p&gt;

&lt;p&gt;CommentHistoryItem extends HistoryItem&lt;br/&gt;
    comment: (foreign key to Comment entity)&lt;/p&gt;

&lt;p&gt;I want to select all of them using the following DQL:&lt;/p&gt;

&lt;p&gt;SELECT p, c FROM ProFolioBundle:PhotoHistoryItem p, ProFolioBundle:CommentHistoryItem c LEFT JOIN p.photo LEFT JOIN c.comment&lt;/p&gt;

&lt;p&gt;But the generated SQL has an error in the final AND syntax (it generates &quot;AND AND&quot;):&lt;/p&gt;

&lt;p&gt;SELECT h0_.id AS id0, h0_.createdAt AS createdAt1, h1_.id AS id2, h1_.createdAt AS createdAt3, h0_.type AS type4, h1_.type AS type5 FROM HistoryItem h0_, HistoryItem h1_ LEFT JOIN Photo p2_ ON h0_.photo_id = p2_.id INNER JOIN Comment c3_ ON h1_.comment_id = c3_.id WHERE (h0_.type IN (&apos;photo&apos;) AND AND h1_.type IN (&apos;comment&apos;)) LIMIT 20&lt;/p&gt;

&lt;p&gt;The error MySQL throws is:&lt;/p&gt;

&lt;p&gt;SQLSTATE&lt;span class=&quot;error&quot;&gt;&amp;#91;42000&amp;#93;&lt;/span&gt;: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near &apos;AND h1_.type IN (&apos;comment&apos;)) LIMIT 20&apos; at line 1 &lt;/p&gt;</description>
                <environment>Symfony 2.0.12&lt;br/&gt;
PHP 5.3.10&lt;br/&gt;
MySQL 5.1</environment>
            <key id="13616">DDC-1770</key>
            <summary>Select from multiple subclassed entities generates SQL syntax error</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="5" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/resolved.png">Resolved</status>
                    <resolution id="1">Fixed</resolution>
                    <security id="10000">All</security>
                        <assignee username="beberlei">Benjamin Eberlei</assignee>
                                <reporter username="nlaplante">Nicolas Laplante</reporter>
                        <labels>
                    </labels>
                <created>Thu, 5 Apr 2012 22:56:20 +0000</created>
                <updated>Sun, 27 May 2012 17:58:16 +0000</updated>
                    <resolved>Sun, 27 May 2012 17:58:16 +0000</resolved>
                            <version>2.1.6</version>
                                <fixVersion>2.1.7</fixVersion>
                                <component>DQL</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>2</watches>
                        <comments>
                    <comment id="17779" author="nlaplante" created="Thu, 5 Apr 2012 22:57:50 +0000"  >&lt;p&gt;Fix entity names&lt;/p&gt;</comment>
                    <comment id="17856" author="fabio.bat.silva" created="Tue, 17 Apr 2012 01:56:22 +0000"  >&lt;p&gt;Hi Nicolas&lt;/p&gt;

&lt;p&gt;Could you attach your entities please ?&lt;/p&gt;</comment>
                    <comment id="17857" author="nlaplante" created="Tue, 17 Apr 2012 03:03:48 +0000"  >&lt;p&gt;Sure, here are the 3 entities&lt;/p&gt;</comment>
                    <comment id="17858" author="nlaplante" created="Tue, 17 Apr 2012 03:06:45 +0000"  >&lt;p&gt;Here are the referenced entities in case you need them too&lt;/p&gt;</comment>
                    <comment id="18017" author="beberlei" created="Sun, 27 May 2012 17:58:16 +0000"  >&lt;p&gt;Fixed&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                    <attachment id="11183" name="Comment.php" size="4901" author="nlaplante" created="Tue, 17 Apr 2012 03:06:45 +0000" />
                    <attachment id="11180" name="CommentHistoryItem.php" size="911" author="nlaplante" created="Tue, 17 Apr 2012 03:03:48 +0000" />
                    <attachment id="11179" name="HistoryItem.php" size="1485" author="nlaplante" created="Tue, 17 Apr 2012 03:03:48 +0000" />
                    <attachment id="11182" name="Photo.php" size="10332" author="nlaplante" created="Tue, 17 Apr 2012 03:06:45 +0000" />
                    <attachment id="11181" name="PhotoHistoryItem.php" size="882" author="nlaplante" created="Tue, 17 Apr 2012 03:03:48 +0000" />
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DDC-1764] [GH-326] 2.1.x setDiscriminatorMap fix</title>
                <link>http://www.doctrine-project.org/jira/browse/DDC-1764</link>
                <project id="10032" key="DDC">Doctrine 2 - ORM</project>
                        <description>&lt;p&gt;This issue is created automatically through a Github pull request on behalf of smatyas:&lt;/p&gt;

&lt;p&gt;  Url: &lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/326&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/326&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Message:&lt;/p&gt;

&lt;p&gt;Fixing a bug when calling setDiscriminatorMap from multiple sources (ie: from Events::loadClassMetadata and annotation).&lt;/p&gt;

&lt;p&gt;&lt;a href=&quot;http://www.doctrine-project.org/jira/browse/DDC-1763&quot; class=&quot;external-link&quot;&gt;http://www.doctrine-project.org/jira/browse/DDC-1763&lt;/a&gt;&lt;/p&gt;</description>
                <environment></environment>
            <key id="13605">DDC-1764</key>
            <summary>[GH-326] 2.1.x setDiscriminatorMap fix</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="5" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/resolved.png">Resolved</status>
                    <resolution id="1">Fixed</resolution>
                    <security id="10000">All</security>
                        <assignee username="beberlei">Benjamin Eberlei</assignee>
                                <reporter username="beberlei">Benjamin Eberlei</reporter>
                        <labels>
                    </labels>
                <created>Wed, 4 Apr 2012 13:48:13 +0000</created>
                <updated>Sat, 7 Apr 2012 07:47:42 +0000</updated>
                    <resolved>Sat, 7 Apr 2012 07:47:42 +0000</resolved>
                                            <fixVersion>2.1.7</fixVersion>
                <fixVersion>2.2.2</fixVersion>
                <fixVersion>2.3</fixVersion>
                                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                        <comments>
                    <comment id="17742" author="beberlei" created="Wed, 4 Apr 2012 13:49:33 +0000"  >&lt;p&gt;A related Github Pull-Request &lt;span class=&quot;error&quot;&gt;&amp;#91;GH-327&amp;#93;&lt;/span&gt; was opened&lt;br/&gt;
&lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/327&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/327&lt;/a&gt;&lt;/p&gt;</comment>
                    <comment id="17743" author="beberlei" created="Wed, 4 Apr 2012 13:52:21 +0000"  >&lt;p&gt;A related Github Pull-Request &lt;span class=&quot;error&quot;&gt;&amp;#91;GH-328&amp;#93;&lt;/span&gt; was opened&lt;br/&gt;
&lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/328&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/328&lt;/a&gt;&lt;/p&gt;</comment>
                    <comment id="17750" author="beberlei" created="Wed, 4 Apr 2012 19:59:03 +0000"  >&lt;p&gt;A related Github Pull-Request &lt;span class=&quot;error&quot;&gt;&amp;#91;GH-328&amp;#93;&lt;/span&gt; was synchronize&lt;br/&gt;
&lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/328&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/328&lt;/a&gt;&lt;/p&gt;</comment>
                    <comment id="17782" author="beberlei" created="Fri, 6 Apr 2012 13:50:36 +0000"  >&lt;p&gt;A related Github Pull-Request &lt;span class=&quot;error&quot;&gt;&amp;#91;GH-328&amp;#93;&lt;/span&gt; was synchronize&lt;br/&gt;
&lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/328&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/328&lt;/a&gt;&lt;/p&gt;</comment>
                    <comment id="17804" author="beberlei" created="Sat, 7 Apr 2012 07:12:38 +0000"  >&lt;p&gt;A related Github Pull-Request &lt;span class=&quot;error&quot;&gt;&amp;#91;GH-327&amp;#93;&lt;/span&gt; was synchronize&lt;br/&gt;
&lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/327&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/327&lt;/a&gt;&lt;/p&gt;</comment>
                    <comment id="17813" author="beberlei" created="Sat, 7 Apr 2012 07:21:03 +0000"  >&lt;p&gt;A related Github Pull-Request &lt;span class=&quot;error&quot;&gt;&amp;#91;GH-328&amp;#93;&lt;/span&gt; was synchronize&lt;br/&gt;
&lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/328&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/328&lt;/a&gt;&lt;/p&gt;</comment>
                    <comment id="17824" author="beberlei" created="Sat, 7 Apr 2012 07:44:23 +0000"  >&lt;p&gt;A related Github Pull-Request &lt;span class=&quot;error&quot;&gt;&amp;#91;GH-327&amp;#93;&lt;/span&gt; was closed&lt;br/&gt;
&lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/327&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/327&lt;/a&gt;&lt;/p&gt;</comment>
                    <comment id="17825" author="beberlei" created="Sat, 7 Apr 2012 07:44:34 +0000"  >&lt;p&gt;A related Github Pull-Request &lt;span class=&quot;error&quot;&gt;&amp;#91;GH-328&amp;#93;&lt;/span&gt; was closed&lt;br/&gt;
&lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/328&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/328&lt;/a&gt;&lt;/p&gt;</comment>
                    <comment id="17826" author="beberlei" created="Sat, 7 Apr 2012 07:47:27 +0000"  >&lt;p&gt;A related Github Pull-Request &lt;span class=&quot;error&quot;&gt;&amp;#91;GH-326&amp;#93;&lt;/span&gt; was closed&lt;br/&gt;
&lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/326&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/326&lt;/a&gt;&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DDC-1763] Fixing a bug when calling setDiscriminatorMap from multiple sources (ie: from Events::loadClassMetadata and annotation).</title>
                <link>http://www.doctrine-project.org/jira/browse/DDC-1763</link>
                <project id="10032" key="DDC">Doctrine 2 - ORM</project>
                        <description>&lt;p&gt;We tried to set discriminator map in &lt;a href=&quot;https://github.com/Netpositive/NetpositiveDiscriminatorMapBundle&quot; class=&quot;external-link&quot;&gt;https://github.com/Netpositive/NetpositiveDiscriminatorMapBundle&lt;/a&gt; both from Events::loadClassMetadata and annotation.&lt;/p&gt;

&lt;p&gt;Pull request created on 2.1.x, 2.2, master branches.&lt;/p&gt;</description>
                <environment></environment>
            <key id="13604">DDC-1763</key>
            <summary>Fixing a bug when calling setDiscriminatorMap from multiple sources (ie: from Events::loadClassMetadata and annotation).</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="5" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/resolved.png">Resolved</status>
                    <resolution id="1">Fixed</resolution>
                    <security id="10000">All</security>
                        <assignee username="beberlei">Benjamin Eberlei</assignee>
                                <reporter username="smatyas">Matyas Somfai</reporter>
                        <labels>
                    </labels>
                <created>Wed, 4 Apr 2012 13:45:43 +0000</created>
                <updated>Sat, 7 Apr 2012 07:48:16 +0000</updated>
                    <resolved>Sat, 7 Apr 2012 07:48:16 +0000</resolved>
                            <version>2.1.6</version>
                <version>2.2</version>
                <version>Git Master</version>
                                <fixVersion>2.1.7</fixVersion>
                <fixVersion>2.2.2</fixVersion>
                <fixVersion>2.3</fixVersion>
                                <component>ORM</component>
                        <due></due>
                    <votes>1</votes>
                        <watches>1</watches>
                        <comments>
                    <comment id="17772" author="burci" created="Thu, 5 Apr 2012 11:02:43 +0000"  >&lt;p&gt;Pull requests:&lt;/p&gt;

&lt;p&gt;&lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/326&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/326&lt;/a&gt;&lt;br/&gt;
&lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/327&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/327&lt;/a&gt;&lt;br/&gt;
&lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/328&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/328&lt;/a&gt;&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DDC-1745] [GH-316] Fixes autoloading of generated Annotations </title>
                <link>http://www.doctrine-project.org/jira/browse/DDC-1745</link>
                <project id="10032" key="DDC">Doctrine 2 - ORM</project>
                        <description>&lt;p&gt;This issue is created automatically through a Github pull request on behalf of fixe:&lt;/p&gt;

&lt;p&gt;  Url: &lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/316&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/316&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Message:&lt;/p&gt;

&lt;p&gt;This PR fixes an &lt;span class=&quot;error&quot;&gt;&amp;#91;issue&amp;#93;&lt;/span&gt;(&lt;a href=&quot;https://github.com/symfony/symfony/issues/3752&quot; class=&quot;external-link&quot;&gt;https://github.com/symfony/symfony/issues/3752&lt;/a&gt;) submited by @Venzon.&lt;/p&gt;</description>
                <environment></environment>
            <key id="13583">DDC-1745</key>
            <summary>[GH-316] Fixes autoloading of generated Annotations </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="5" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/resolved.png">Resolved</status>
                    <resolution id="1">Fixed</resolution>
                    <security id="10000">All</security>
                        <assignee username="beberlei">Benjamin Eberlei</assignee>
                                <reporter username="beberlei">Benjamin Eberlei</reporter>
                        <labels>
                    </labels>
                <created>Sun, 1 Apr 2012 01:01:46 +0000</created>
                <updated>Mon, 16 Apr 2012 16:52:20 +0000</updated>
                    <resolved>Mon, 16 Apr 2012 16:52:20 +0000</resolved>
                                            <fixVersion>2.1.7</fixVersion>
                <fixVersion>2.2.3</fixVersion>
                                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                        <comments>
                    <comment id="17707" author="beberlei" created="Sun, 1 Apr 2012 09:02:14 +0000"  >&lt;p&gt;A related Github Pull-Request &lt;span class=&quot;error&quot;&gt;&amp;#91;GH-316&amp;#93;&lt;/span&gt; was synchronize&lt;br/&gt;
&lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/316&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/316&lt;/a&gt;&lt;/p&gt;</comment>
                    <comment id="17745" author="beberlei" created="Wed, 4 Apr 2012 19:59:01 +0000"  >&lt;p&gt;A related Github Pull-Request &lt;span class=&quot;error&quot;&gt;&amp;#91;GH-316&amp;#93;&lt;/span&gt; was synchronize&lt;br/&gt;
&lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/316&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/316&lt;/a&gt;&lt;/p&gt;</comment>
                    <comment id="17789" author="beberlei" created="Fri, 6 Apr 2012 13:50:37 +0000"  >&lt;p&gt;A related Github Pull-Request &lt;span class=&quot;error&quot;&gt;&amp;#91;GH-316&amp;#93;&lt;/span&gt; was synchronize&lt;br/&gt;
&lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/316&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/316&lt;/a&gt;&lt;/p&gt;</comment>
                    <comment id="17811" author="beberlei" created="Sat, 7 Apr 2012 07:21:03 +0000"  >&lt;p&gt;A related Github Pull-Request &lt;span class=&quot;error&quot;&gt;&amp;#91;GH-316&amp;#93;&lt;/span&gt; was synchronize&lt;br/&gt;
&lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/316&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/316&lt;/a&gt;&lt;/p&gt;</comment>
                    <comment id="17853" author="beberlei" created="Mon, 16 Apr 2012 16:52:20 +0000"  >&lt;p&gt;Fixed&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DDC-1695] SQLs for PostgreSQL case sensite tables/fields are wrongly generated</title>
                <link>http://www.doctrine-project.org/jira/browse/DDC-1695</link>
                <project id="10032" key="DDC">Doctrine 2 - ORM</project>
                        <description>&lt;p&gt;The SQLs for case sensitive schemas in postgreSQL are wronly generated.&lt;/p&gt;

&lt;p&gt;Example:&lt;br/&gt;
Schema:&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;CREATE TABLE &lt;span class=&quot;code-quote&quot;&gt;&quot;News&quot;&lt;/span&gt; (
  &lt;span class=&quot;code-quote&quot;&gt;&quot;IdNews&quot;&lt;/span&gt; serial NOT NULL,
  &lt;span class=&quot;code-quote&quot;&gt;&quot;IdUser&quot;&lt;/span&gt; bigint NOT NULL,
  &lt;span class=&quot;code-quote&quot;&gt;&quot;IdLanguage&quot;&lt;/span&gt; integer NOT NULL,
  &lt;span class=&quot;code-quote&quot;&gt;&quot;IdCondition&quot;&lt;/span&gt; integer,
  &lt;span class=&quot;code-quote&quot;&gt;&quot;IdHealthProvider&quot;&lt;/span&gt; integer,
  &lt;span class=&quot;code-quote&quot;&gt;&quot;IdSpeciality&quot;&lt;/span&gt; integer,
  &lt;span class=&quot;code-quote&quot;&gt;&quot;IdMedicineType&quot;&lt;/span&gt; integer,
  &lt;span class=&quot;code-quote&quot;&gt;&quot;IdTreatment&quot;&lt;/span&gt; integer,
  &lt;span class=&quot;code-quote&quot;&gt;&quot;Title&quot;&lt;/span&gt; character varying,
  &lt;span class=&quot;code-quote&quot;&gt;&quot;SmallText&quot;&lt;/span&gt; character varying,
  &lt;span class=&quot;code-quote&quot;&gt;&quot;LongText&quot;&lt;/span&gt; character varying,
  &lt;span class=&quot;code-quote&quot;&gt;&quot;PublishDate&quot;&lt;/span&gt; timestamp with time zone,
  &lt;span class=&quot;code-quote&quot;&gt;&quot;IdxNews&quot;&lt;/span&gt; tsvector,
  &lt;span class=&quot;code-quote&quot;&gt;&quot;Highlight&quot;&lt;/span&gt; &lt;span class=&quot;code-object&quot;&gt;boolean&lt;/span&gt; NOT NULL DEFAULT &lt;span class=&quot;code-keyword&quot;&gt;false&lt;/span&gt;,
  &lt;span class=&quot;code-quote&quot;&gt;&quot;Order&quot;&lt;/span&gt; integer NOT NULL DEFAULT 0,
  &lt;span class=&quot;code-quote&quot;&gt;&quot;Deleted&quot;&lt;/span&gt; &lt;span class=&quot;code-object&quot;&gt;boolean&lt;/span&gt; NOT NULL DEFAULT &lt;span class=&quot;code-keyword&quot;&gt;false&lt;/span&gt;,
  &lt;span class=&quot;code-quote&quot;&gt;&quot;Active&quot;&lt;/span&gt; &lt;span class=&quot;code-object&quot;&gt;boolean&lt;/span&gt; NOT NULL DEFAULT &lt;span class=&quot;code-keyword&quot;&gt;false&lt;/span&gt;,
  &lt;span class=&quot;code-quote&quot;&gt;&quot;UpdateToHighlighted&quot;&lt;/span&gt; &lt;span class=&quot;code-object&quot;&gt;boolean&lt;/span&gt; DEFAULT &lt;span class=&quot;code-keyword&quot;&gt;false&lt;/span&gt;,
  CONSTRAINT &lt;span class=&quot;code-quote&quot;&gt;&quot;News_pkey&quot;&lt;/span&gt; PRIMARY KEY (&lt;span class=&quot;code-quote&quot;&gt;&quot;IdNews&quot;&lt;/span&gt; ));
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Object (I added quotes trying to generate the SQLs quoted.:&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;&amp;lt;?php

namespace GlobalTreatments\ApplicationBundle\Entity;

use Doctrine\ORM\Mapping as ORM;

/**
 * @ORM\Table(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;News&quot;&lt;/span&gt;&quot;&quot;)
 * @ORM\Entity
 */
class News
{
    /**
     * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; integer $idNews
     *
     * @ORM\Column(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;IdNews&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;, type=&quot;&lt;/span&gt;integer&quot;, nullable=&lt;span class=&quot;code-keyword&quot;&gt;false&lt;/span&gt;)
     * @ORM\Id
     * @ORM\GeneratedValue(strategy=&lt;span class=&quot;code-quote&quot;&gt;&quot;SEQUENCE&quot;&lt;/span&gt;)
     * @ORM\SequenceGenerator(sequenceName=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;News_IdNews_seq&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;, allocationSize=&quot;&lt;/span&gt;1&lt;span class=&quot;code-quote&quot;&gt;&quot;, initialValue=&quot;&lt;/span&gt;1&quot;)
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $idNews;

    /**
     * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; bigint $iduser
     *
     * @ORM\Column(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;IdUser&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;, type=&quot;&lt;/span&gt;bigint&quot;, nullable=&lt;span class=&quot;code-keyword&quot;&gt;false&lt;/span&gt;)
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $idUser;

    /**
     * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; integer $idLanguage
     *
     * @ORM\Column(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;IdLanguage&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;, type=&quot;&lt;/span&gt;integer&quot;, nullable=&lt;span class=&quot;code-keyword&quot;&gt;false&lt;/span&gt;)
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $idLanguage;

    /**
     * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; integer $idCondition
     *
     * @ORM\Column(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;IdCondition&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;, type=&quot;&lt;/span&gt;integer&quot;, nullable=&lt;span class=&quot;code-keyword&quot;&gt;true&lt;/span&gt;)
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $idCondition;

    /**
     * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; integer $idHealthProvider
     *
     * @ORM\Column(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;IdHealthProvider&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;, type=&quot;&lt;/span&gt;integer&quot;, nullable=&lt;span class=&quot;code-keyword&quot;&gt;true&lt;/span&gt;)
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $idHealthProvider;

    /**
     * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; integer $idSpeciality
     *
     * @ORM\Column(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;IdSpeciality&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;, type=&quot;&lt;/span&gt;integer&quot;, nullable=&lt;span class=&quot;code-keyword&quot;&gt;true&lt;/span&gt;)
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $idSpeciality;

    /**
     * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; integer $idMedicineType
     *
     * @ORM\Column(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;IdMedicineType&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;, type=&quot;&lt;/span&gt;integer&quot;, nullable=&lt;span class=&quot;code-keyword&quot;&gt;true&lt;/span&gt;)
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $idMedicineType;

    /**
     * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; integer $idTreatment
     *
     * @ORM\Column(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;IdTreatment&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;, type=&quot;&lt;/span&gt;integer&quot;, nullable=&lt;span class=&quot;code-keyword&quot;&gt;true&lt;/span&gt;)
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $idTreatment;

    /**
     * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; string $title
     *
     * @ORM\Column(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;Title&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;, type=&quot;&lt;/span&gt;string&quot;, nullable=&lt;span class=&quot;code-keyword&quot;&gt;true&lt;/span&gt;)
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $title;

    /**
     * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; string $smallText
     *
     * @ORM\Column(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;SmallText&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;, type=&quot;&lt;/span&gt;string&quot;, nullable=&lt;span class=&quot;code-keyword&quot;&gt;true&lt;/span&gt;)
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $smallText;

    /**
     * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; string $longText
     *
     * @ORM\Column(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;LongText&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;, type=&quot;&lt;/span&gt;string&quot;, nullable=&lt;span class=&quot;code-keyword&quot;&gt;true&lt;/span&gt;)
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $longText;

    /**
     * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; datetimetz $publishDate
     *
     * @ORM\Column(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;PublishDate&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;, type=&quot;&lt;/span&gt;datetimetz&quot;, nullable=&lt;span class=&quot;code-keyword&quot;&gt;true&lt;/span&gt;)
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $publishDate;

    /**
     * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; tsvector $idxNews
     *
     * @ORM\Column(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;IdxNews&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;, type=&quot;&lt;/span&gt;tsvector&quot;, nullable=&lt;span class=&quot;code-keyword&quot;&gt;true&lt;/span&gt;)
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $idxNews;

    /**
     * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; &lt;span class=&quot;code-object&quot;&gt;boolean&lt;/span&gt; $highlight
     *
     * @ORM\Column(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;Highlight&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;, type=&quot;&lt;/span&gt;&lt;span class=&quot;code-object&quot;&gt;boolean&lt;/span&gt;&quot;, nullable=&lt;span class=&quot;code-keyword&quot;&gt;false&lt;/span&gt;)
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $highlight;

    /**
     * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; integer $order
     *
     * @ORM\Column(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;Order&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;, type=&quot;&lt;/span&gt;integer&quot;, nullable=&lt;span class=&quot;code-keyword&quot;&gt;false&lt;/span&gt;)
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $order;

    /**
     * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; &lt;span class=&quot;code-object&quot;&gt;boolean&lt;/span&gt; $deleted
     *
     * @ORM\Column(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;Deleted&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;, type=&quot;&lt;/span&gt;&lt;span class=&quot;code-object&quot;&gt;boolean&lt;/span&gt;&quot;, nullable=&lt;span class=&quot;code-keyword&quot;&gt;false&lt;/span&gt;)
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $deleted;

    /**
     * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; &lt;span class=&quot;code-object&quot;&gt;boolean&lt;/span&gt; $active
     *
     * @ORM\Column(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;Active&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;, type=&quot;&lt;/span&gt;&lt;span class=&quot;code-object&quot;&gt;boolean&lt;/span&gt;&quot;, nullable=&lt;span class=&quot;code-keyword&quot;&gt;false&lt;/span&gt;)
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $active;

    /**
     * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; &lt;span class=&quot;code-object&quot;&gt;boolean&lt;/span&gt; $updateToHighlighted
     *
     * @ORM\Column(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;UpdateToHighlighted&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;, type=&quot;&lt;/span&gt;&lt;span class=&quot;code-object&quot;&gt;boolean&lt;/span&gt;&quot;, nullable=&lt;span class=&quot;code-keyword&quot;&gt;true&lt;/span&gt;)
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $updateToHighlighted;

    /**
     * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; condition
     *
     * @ORM\ManyToOne(targetEntity=&lt;span class=&quot;code-quote&quot;&gt;&quot;Condition&quot;&lt;/span&gt;)
     * @ORM\JoinColumns({
     *   @ORM\JoinColumn(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;IdCondition&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;, referencedColumnName=&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;IdCondition&quot;&lt;/span&gt;&quot;&quot;)
     * })
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $condition;

    /**
     * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; healthProvider
     *
     * @ORM\ManyToOne(targetEntity=&lt;span class=&quot;code-quote&quot;&gt;&quot;HealthProvider&quot;&lt;/span&gt;)
     * @ORM\JoinColumns({
     *   @ORM\JoinColumn(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;IdHealthProvider&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;, referencedColumnName=&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;IdHealthProvider&quot;&lt;/span&gt;&quot;&quot;)
     * })
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $healthProvider;

    /**
     * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; language
     *
     * @ORM\ManyToOne(targetEntity=&lt;span class=&quot;code-quote&quot;&gt;&quot;Language&quot;&lt;/span&gt;)
     * @ORM\JoinColumns({
     *   @ORM\JoinColumn(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;IdLanguage&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;, referencedColumnName=&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;IdLanguage&quot;&lt;/span&gt;&quot;&quot;)
     * })
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $language;

    /**
     * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; medicineType
     *
     * @ORM\ManyToOne(targetEntity=&lt;span class=&quot;code-quote&quot;&gt;&quot;MedicineType&quot;&lt;/span&gt;)
     * @ORM\JoinColumns({
     *   @ORM\JoinColumn(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;IdMedicineType&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;, referencedColumnName=&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;IdMedicineType&quot;&lt;/span&gt;&quot;&quot;)
     * })
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $medicineType;

    /**
     * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; speciality
     *
     * @ORM\ManyToOne(targetEntity=&lt;span class=&quot;code-quote&quot;&gt;&quot;Speciality&quot;&lt;/span&gt;)
     * @ORM\JoinColumns({
     *   @ORM\JoinColumn(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;IdSpeciality&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;, referencedColumnName=&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;IdSpeciality&quot;&lt;/span&gt;&quot;&quot;)
     * })
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $speciality;

    /**
     * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; treatment
     *
     * @ORM\ManyToOne(targetEntity=&lt;span class=&quot;code-quote&quot;&gt;&quot;Treatment&quot;&lt;/span&gt;)
     * @ORM\JoinColumns({
     *   @ORM\JoinColumn(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;IdTreatment&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;, referencedColumnName=&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;IdTreatment&quot;&lt;/span&gt;&quot;&quot;)
     * })
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $treatment;

    /**
     * @&lt;span class=&quot;code-keyword&quot;&gt;var&lt;/span&gt; user
     *
     * @ORM\ManyToOne(targetEntity=&lt;span class=&quot;code-quote&quot;&gt;&quot;User&quot;&lt;/span&gt;)
     * @ORM\JoinColumns({
     *   @ORM\JoinColumn(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;&quot;IdUser&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;, referencedColumnName=&quot;&lt;/span&gt;&lt;span class=&quot;code-quote&quot;&gt;&quot;&quot;IdUser&quot;&lt;/span&gt;&quot;&quot;)
     * })
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $user;

    ....

}
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;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;&apos;SELECT n.smallText, n.publishDate &apos; .
&apos;FROM News n &apos; .
	&apos;INNER JOIN n.language la &apos; .
&apos;WHERE la.languageCode = :languageCode &apos; .
&apos;ORDER BY n.publishDate DESC&apos;
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Generated SQL:&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 &lt;span class=&quot;code-quote&quot;&gt;&quot;0_.&quot;&lt;/span&gt;SmallText&lt;span class=&quot;code-quote&quot;&gt;&quot; AS &quot;&lt;/span&gt;SmallText&lt;span class=&quot;code-quote&quot;&gt;&quot;0, &quot;&lt;/span&gt;0_.&lt;span class=&quot;code-quote&quot;&gt;&quot;PublishDate&quot;&lt;/span&gt; AS &lt;span class=&quot;code-quote&quot;&gt;&quot;PublishDate&quot;&lt;/span&gt;1 FROM &lt;span class=&quot;code-quote&quot;&gt;&quot;News&quot;&lt;/span&gt; &lt;span class=&quot;code-quote&quot;&gt;&quot;0_ INNER JOIN &quot;&lt;/span&gt;Language&lt;span class=&quot;code-quote&quot;&gt;&quot; &quot;&lt;/span&gt;1_ ON &lt;span class=&quot;code-quote&quot;&gt;&quot;0_.&quot;&lt;/span&gt;IdLanguage&lt;span class=&quot;code-quote&quot;&gt;&quot; = &quot;&lt;/span&gt;1_.&lt;span class=&quot;code-quote&quot;&gt;&quot;IdLanguage&quot;&lt;/span&gt; WHERE &lt;span class=&quot;code-quote&quot;&gt;&quot;1_.&quot;&lt;/span&gt;LanguageCode&lt;span class=&quot;code-quote&quot;&gt;&quot; = ? ORDER BY &quot;&lt;/span&gt;0_.&lt;span class=&quot;code-quote&quot;&gt;&quot;PublishDate&quot;&lt;/span&gt; DESC LIMIT 6
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Notice there are unmattched &quot; in the SQL.&lt;/p&gt;</description>
                <environment>PostgreSQL 9.x, Symfony 2</environment>
            <key id="13513">DDC-1695</key>
            <summary>SQLs for PostgreSQL case sensite tables/fields are wrongly generated</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="5" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/resolved.png">Resolved</status>
                    <resolution id="1">Fixed</resolution>
                    <security id="10000">All</security>
                        <assignee username="beberlei">Benjamin Eberlei</assignee>
                                <reporter username="ignaciolarranaga">Ignacio Larranaga</reporter>
                        <labels>
                    </labels>
                <created>Fri, 9 Mar 2012 03:08:19 +0000</created>
                <updated>Sun, 11 Mar 2012 22:34:37 +0000</updated>
                    <resolved>Sun, 11 Mar 2012 22:34:37 +0000</resolved>
                            <version>2.1.6</version>
                                <fixVersion>2.1.7</fixVersion>
                <fixVersion>2.2.2</fixVersion>
                                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                        <comments>
                    <comment id="17538" author="ignaciolarranaga" created="Fri, 9 Mar 2012 03:09:09 +0000"  >&lt;p&gt;If there is another approach to specify the table/column names are case sensitive in PGSQL please let me know.&lt;/p&gt;</comment>
                    <comment id="17539" author="ignaciolarranaga" created="Fri, 9 Mar 2012 03:50:20 +0000"  >&lt;p&gt;Just to comment. I also tried the normal quoting.&lt;/p&gt;

&lt;p&gt;Example: @ORM\Column(name=&quot;`IdNews`&quot;, type=&quot;integer&quot;, nullable=false)&lt;/p&gt;

&lt;p&gt;And does not work too because of the same reason.&lt;/p&gt;</comment>
                    <comment id="17540" author="ignaciolarranaga" created="Fri, 9 Mar 2012 05:40:25 +0000"  >&lt;p&gt;Hi, I generate this patch and seems to be working for me (at least what I&apos;m testing right now).&lt;/p&gt;

&lt;p&gt;I used &#180; to quote tables and single attributes (not relationships) and the SQLs are correctly generated.&lt;/p&gt;</comment>
                    <comment id="17542" author="ignaciolarranaga" created="Fri, 9 Mar 2012 15:00:06 +0000"  >&lt;p&gt;Adding a new patch for another files I need to change.&lt;/p&gt;</comment>
                    <comment id="17553" author="beberlei" created="Sun, 11 Mar 2012 22:09:22 +0000"  >&lt;p&gt;Formatted code&lt;/p&gt;</comment>
                    <comment id="17554" author="beberlei" created="Sun, 11 Mar 2012 22:34:37 +0000"  >&lt;p&gt;Fixed and merged into 2.1.x and 2.2 branches&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                    <attachment id="11169" name="doctrine-2.1.6.patch" size="4479" author="ignaciolarranaga" created="Fri, 9 Mar 2012 15:00:06 +0000" />
                    <attachment id="11168" name="SqlWalker.patch" size="2410" author="ignaciolarranaga" created="Fri, 9 Mar 2012 05:40:25 +0000" />
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DDC-1683] Doctrine\ORM\Query\Expr\Comparison Doesn&apos;t handle boolean values properly</title>
                <link>http://www.doctrine-project.org/jira/browse/DDC-1683</link>
                <project id="10032" key="DDC">Doctrine 2 - ORM</project>
                        <description>&lt;p&gt;Expected behaviour - Using boolean types in Query Builder&lt;/p&gt;

&lt;p&gt;The following works&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;$qb = $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;getDoctrine()-&amp;gt;getEntityManager()-&amp;gt;createQueryBuilder();

$qb
    -&amp;gt;select(&apos;entity&apos;)
    -&amp;gt;from(&apos;FooBundle:Entity&apos;, &apos;entity&apos;)
    -&amp;gt;where($qb-&amp;gt;expr()-&amp;gt;eq(&apos;entity.visible&apos;, &lt;span class=&quot;code-keyword&quot;&gt;true&lt;/span&gt;))
;

$query = $qb-&amp;gt;getQuery();

&lt;span class=&quot;code-keyword&quot;&gt;return&lt;/span&gt; $query-&amp;gt;getResult();
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;The following throws an &lt;tt&gt;Doctrine/ORM/Query/QueryException&lt;/tt&gt; error &lt;tt&gt;&lt;span class=&quot;error&quot;&gt;&amp;#91;Syntax Error&amp;#93;&lt;/span&gt; line 0, col -1: Error: Expected Literal, got end of string.&lt;/tt&gt;&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;$qb = $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;getDoctrine()-&amp;gt;getEntityManager()-&amp;gt;createQueryBuilder();

$qb
    -&amp;gt;select(&apos;entity&apos;)
    -&amp;gt;from(&apos;FooBundle:Entity&apos;, &apos;entity&apos;)
    -&amp;gt;where($qb-&amp;gt;expr()-&amp;gt;eq(&apos;entity.visible&apos;, &lt;span class=&quot;code-keyword&quot;&gt;false&lt;/span&gt;))
;

$query = $qb-&amp;gt;getQuery();

&lt;span class=&quot;code-keyword&quot;&gt;return&lt;/span&gt; $query-&amp;gt;getResult();
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;This is due to  &lt;tt&gt;Doctrine\ORM\Query\Expr\Comparison::_toString()&lt;/tt&gt;&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;public&lt;/span&gt; function __toString()
{
    &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;_leftExpr . &apos; &apos; . $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;_operator . &apos; &apos; . $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;_rightExpr;
}
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;When &lt;tt&gt;$this-&amp;gt;_rightExpr === true&lt;/tt&gt; type coercion results in 1, but for false it results in an empty string, thus &lt;br/&gt;
resulting in invalid SQL.&lt;/p&gt;

&lt;p&gt;The following in &lt;tt&gt;Doctrine\ORM\Query\Expr\Comparison::__construct()&lt;/tt&gt; resolves the problem (&lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/297&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/297&lt;/a&gt;)&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;public&lt;/span&gt; function __construct($leftExpr, $&lt;span class=&quot;code-keyword&quot;&gt;operator&lt;/span&gt;, $rightExpr)
{
    $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;_leftExpr  = $leftExpr;
    $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;_operator  = $&lt;span class=&quot;code-keyword&quot;&gt;operator&lt;/span&gt;;
    $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;_rightExpr = $rightExpr === &lt;span class=&quot;code-keyword&quot;&gt;false&lt;/span&gt; ? (&lt;span class=&quot;code-object&quot;&gt;int&lt;/span&gt;) $rightExpr : $rightExpr;
}
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;


&lt;p&gt;Could be related to &lt;a href=&quot;http://www.doctrine-project.org/jira/browse/DDC-1048&quot; class=&quot;external-link&quot;&gt;http://www.doctrine-project.org/jira/browse/DDC-1048&lt;/a&gt; and &lt;a href=&quot;http://www.doctrine-project.org/jira/browse/DDC-949&quot; class=&quot;external-link&quot;&gt;http://www.doctrine-project.org/jira/browse/DDC-949&lt;/a&gt;&lt;/p&gt;</description>
                <environment>Symfony 2.0.11, MySQL, PDO, PHP Version 5.3.5-1ubuntu7.7</environment>
            <key id="13498">DDC-1683</key>
            <summary>Doctrine\ORM\Query\Expr\Comparison Doesn&apos;t handle boolean values properly</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="5" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/resolved.png">Resolved</status>
                    <resolution id="1">Fixed</resolution>
                    <security id="10000">All</security>
                        <assignee username="beberlei">Benjamin Eberlei</assignee>
                                <reporter username="peterjmit">Peter Mitchell</reporter>
                        <labels>
                    </labels>
                <created>Tue, 6 Mar 2012 10:53:37 +0000</created>
                <updated>Wed, 14 Mar 2012 19:52:05 +0000</updated>
                    <resolved>Wed, 14 Mar 2012 19:52:05 +0000</resolved>
                            <version>2.1.6</version>
                <version>2.2</version>
                                <fixVersion>2.1.7</fixVersion>
                <fixVersion>2.2.2</fixVersion>
                                <component>DQL</component>
                <component>ORM</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                        <comments>
                    <comment id="17572" author="beberlei" created="Wed, 14 Mar 2012 19:52:05 +0000"  >&lt;p&gt;Fixed, but your code is wrong. It has to be&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;$qb-&amp;gt;expr()-&amp;gt;literal(&lt;span class=&quot;code-keyword&quot;&gt;true&lt;/span&gt;);
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;</comment>
                </comments>
                    <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DDC-1678] When many to many changes but no fields, listeners don&apos;t get notified about update.</title>
                <link>http://www.doctrine-project.org/jira/browse/DDC-1678</link>
                <project id="10032" key="DDC">Doctrine 2 - ORM</project>
                        <description>&lt;p&gt;See &lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/256&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/256&lt;/a&gt;&lt;/p&gt;</description>
                <environment></environment>
            <key id="13491">DDC-1678</key>
            <summary>When many to many changes but no fields, listeners don&apos;t get notified about update.</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="5" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/resolved.png">Resolved</status>
                    <resolution id="1">Fixed</resolution>
                    <security id="10000">All</security>
                        <assignee username="beberlei">Benjamin Eberlei</assignee>
                                <reporter username="beberlei">Benjamin Eberlei</reporter>
                        <labels>
                    </labels>
                <created>Sat, 3 Mar 2012 21:15:13 +0000</created>
                <updated>Sat, 3 Mar 2012 21:19:21 +0000</updated>
                    <resolved>Sat, 3 Mar 2012 21:19:21 +0000</resolved>
                            <version>2.2</version>
                                <fixVersion>2.1.7</fixVersion>
                <fixVersion>2.2.1</fixVersion>
                                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                        <comments>
                    <comment id="17508" author="beberlei" created="Sat, 3 Mar 2012 21:19:21 +0000"  >&lt;p&gt;Fixed&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DDC-1659] Clear read only entities</title>
                <link>http://www.doctrine-project.org/jira/browse/DDC-1659</link>
                <project id="10032" key="DDC">Doctrine 2 - ORM</project>
                        <description>&lt;p&gt;&lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/286&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/286&lt;/a&gt;&lt;/p&gt;</description>
                <environment></environment>
            <key id="13462">DDC-1659</key>
            <summary>Clear read only entities</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="5" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/resolved.png">Resolved</status>
                    <resolution id="1">Fixed</resolution>
                    <security id="10000">All</security>
                        <assignee username="beberlei">Benjamin Eberlei</assignee>
                                <reporter username="beberlei">Benjamin Eberlei</reporter>
                        <labels>
                    </labels>
                <created>Sun, 19 Feb 2012 23:34:27 +0000</created>
                <updated>Mon, 20 Feb 2012 08:43:20 +0000</updated>
                    <resolved>Mon, 20 Feb 2012 08:43:20 +0000</resolved>
                                            <fixVersion>2.1.7</fixVersion>
                <fixVersion>2.2.1</fixVersion>
                                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                        <comments>
                    <comment id="17447" author="beberlei" created="Mon, 20 Feb 2012 08:43:20 +0000"  >&lt;p&gt;Fixed&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DDC-1648] Primary Keys as Foreign Keys - still not working in  Reverse Engineering in 2.1.6</title>
                <link>http://www.doctrine-project.org/jira/browse/DDC-1648</link>
                <project id="10032" key="DDC">Doctrine 2 - ORM</project>
                        <description>&lt;p&gt;Please, read this old thread - looks like this problem still is not solved &lt;img class=&quot;emoticon&quot; src=&quot;http://www.doctrine-project.org/jira/images/icons/emoticons/sad.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;

&lt;p&gt;&lt;a href=&quot;http://comments.gmane.org/gmane.comp.php.symfony.symfony2/1398&quot; class=&quot;external-link&quot;&gt;http://comments.gmane.org/gmane.comp.php.symfony.symfony2/1398&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&amp;gt;&amp;gt;The primary key as foreign key limitation is from the 2.0 manual. You are using 2.1 with symfony, which supports this. Please use the correct manual.&lt;/p&gt;

&lt;p&gt;&amp;gt;&amp;gt; The only problem is that the reverse engineering does not support this. You have to reverse engineer yourself, or write a patch to have Doctrine support this. I would really appreciate it &lt;/p&gt;

&lt;p&gt;As I understand it is supported in the &quot;core&quot;, but some reverse engineer script is still not using that possibility.&lt;br/&gt;
Could you at least point where this can fixed?&lt;/p&gt;
</description>
                <environment></environment>
            <key id="13436">DDC-1648</key>
            <summary>Primary Keys as Foreign Keys - still not working in  Reverse Engineering in 2.1.6</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="5" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/resolved.png">Resolved</status>
                    <resolution id="1">Fixed</resolution>
                    <security id="10000">All</security>
                        <assignee username="beberlei">Benjamin Eberlei</assignee>
                                <reporter username="rivaros">ross neacoders</reporter>
                        <labels>
                    </labels>
                <created>Sun, 12 Feb 2012 06:36:14 +0000</created>
                <updated>Wed, 14 Mar 2012 20:40:35 +0000</updated>
                    <resolved>Wed, 14 Mar 2012 20:40:35 +0000</resolved>
                            <version>2.1.6</version>
                                <fixVersion>2.1.7</fixVersion>
                <fixVersion>2.2.2</fixVersion>
                                        <due></due>
                    <votes>0</votes>
                        <watches>0</watches>
                        <comments>
                    <comment id="17408" author="beberlei" created="Sun, 12 Feb 2012 09:39:18 +0000"  >&lt;p&gt;In lib/Doctrine/ORM/Mapping/DatabaseDriver.php&lt;/p&gt;</comment>
                    <comment id="17409" author="rivaros" created="Sun, 12 Feb 2012 14:43:51 +0000"  >&lt;p&gt;Thank you Benjamin,&lt;/p&gt;

&lt;p&gt;Actually started tracking this error from /lib/Doctrine/ORM/Mapping/ClasMetadataInfo.php and step-bystep it goes to&lt;br/&gt;
/lib/Doctrine/ORM/Mapping/Driver/DatabaseDriver.php&lt;/p&gt;

&lt;p&gt;Actually it calls ClasMetadataInfo::mapMayToOne instead of mapOneToOne in such situations. &lt;br/&gt;
Will investigate further. Pff... DatabaseDriver.php looks a hard class. &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>
                    <comment id="17410" author="rivaros" created="Sun, 12 Feb 2012 20:02:28 +0000"  >&lt;p&gt;I am almost done with it - need a little more help from you:&lt;/p&gt;

&lt;p&gt;So I fixed the DatabaseDriver so it correctly calls mapOneToOne&lt;br/&gt;
and passes association_mapping to it.&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;    /**
     * Adds a one-to-one mapping.
     *
     * @param array $mapping The mapping.
     */
    &lt;span class=&quot;code-keyword&quot;&gt;public&lt;/span&gt; function mapOneToOne(array $mapping)
    {
        $mapping[&apos;type&apos;] = self::ONE_TO_ONE;
        $mapping = $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;_validateAndCompleteOneToOneMapping($mapping);
        $&lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt;-&amp;gt;_storeAssociationMapping($mapping);
print_r($assocMapping); &amp;lt;--added &lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt; to see what structure we have on output
    }
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;this gives the following structure&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;Array
(
    [fieldName] =&amp;gt; someguid                      &amp;lt;--- my primary key field, which is also foreign key
    [targetEntity] =&amp;gt; Additionalinfo               &amp;lt;--- target table
    [id] =&amp;gt; 1                                                      &amp;lt;--- indicates that &lt;span class=&quot;code-keyword&quot;&gt;this&lt;/span&gt; mapping is also id (primary key)
    [joinColumns] =&amp;gt; Array
        (
            [0] =&amp;gt; Array
                (
                    [name] =&amp;gt; Someguid                                                     &amp;lt;--- join columns
                    [referencedColumnName] =&amp;gt; UniqueID                    
                )

        )

    [type] =&amp;gt; 1  &amp;lt;-- indicates ONE-TO-ONE assoc mapping
    [mappedBy] =&amp;gt; 
    [inversedBy] =&amp;gt; 
    [isOwningSide] =&amp;gt; 1
    [sourceEntity] =&amp;gt; Sampledata
    [fetch] =&amp;gt; 2
..... (i omit other data as not important)
)
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Now the problem: in my entity I got the following&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;var&lt;/span&gt; Additionalinfo
     *
     * @ORM\OneToOne(targetEntity=&lt;span class=&quot;code-quote&quot;&gt;&quot;Additionalinfo&quot;&lt;/span&gt;)
     * @ORM\JoinColumns({
     *   @ORM\JoinColumn(name=&lt;span class=&quot;code-quote&quot;&gt;&quot;Someguid&quot;&lt;/span&gt;, referencedColumnName=&lt;span class=&quot;code-quote&quot;&gt;&quot;UniqueID&quot;&lt;/span&gt;)
     * })
     */
    &lt;span class=&quot;code-keyword&quot;&gt;private&lt;/span&gt; $someguid;
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;So it correctly created a One-To-One mapping, but it did not preserve @Id attribute.&lt;/p&gt;

&lt;p&gt;I guess this is because field_associations and mapping_associations are processed in separate way,&lt;br/&gt;
and in mapping_association it ignores the $mapping&lt;span class=&quot;error&quot;&gt;&amp;#91;&amp;quot;id&amp;quot;&amp;#93;&lt;/span&gt; setting.&lt;/p&gt;

&lt;p&gt;Do you know what code is managing creating the &amp;lt;id ....&amp;gt; / @Id  staff - it is common for annotation/yaml/xml, e.x. when i generated xml for entity, it also does not contain &amp;lt;id &amp;gt; tag.&lt;/p&gt;

</comment>
                    <comment id="17411" author="rivaros" created="Sun, 12 Feb 2012 21:47:50 +0000"  >&lt;p&gt;Update: fixed the last problem in Doctrine/ORM/Tools/EntityGenerator.php&lt;/p&gt;

&lt;p&gt;Still has to be fixed in YAML/XML exporters - not very familiar with the syntax.&lt;/p&gt;</comment>
                    <comment id="17507" author="beberlei" created="Sat, 3 Mar 2012 21:00:50 +0000"  >&lt;p&gt;This PR fixes the problem &lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/280&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/280&lt;/a&gt;&lt;/p&gt;</comment>
                    <comment id="17579" author="beberlei" created="Wed, 14 Mar 2012 20:40:35 +0000"  >&lt;p&gt;Fixed&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DDC-1643] PersistentCollection should support clone</title>
                <link>http://www.doctrine-project.org/jira/browse/DDC-1643</link>
                <project id="10032" key="DDC">Doctrine 2 - ORM</project>
                        <description>&lt;p&gt;I&apos;m trying to clone a &lt;tt&gt;PersistentCollection&lt;/tt&gt; and expect to get a stable snapshot. But the class does not implement &lt;tt&gt;__clone&lt;/tt&gt;, thus both objects refer to the same internal &lt;tt&gt;ArrayCollection&lt;/tt&gt;.&lt;/p&gt;

&lt;p&gt;I can&apos;t use &lt;tt&gt;takeSnapshot&lt;/tt&gt; because I&apos;m writing generic code that should work with any implementation of &lt;tt&gt;Traversable&lt;/tt&gt;/&lt;tt&gt;ArrayAccess&lt;/tt&gt;.&lt;/p&gt;</description>
                <environment></environment>
            <key id="13429">DDC-1643</key>
            <summary>PersistentCollection should support clone</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="5" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/resolved.png">Resolved</status>
                    <resolution id="1">Fixed</resolution>
                    <security id="10000">All</security>
                        <assignee username="beberlei">Benjamin Eberlei</assignee>
                                <reporter username="bschussek">Bernhard Schussek</reporter>
                        <labels>
                    </labels>
                <created>Thu, 9 Feb 2012 12:56:43 +0000</created>
                <updated>Fri, 17 Feb 2012 23:49:12 +0000</updated>
                    <resolved>Fri, 17 Feb 2012 23:49:12 +0000</resolved>
                            <version>2.2</version>
                                <fixVersion>2.1.7</fixVersion>
                <fixVersion>2.2.1</fixVersion>
                                <component>ORM</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>1</watches>
                        <comments>
                    <comment id="17389" author="beberlei" created="Thu, 9 Feb 2012 18:38:28 +0000"  >&lt;p&gt;Moved to right project&lt;/p&gt;</comment>
                    <comment id="17391" author="bschussek" created="Fri, 10 Feb 2012 13:47:24 +0000"  >&lt;p&gt;Thank you for moving. Any comments on the feasibility of this issue?&lt;/p&gt;</comment>
                    <comment id="17392" author="beberlei" created="Fri, 10 Feb 2012 13:48:53 +0000"  >&lt;p&gt;I guess its feasible, i have to think about:&lt;/p&gt;

&lt;p&gt;1. how to fix the issue&lt;br/&gt;
2. what behavior to attach in general.&lt;/p&gt;</comment>
                    <comment id="17393" author="bschussek" created="Fri, 10 Feb 2012 13:50:42 +0000"  >&lt;p&gt;Ok. For the sake of completeness, this issue directly causes another in Symfony2 which was already partially fixed here: &lt;a href=&quot;https://github.com/symfony/symfony/pull/3315&quot; class=&quot;external-link&quot;&gt;https://github.com/symfony/symfony/pull/3315&lt;/a&gt;&lt;/p&gt;</comment>
                    <comment id="17422" author="auswebdev" created="Mon, 13 Feb 2012 21:13:32 +0000"  >&lt;p&gt;PR submitted for this issue: &lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/281&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/281&lt;/a&gt;&lt;/p&gt;</comment>
                    <comment id="17439" author="beberlei" created="Fri, 17 Feb 2012 22:41:22 +0000"  >&lt;p&gt;What are you doing after the PersistentCollection is cloned? &lt;/p&gt;

&lt;p&gt;The reason is, that if the code looks like this:&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;$col = clone $entity-&amp;gt;getCol();
$otherEntity-&amp;gt;setCol($col);
echo count($col);
$em-&amp;gt;flush();
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;It will do very weird stuff using the owner of the association $col which is $entity. It will also try to insert the $col for $entity not for $otherEntity. To prevent this we have to do some work,&lt;/p&gt;</comment>
                    <comment id="17440" author="beberlei" created="Fri, 17 Feb 2012 23:49:12 +0000"  >&lt;p&gt;Fixed in &lt;a href=&quot;https://github.com/doctrine/doctrine2/commit/93f79d0810a158138020b4cca3332f9f0b1a76af&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/commit/93f79d0810a158138020b4cca3332f9f0b1a76af&lt;/a&gt; and merged into 2.2 and 2.1.x&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>

<item>
            <title>[DDC-1638] Inexistant method newInstance in UnitOfWork</title>
                <link>http://www.doctrine-project.org/jira/browse/DDC-1638</link>
                <project id="10032" key="DDC">Doctrine 2 - ORM</project>
                        <description>&lt;p&gt;the UnitOfWork uses ``newInstance`` to get the managed copy but this method does not exist in 2.1.6, thus breaking the code: &lt;a href=&quot;https://github.com/doctrine/doctrine2/blob/e1647229cd2544bd77f10620e1b95a5781c4a733/lib/Doctrine/ORM/UnitOfWork.php#L1418&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/blob/e1647229cd2544bd77f10620e1b95a5781c4a733/lib/Doctrine/ORM/UnitOfWork.php#L1418&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;This is probably an error when backporting a patch as the method exists in master&lt;/p&gt;</description>
                <environment></environment>
            <key id="13423">DDC-1638</key>
            <summary>Inexistant method newInstance in UnitOfWork</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="5" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/resolved.png">Resolved</status>
                    <resolution id="1">Fixed</resolution>
                    <security id="10000">All</security>
                        <assignee username="beberlei">Benjamin Eberlei</assignee>
                                <reporter username="stof">Christophe Coevoet</reporter>
                        <labels>
                    </labels>
                <created>Tue, 7 Feb 2012 13:26:46 +0000</created>
                <updated>Fri, 10 Feb 2012 19:49:21 +0000</updated>
                    <resolved>Fri, 10 Feb 2012 19:49:21 +0000</resolved>
                            <version>2.1.6</version>
                                <fixVersion>2.1.7</fixVersion>
                                <component>ORM</component>
                        <due></due>
                    <votes>0</votes>
                        <watches>2</watches>
                        <comments>
                    <comment id="17376" author="ocramius" created="Tue, 7 Feb 2012 13:43:40 +0000"  >&lt;p&gt;Patch at &lt;a href=&quot;https://github.com/doctrine/doctrine2/pull/276&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/doctrine2/pull/276&lt;/a&gt;&lt;/p&gt;</comment>
                    <comment id="17398" author="beberlei" created="Fri, 10 Feb 2012 19:49:21 +0000"  >&lt;p&gt;Fixed&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                </attachments>
            <subtasks>
        </subtasks>
        </item>
</channel>
</rss>