<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Joseph Scott &#187; pdo</title>
	<atom:link href="http://josephscott.org/archives/tag/pdo/feed/" rel="self" type="application/rss+xml" />
	<link>http://josephscott.org</link>
	<description></description>
	<lastBuildDate>Mon, 06 Sep 2010 17:44:45 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
	<atom:link rel='hub' href='http://josephscott.org/?pushpress=hub'/>
		<item>
		<title>PDO Oddness</title>
		<link>http://josephscott.org/archives/2010/01/pdo-oddness/</link>
		<comments>http://josephscott.org/archives/2010/01/pdo-oddness/#comments</comments>
		<pubDate>Mon, 11 Jan 2010 16:13:09 +0000</pubDate>
		<dc:creator>Joseph Scott</dc:creator>
				<category><![CDATA[Posts]]></category>
		<category><![CDATA[pdo]]></category>
		<category><![CDATA[php]]></category>

		<guid isPermaLink="false">http://josephscott.org/?p=1704</guid>
		<description><![CDATA[There are some parts of PDO that I find strange. First up, why is the default fetch mode for the fetch function PDO::FETCH_BOTH? Returning twice as much data seems like a waste. Second, but related to the first, why can&#8217;t &#8230; <a href="http://josephscott.org/archives/2010/01/pdo-oddness/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>There are some parts of <a href="http://us.php.net/pdo">PDO</a> that I find strange.</p>
<p>First up, why is the default fetch mode for the <a href="http://www.php.net/manual/en/pdostatement.fetch.php">fetch</a> function PDO::FETCH_BOTH?  Returning twice as much data seems like a waste.</p>
<p>Second, but related to the first, why can&#8217;t you change the default fetch mode using <a href="http://www.php.net/manual/en/pdo.setattribute.php">PDO::setAttribute</a>?  It&#8217;s fine to be able to override the default when calling fetch, but being able to set a more reasonable default seems like an obvious feature.</p>
<p>And finally, why doesn&#8217;t the <a href="http://us.php.net/manual/en/pdo.connections.php">PDO DSN</a> include the username and password?  The format for the DSN is a bit different too.  Instead of using the URL style, used by many others like the <a href="http://pear.php.net/manual/en/package.database.db.intro-dsn.php">PEAR::DB DSN</a>, they came up with something else entirely.</p>
]]></content:encoded>
			<wfw:commentRss>http://josephscott.org/archives/2010/01/pdo-oddness/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
