<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	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/"
		>
<channel>
	<title>Comments on: Install DBD::Oracle on 64-bit Linux and Oracle 11g</title>
	<atom:link href="http://www.pythian.com/news/995/another-dbdoracle-intall-kludge-64-bit-linux-and-oracle-11/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.pythian.com/news/995/another-dbdoracle-intall-kludge-64-bit-linux-and-oracle-11/</link>
	<description>News and views from Pythian DBAs</description>
	<lastBuildDate>Sat, 20 Mar 2010 20:27:09 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: John Scoles</title>
		<link>http://www.pythian.com/news/995/another-dbdoracle-intall-kludge-64-bit-linux-and-oracle-11/#comment-402791</link>
		<dc:creator>John Scoles</dc:creator>
		<pubDate>Fri, 05 Feb 2010 13:33:47 +0000</pubDate>
		<guid isPermaLink="false">http://www.pythian.com/blogs/995/another-dbdoracle-intall-kludge-64-bit-linux-and-oracle-11#comment-402791</guid>
		<description>AIX is always a bugger with anything to do with Perl and C libs

See this Blog entry for a similar story

http://www.pythian.com/news/6087/dbdoracle-on-aix-5-1/

sounds the same as yours</description>
		<content:encoded><![CDATA[<p>AIX is always a bugger with anything to do with Perl and C libs</p>
<p>See this Blog entry for a similar story</p>
<p><a href="http://www.pythian.com/news/6087/dbdoracle-on-aix-5-1/" rel="nofollow">http://www.pythian.com/news/6087/dbdoracle-on-aix-5-1/</a></p>
<p>sounds the same as yours</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: perl daze</title>
		<link>http://www.pythian.com/news/995/another-dbdoracle-intall-kludge-64-bit-linux-and-oracle-11/#comment-402703</link>
		<dc:creator>perl daze</dc:creator>
		<pubDate>Fri, 05 Feb 2010 04:15:51 +0000</pubDate>
		<guid isPermaLink="false">http://www.pythian.com/blogs/995/another-dbdoracle-intall-kludge-64-bit-linux-and-oracle-11#comment-402703</guid>
		<description>By the way, here were the errors I was getting prior to specifying the demo_rdbms32.mk file.

xlc: 1501-228 (W) input file /lib32/crt0_64.o not found
make: 1254-004 The error code from the last command is 252.


Stop.</description>
		<content:encoded><![CDATA[<p>By the way, here were the errors I was getting prior to specifying the demo_rdbms32.mk file.</p>
<p>xlc: 1501-228 (W) input file /lib32/crt0_64.o not found<br />
make: 1254-004 The error code from the last command is 252.</p>
<p>Stop.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: perl daze</title>
		<link>http://www.pythian.com/news/995/another-dbdoracle-intall-kludge-64-bit-linux-and-oracle-11/#comment-402699</link>
		<dc:creator>perl daze</dc:creator>
		<pubDate>Fri, 05 Feb 2010 04:12:19 +0000</pubDate>
		<guid isPermaLink="false">http://www.pythian.com/blogs/995/another-dbdoracle-intall-kludge-64-bit-linux-and-oracle-11#comment-402699</guid>
		<description>After at least 20 hours of working on this (over two weeks), DBD Oracle installed now on AIX 5.3 + 11g Client + DBD::Oracle 1.19 + DBI 1.609.

The key problem was that 11g Client does not have the .mk files that the perl modules usually look for.  I’m also curious if perl or Oracle 11g Client is in 32-bit, and if that has any negative impact.

See below for more details.  Keep in mind, I&#039;m not a perl developer, I only try to install the modules for our app.  So, much of my explanation below is just from deduction. If someone has better input, please feel free to add.

- - - 

Key changes:
• DBD::Oracle 1.19
• Use 11g Client&#039;s .mk file demo_rdbms32.mk

What’s the story?

The DBD Modules have three key pieces
A)	List of Oracle .mk files to look for (defined in Makefile.PL &gt; mk_oci)
B)	New features
C)	Battery of tests

DBD::Oracle versions 1.19, 1.21, and 1.23 look for files a certain set of Oracle files (demo_xe.mk, oracle.mk, demo_rdbms.mk, ins_rdbms.mk,etc.).  However, Oracle 11g Client install apparently does not have these files.  The special Makefile.PL has some extra logic.  If perl is 64-bit, then look for those usual set of files; otherwise, look for a single file, demo_rdbms32.mk.  And the 11g Client has this file.  You can specify this file as an argument, and that solves the problem too. 

Why not 1.21?  The “make test” only passes 96% of the tests
Why not 1.23?  The “make test” only passes 6% of the tests

DBD 1.19 passes all the tests.


Steps

export ORACLE_HOME=
export ORACLE_SID=
export ORACLE_USERID=user/password@$ORACLE_SID
export PERLLIB=/usr/local/lib
export LIBPATH=$ORACLE_HOME/lib32
perl Makefile.PL -m $ORACLE_HOME/rdbms/demo/demo_rdbms32.mk
make
make test</description>
		<content:encoded><![CDATA[<p>After at least 20 hours of working on this (over two weeks), DBD Oracle installed now on AIX 5.3 + 11g Client + DBD::Oracle 1.19 + DBI 1.609.</p>
<p>The key problem was that 11g Client does not have the .mk files that the perl modules usually look for.  I’m also curious if perl or Oracle 11g Client is in 32-bit, and if that has any negative impact.</p>
<p>See below for more details.  Keep in mind, I&#8217;m not a perl developer, I only try to install the modules for our app.  So, much of my explanation below is just from deduction. If someone has better input, please feel free to add.</p>
<p>- &#8211; - </p>
<p>Key changes:<br />
• DBD::Oracle 1.19<br />
• Use 11g Client&#8217;s .mk file demo_rdbms32.mk</p>
<p>What’s the story?</p>
<p>The DBD Modules have three key pieces<br />
A)	List of Oracle .mk files to look for (defined in Makefile.PL &gt; mk_oci)<br />
B)	New features<br />
C)	Battery of tests</p>
<p>DBD::Oracle versions 1.19, 1.21, and 1.23 look for files a certain set of Oracle files (demo_xe.mk, oracle.mk, demo_rdbms.mk, ins_rdbms.mk,etc.).  However, Oracle 11g Client install apparently does not have these files.  The special Makefile.PL has some extra logic.  If perl is 64-bit, then look for those usual set of files; otherwise, look for a single file, demo_rdbms32.mk.  And the 11g Client has this file.  You can specify this file as an argument, and that solves the problem too. </p>
<p>Why not 1.21?  The “make test” only passes 96% of the tests<br />
Why not 1.23?  The “make test” only passes 6% of the tests</p>
<p>DBD 1.19 passes all the tests.</p>
<p>Steps</p>
<p>export ORACLE_HOME=<br />
export ORACLE_SID=<br />
export ORACLE_USERID=user/password@$ORACLE_SID<br />
export PERLLIB=/usr/local/lib<br />
export LIBPATH=$ORACLE_HOME/lib32<br />
perl Makefile.PL -m $ORACLE_HOME/rdbms/demo/demo_rdbms32.mk<br />
make<br />
make test</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: John Danilson</title>
		<link>http://www.pythian.com/news/995/another-dbdoracle-intall-kludge-64-bit-linux-and-oracle-11/#comment-376808</link>
		<dc:creator>John Danilson</dc:creator>
		<pubDate>Fri, 25 Sep 2009 15:09:46 +0000</pubDate>
		<guid isPermaLink="false">http://www.pythian.com/blogs/995/another-dbdoracle-intall-kludge-64-bit-linux-and-oracle-11#comment-376808</guid>
		<description>alex, the link to the revised Makefile.PL appears not to work.  Is there an updated link available or can you upload the Makefile.PL somewhere here.

