$csr = ora_open($dbh, "select foo from bar where x=:1 and y=:2");
$csr->bind_param(1, $value_x, $char_attrib);
$csr->bind_param(2, $value_y, $char_attrib);
ora_bind($csr); # bind with no parameters since we've done bind_param()'s</PRE>
<P>
<HR>
<H1><A NAME="debugging">DEBUGGING</A></H1>
<P><STRONG>DBD:</STRONG> The Oraperl $ora_debug variable is not supported. However
detailed debugging can be enabled at any time by executing</P>
<PRE>
$h->debug(2);</PRE>
<P>where $h is either a $lda or a $csr. If debugging is enabled on an
$lda then it is automatically passed on to any cursors returned by
&ora_open().</P>
<P>
<HR>
<H1><A NAME="example">EXAMPLE</A></H1>
<PRE>
format STDOUT_TOP =
Name Phone
==== =====
.</PRE>
<PRE>
format STDOUT =
@<<<<<<<<<< @>>>>>>>>>>
$name, $phone
.</PRE>
<PRE>
die "You should use oraperl, not perl\n" unless defined &ora_login;
$ora_debug = shift if $ARGV[0] =~ /^\-#/;</PRE>
<PRE>
$lda = &ora_login('t', 'kstock', 'kstock')
|| die $ora_errstr;
$csr = &ora_open($lda, 'select * from telno order by name')
|| die $ora_errstr;</PRE>
<PRE>
$nfields = &ora_fetch($csr);
print "Query will return $nfields fields\n\n";</PRE>
<PRE>
while (($name, $phone) = &ora_fetch($csr)) { write; }
warn $ora_errstr if $ora_errno;</PRE>
<PRE>
die "fetch error: $ora_errstr" if $ora_errno;</PRE>
<PRE>
do ora_close($csr) || die "can't close cursor";
do ora_logoff($lda) || die "can't log off Oracle";</PRE>
<P>
<HR>
<H1><A NAME="notes">NOTES</A></H1>
<P>In keeping with the philosophy of Perl, there is no pre-defined limit
to the number of simultaneous logins or SQL statements which may be
active, nor to the number of data fields which may be returned by a
query. The only limits are those imposed by the amount of memory
available, or by Oracle.</P>
<P>
<HR>
<H1><A NAME="warnings">WARNINGS</A></H1>
<P>The Oraperl emulation software shares no code with the original
oraperl. It is built on top of the new Perl5 DBI and DBD::Oracle
modules. These modules are still evolving. (One of the goals of
the Oraperl emulation software is to allow useful work to be done
with the DBI and DBD::Oracle modules whilst insulating users from
the ongoing changes in their interfaces.)</P>
<P>It is quite possible, indeed probable, that some differences in
behaviour will exist. These are probably confined to error handling.</P>
<P><STRONG>All</STRONG> differences in behaviour which are not documented here should be
reported to <A HREF="mailto:Tim.Bunce@ig.co.uk">Tim.Bunce@ig.co.uk</A> <STRONG>and</STRONG> CC'd to <A HREF="mailto:dbi-users@fugue.com.">dbi-users@fugue.com.</A></P>