<!-- 
RSS generated by JIRA (5.2.7#850-sha1:b2af0c8dc8537b36121c6a579fabbdf79fc919e5) at Wed Jun 19 03:12:29 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/si/jira.issueviews:issue-xml/DBAL-320/DBAL-320.xml?field=key&field=summary
-->
<rss version="0.92" >
<channel>
    <title>Doctrine Project</title>
    <link>http://www.doctrine-project.org/jira</link>
    <description>This file is an XML representation of an issue</description>
    <language>en-us</language>    <build-info>
        <version>5.2.7</version>
        <build-number>850</build-number>
        <build-date>21-02-2013</build-date>
    </build-info>

<item>
            <title>[DBAL-320] allow SQL QueryBuilder to do INSERTS</title>
                <link>http://www.doctrine-project.org/jira/browse/DBAL-320</link>
                <project id="10040" key="DBAL">Doctrine DBAL</project>
                        <description>&lt;p&gt;With&lt;/p&gt;

&lt;p&gt;$db = \Doctrine\DBAL\DriverManager::getConnection($connectionParams, $config);&lt;br/&gt;
$qb = $db-&amp;gt;createQueryBuilder();&lt;/p&gt;

&lt;p&gt;this QueryBuilder I&apos;m able to do SELECT, UPDATE and DELETE. However, INSERT is not possible. Are there any good reasons for this?&lt;/p&gt;

&lt;p&gt;Attached you find a patch that until now works fine for me. I don&apos;t know, however, if there are any side effects.&lt;/p&gt;</description>
                <environment></environment>
            <key id="13961">DBAL-320</key>
            <summary>allow SQL QueryBuilder to do INSERTS</summary>
                <type id="2" iconUrl="http://www.doctrine-project.org/jira/images/icons/issuetypes/newfeature.png">New Feature</type>
                                <priority id="3" iconUrl="http://www.doctrine-project.org/jira/images/icons/priorities/major.png">Major</priority>
                    <status id="4" iconUrl="http://www.doctrine-project.org/jira/images/icons/statuses/reopened.png">Reopened</status>
                    <resolution id="-1">Unresolved</resolution>
                    <security id="10000">All</security>
                        <assignee username="beberlei">Benjamin Eberlei</assignee>
                                <reporter username="tcm">Tim Mundt</reporter>
                        <labels>
                    </labels>
                <created>Mon, 13 Aug 2012 10:45:41 +0000</created>
                <updated>Mon, 13 Aug 2012 13:12:47 +0000</updated>
                                    <version>2.3</version>
                                                        <due></due>
                    <votes>0</votes>
                        <watches>2</watches>
                        <comments>
                    <comment id="18489" author="ocramius" created="Mon, 13 Aug 2012 10:46:59 +0000"  >&lt;p&gt;Insert is not supported by DQL&lt;/p&gt;</comment>
                    <comment id="18490" author="tcm" created="Mon, 13 Aug 2012 11:15:52 +0000"  >&lt;p&gt;Well, that was quick and not helpful. I have read about the QueryBuilder in the ORM package. For some reason with persistence (that other libraries don&apos;t have), insert cannot be supported. However, I&apos;m talking about DBAL here. What good reason is there not to support INSERT??&lt;/p&gt;</comment>
                    <comment id="18491" author="tcm" created="Mon, 13 Aug 2012 11:16:30 +0000"  >&lt;p&gt;see previous comment, I&apos;d appreciate some clarification&lt;/p&gt;</comment>
                    <comment id="18492" author="ocramius" created="Mon, 13 Aug 2012 11:30:30 +0000"  >&lt;p&gt;&lt;a href=&quot;http://www.doctrine-project.org/jira/secure/ViewProfile.jspa?name=tcm&quot; class=&quot;user-hover&quot; rel=&quot;tcm&quot;&gt;Tim Mundt&lt;/a&gt; Ouch, no, it was my fault, sorry. &lt;br/&gt;
I confused the project related to the issue.&lt;/p&gt;</comment>
                    <comment id="18493" author="ocramius" created="Mon, 13 Aug 2012 11:34:13 +0000"  >&lt;p&gt;This is actually valid (even the patch, though it needs to adds tests)&lt;/p&gt;</comment>
                    <comment id="18494" author="tcm" created="Mon, 13 Aug 2012 11:56:16 +0000"  >&lt;p&gt;Glad to hear there seems to be no fundamental problem with this. Can I somehow help this patch go into the code? I&apos;m not familiar with the tests here. If you give me some pointer, maybe I can come up with something useful. On the other hand, it could be a good idea for some more involved people to have a look at this before.&lt;/p&gt;</comment>
                    <comment id="18496" author="ocramius" created="Mon, 13 Aug 2012 12:13:24 +0000"  >&lt;p&gt;You&apos;d need to add tests in &lt;a href=&quot;https://github.com/doctrine/dbal/blob/master/tests/Doctrine/Tests/DBAL/Query/QueryBuilderTest.php&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/dbal/blob/master/tests/Doctrine/Tests/DBAL/Query/QueryBuilderTest.php&lt;/a&gt; (to be included in your patch or in a github pull request)&lt;br/&gt;
A Github PR is also the fastest way to get your code reviewed since not everyone visits the issue tracker.&lt;/p&gt;</comment>
                    <comment id="18497" author="tcm" created="Mon, 13 Aug 2012 13:12:47 +0000"  >&lt;p&gt;Here&apos;s the PR: &lt;a href=&quot;https://github.com/doctrine/dbal/pull/184&quot; class=&quot;external-link&quot;&gt;https://github.com/doctrine/dbal/pull/184&lt;/a&gt;&lt;/p&gt;</comment>
                </comments>
                    <attachments>
                    <attachment id="11310" name="INSERT-for-doctrine-SQL-QueryBuilder.patch" size="2479" author="tcm" created="Mon, 13 Aug 2012 10:45:41 +0000" />
                </attachments>
            <subtasks>
        </subtasks>
        </item>
</channel>
</rss>