Thanks</description>
		<content:encoded><![CDATA[<p>alex, the link to the revised Makefile.PL appears not to work.  Is there an updated link available or can you upload the Makefile.PL somewhere here.</p>
<p>Thanks</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Paul Vallee</title>
		<link>http://www.pythian.com/news/995/another-dbdoracle-intall-kludge-64-bit-linux-and-oracle-11/#comment-238311</link>
		<dc:creator>Paul Vallee</dc:creator>
		<pubDate>Thu, 17 Jul 2008 18:57:09 +0000</pubDate>
		<guid isPermaLink="false">http://www.pythian.com/blogs/995/another-dbdoracle-intall-kludge-64-bit-linux-and-oracle-11#comment-238311</guid>
		<description>Excellent info, John, thanks.
Paul</description>
		<content:encoded><![CDATA[<p>Excellent info, John, thanks.<br />
Paul</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: John Scoles</title>
		<link>http://www.pythian.com/news/995/another-dbdoracle-intall-kludge-64-bit-linux-and-oracle-11/#comment-238309</link>
		<dc:creator>John Scoles</dc:creator>
		<pubDate>Thu, 17 Jul 2008 18:45:49 +0000</pubDate>
		<guid isPermaLink="false">http://www.pythian.com/blogs/995/another-dbdoracle-intall-kludge-64-bit-linux-and-oracle-11#comment-238309</guid>
		<description>Actully &#039;No&#039; is correct. 

The JDBC interface does let you &#039;batch&#039; multiple statments with one execute but this is just hiding the fact that one execute is fired for ecach of them. 

From the JDBC docs

&quot;The batch update facility is used with a PreparedStatement to associate multiple sets of input parameter values with a single PreparedStatement object.&quot;

so this

PreparedStatement stmt = con.prepareStatement(
	&quot;INSERT INTO employees VALUES (?, ?)&quot;);

stmt.setInt(1, 2000);
stmt.setString(2, &quot;Kelly Kaufmann&quot;);
stmt.addBatch();

stmt.setInt(1, 3000);
stmt.setString(2, &quot;Bill Barnes&quot;);
stmt.addBatch();
 
// submit the batch for execution
int[] updateCounts = stmt.executeBatch();

will do 1 OCIExecute .  

but this

Statement stmt = con.createStatement();
stmt.addBatch(&quot;INSERT INTO employees VALUES (1000, ?,?)&quot;);
stmt.setInt(1, 2000);
stmt.setString(2, &quot;Kelly Kaufmann&quot;);
stmt.addBatch(&quot;INSERT INTO departments VALUES (?, ?&#039;)&quot;);
stmt.setInt(1, 260);
stmt.setString(2, &quot;Shoe&quot;);
stmt.addBatch(&quot;INSERT INTO emp_dept VALUES (?, ?)&quot;);
stmt.setInt(1, 1000);
stmt.setInt(2, 260);

int[] updateCounts = stmt.executeBatch();

will do 3 OCIExecute command one for each SQL.  So in this case there are 3 round trips to the server rather than just one for the last example.</description>
		<content:encoded><![CDATA[<p>Actully &#8216;No&#8217; is correct. </p>
<p>The JDBC interface does let you &#8216;batch&#8217; multiple statments with one execute but this is just hiding the fact that one execute is fired for ecach of them. </p>
<p>From the JDBC docs</p>
<p>&#8220;The batch update facility is used with a PreparedStatement to associate multiple sets of input parameter values with a single PreparedStatement object.&#8221;</p>
<p>so this</p>
<p>PreparedStatement stmt = con.prepareStatement(<br />
	&#8220;INSERT INTO employees VALUES (?, ?)&#8221;);</p>
<p>stmt.setInt(1, 2000);<br />
stmt.setString(2, &#8220;Kelly Kaufmann&#8221;);<br />
stmt.addBatch();</p>
<p>stmt.setInt(1, 3000);<br />
stmt.setString(2, &#8220;Bill Barnes&#8221;);<br />
stmt.addBatch();</p>
<p>// submit the batch for execution<br />
int[] updateCounts = stmt.executeBatch();</p>
<p>will do 1 OCIExecute .  </p>
<p>but this</p>
<p>Statement stmt = con.createStatement();<br />
stmt.addBatch(&#8221;INSERT INTO employees VALUES (1000, ?,?)&#8221;);<br />
stmt.setInt(1, 2000);<br />
stmt.setString(2, &#8220;Kelly Kaufmann&#8221;);<br />
stmt.addBatch(&#8221;INSERT INTO departments VALUES (?, ?&#8217;)&#8221;);<br />
stmt.setInt(1, 260);<br />
stmt.setString(2, &#8220;Shoe&#8221;);<br />
stmt.addBatch(&#8221;INSERT INTO emp_dept VALUES (?, ?)&#8221;);<br />
stmt.setInt(1, 1000);<br />
stmt.setInt(2, 260);</p>
<p>int[] updateCounts = stmt.executeBatch();</p>
<p>will do 3 OCIExecute command one for each SQL.  So in this case there are 3 round trips to the server rather than just one for the last example.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Paul Vallee</title>
		<link>http://www.pythian.com/news/995/another-dbdoracle-intall-kludge-64-bit-linux-and-oracle-11/#comment-238262</link>
		<dc:creator>Paul Vallee</dc:creator>
		<pubDate>Thu, 17 Jul 2008 17:00:40 +0000</pubDate>
		<guid isPermaLink="false">http://www.pythian.com/blogs/995/another-dbdoracle-intall-kludge-64-bit-linux-and-oracle-11#comment-238262</guid>
		<description>John,
I think Laks is saying &#039;potato&#039; and you&#039;re saying &quot;pineapple&quot;.
The array interface is only for batching re-use of one handle for multiple uses, saving round trips. The batch interface lets you batch multiple statements, including different ones, into one database call. 
No?
Paul</description>
		<content:encoded><![CDATA[<p>John,<br />
I think Laks is saying &#8216;potato&#8217; and you&#8217;re saying &#8220;pineapple&#8221;.<br />
The array interface is only for batching re-use of one handle for multiple uses, saving round trips. The batch interface lets you batch multiple statements, including different ones, into one database call.<br />
No?<br />
Paul</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: John Scoles</title>
		<link>http://www.pythian.com/news/995/another-dbdoracle-intall-kludge-64-bit-linux-and-oracle-11/#comment-238141</link>
		<dc:creator>John Scoles</dc:creator>
		<pubDate>Thu, 17 Jul 2008 13:08:19 +0000</pubDate>
		<guid isPermaLink="false">http://www.pythian.com/blogs/995/another-dbdoracle-intall-kludge-64-bit-linux-and-oracle-11#comment-238141</guid>
		<description>Laks Said 

&#039;Though it helps in array binding and helps it is not equivalent to the batching facility in java driver.&#039;

Hi Laks I was curious about this so I had a look under the hood of the JDBC interface and which calls it was using in OCI to accomplish the task.  

Well to my surprise both JDBC and DBD::Oracle use almost the exactly the same code under the hood so I think it is a case of &#039;We do it this way any you do it the wrong way&#039;:);).

In JDBC you 
1) prepare a statement (con.prepareStatement)
2) bind values to the statement  (stmt.setString(2, &quot;bla&quot;))
3) add the statement to a batch (stmt.addBatch())
4) repeat 2-3 above and then 
5) execute your batch. (stmt.executeBatch())


in DBD:Oracle
1) prepare the statement ($dbh-&gt;prepare)
2) bind all the values to the statement ($sth-&gt;bind_param_array)
3) execute the statement. ($sth-&gt;execute_array)

In both JDBC and DBD::Oracle only 1 round trip call to the execute is made in OCI.

So me thinks it is a case here of &#039;You say &#039;potato&#039; and I say &#039;potato&#039;.

cheers</description>
		<content:encoded><![CDATA[<p>Laks Said </p>
<p>&#8216;Though it helps in array binding and helps it is not equivalent to the batching facility in java driver.&#8217;</p>
<p>Hi Laks I was curious about this so I had a look under the hood of the JDBC interface and which calls it was using in OCI to accomplish the task.  </p>
<p>Well to my surprise both JDBC and DBD::Oracle use almost the exactly the same code under the hood so I think it is a case of &#8216;We do it this way any you do it the wrong way&#8217;:);).</p>
<p>In JDBC you<br />
1) prepare a statement (con.prepareStatement)<br />
2) bind values to the statement  (stmt.setString(2, &#8220;bla&#8221;))<br />
3) add the statement to a batch (stmt.addBatch())<br />
4) repeat 2-3 above and then<br />
5) execute your batch. (stmt.executeBatch())</p>
<p>in DBD:Oracle<br />
1) prepare the statement ($dbh-&gt;prepare)<br />
2) bind all the values to the statement ($sth-&gt;bind_param_array)<br />
3) execute the statement. ($sth-&gt;execute_array)</p>
<p>In both JDBC and DBD::Oracle only 1 round trip call to the execute is made in OCI.</p>
<p>So me thinks it is a case here of &#8216;You say &#8216;potato&#8217; and I say &#8216;potato&#8217;.</p>
<p>cheers</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sergey</title>
		<link>http://www.pythian.com/news/995/another-dbdoracle-intall-kludge-64-bit-linux-and-oracle-11/#comment-209267</link>
		<dc:creator>Sergey</dc:creator>
		<pubDate>Sat, 31 May 2008 10:14:07 +0000</pubDate>
		<guid isPermaLink="false">http://www.pythian.com/blogs/995/another-dbdoracle-intall-kludge-64-bit-linux-and-oracle-11#comment-209267</guid>
		<description>Thank you very much for patching Makefile.PL!
It&#039;s very easy now to install DBD::Oracle with 11g.</description>
		<content:encoded><![CDATA[<p>Thank you very much for patching Makefile.PL!<br />
It&#8217;s very easy now to install DBD::Oracle with 11g.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Laks</title>
		<link>http://www.pythian.com/news/995/another-dbdoracle-intall-kludge-64-bit-linux-and-oracle-11/#comment-206834</link>
		<dc:creator>Laks</dc:creator>
		<pubDate>Tue, 27 May 2008 14:28:39 +0000</pubDate>
		<guid isPermaLink="false">http://www.pythian.com/blogs/995/another-dbdoracle-intall-kludge-64-bit-linux-and-oracle-11#comment-206834</guid>
		<description>Thanks John for your responses.
1) I had a look at the bind_param_array and execute_array interfaces added from 1.18 of DBD::Oracle.
Though it helps in array binding and helps it is not equivalent to the batching facility in java driver.With jdbc one can transparently batch inserts and updates to be sent to rdbms server in one shot. inserts and updates are done normally but driver internally batches them together like one unit of work.
Anyway i am happy that the array interface helps in binding array of values for inserts from 1.18.</description>
		<content:encoded><![CDATA[<p>Thanks John for your responses.<br />
1) I had a look at the bind_param_array and execute_array interfaces added from 1.18 of DBD::Oracle.<br />
Though it helps in array binding and helps it is not equivalent to the batching facility in java driver.With jdbc one can transparently batch inserts and updates to be sent to rdbms server in one shot. inserts and updates are done normally but driver internally batches them together like one unit of work.<br />
Anyway i am happy that the array interface helps in binding array of values for inserts from 1.18.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
