Home > Archive > Oracle PERL DBD > December 2005 > [svn:dbd-oracle] r2321 - dbd-oracle/branches/pythian









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author [svn:dbd-oracle] r2321 - dbd-oracle/branches/pythian
timbo@cvs.perl.org

2005-12-21, 1:24 pm

Author: timbo
Date: Wed Dec 21 09:51:08 2005
New Revision: 2321

Modified:
dbd-oracle/branches/pythian/Changes
dbd-oracle/branches/pythian/Makefile.PL
dbd-oracle/branches/pythian/dbdimp.c
dbd-oracle/branches/pythian/oci8.c
Log:
Added support for binary floats/doubles thanks to Dennis Box.


Modified: dbd-oracle/branches/pythian/Changes
====================
====================
====================
==================
--- dbd-oracle/branches/pythian/Changes (original)
+++ dbd-oracle/branches/pythian/Changes Wed Dec 21 09:51:08 2005
@@ -6,8 +6,9 @@

Added support for nested cursors in select lists thanks to Charles Jardine.
Added "Trailing Spaces" section to docs thanks to Michael A Chase.
- Changed "Binding Cursors" docs, clarifying examples thanks to Charles Jardine.
+ Added support for binary floats/doubles thanks to Dennis Box.

+ Changed "Binding Cursors" docs, clarifying examples thanks to Charles Jardine.
Changed Makefile.PL to avoid risk of sqlplus hanging thanks to Mark Dedlow.
Changed Makefile.PL to prefer ~/rdbms/public over other ~/rdbms/* for .h files.
Changed Makefile.PL to improve build rule detection.
@@ -16,6 +17,7 @@
Updated README.vms re logical name tables thanks to Jakob Snoer.
Updated README.aix thanks to Stephen de Vries.
Updated README.macosx thanks to Stephen de Vries.
+ Renamed README.*'s to add .txt suffix to make life easier for some.

The Copyright terms for DBD::Oracle have been simplified and now read:
The DBD::Oracle module is free software; you can redistribute it

Modified: dbd-oracle/branches/pythian/Makefile.PL
====================
====================
====================
==================
--- dbd-oracle/branches/pythian/Makefile.PL (original)
+++ dbd-oracle/branches/pythian/Makefile.PL Wed Dec 21 09:51:08 2005
@@ -1448,8 +1448,8 @@ sub get_client_version {
close FH;
my $sqlplus_release = `$sqlplus_exe -S /nolog \@define.sql 2>&1`;
unlink "define.sql";
- print $sqlplus_release;
- if ($sqlplus_release =~ /^DEFINE _SQLPLUS_RELEASE = "(\d? \d)(\d\d)(\d\d)(\d\d
)(\d\d)"/) {
+ print $sqlplus_release; # the _SQLPLUS_RELEASE may not be on first line:
+ if ($sqlplus_release =~ /DEFINE _SQLPLUS_RELEASE = "(\d? \d)(\d\d)(\d\d)(\d\d
)(\d\d)"/) {
$client_version_full
= sprintf("%d.%d.%d.%d", $1, $2, $3, $4);
}
}

Modified: dbd-oracle/branches/pythian/dbdimp.c
====================
====================
====================
==================
--- dbd-oracle/branches/pythian/dbdimp.c (original)
+++ dbd-oracle/branches/pythian/dbdimp.c Wed Dec 21 09:51:08 2005
@@ -164,10 +164,14 @@ oratype_bind_ok(int dbtype) /* It's a ty
case 2: /* NVARCHAR2 */
case 5: /* STRING */
case 8: /* LONG */
+ case 21: /* BINARY FLOAT os-endian */
+ case 22: /* BINARY DOUBLE os-endian */
case 23: /* RAW */
case 24: /* LONG RAW */
case 96: /* CHAR */
case 97: /* CHARZ */
+ case 100: /* BINARY FLOAT oracle-endian */
+ case 101: /* BINARY DOUBLE oracle-endian */
case 106: /* MLSLABEL */
case 102: /* SQLT_CUR OCI 7 cursor variable */
case 112: /* SQLT_CLOB / long */
@@ -2120,6 +2124,15 @@ ora2sql_type(imp_fbh
_t* fbh) {
sql_fbh.dbtype = SQL_DECIMAL; /* better: SQL_NUMERIC */
}
break;
+#ifdef SQLT_IBDOUBLE
+ case SQLT_BDOUBLE:
+ case SQLT_BFLOAT:
+ case SQLT_IBDOUBLE:
+ case SQLT_IBFLOAT:
+ sql_fbh.dbtype = SQL_DOUBLE;
+ sql_fbh.prec = 126;
+ break;
+#endif
case SQLT_CHR: sql_fbh.dbtype = SQL_VARCHAR; break;
case SQLT_LNG: sql_fbh.dbtype = SQL_LONGVARCHAR; break; /* long */
case SQLT_DAT: sql_fbh.dbtype = SQL_TYPE_TIMESTAMP;b
reak;

Modified: dbd-oracle/branches/pythian/oci8.c
====================
====================
====================
==================
--- dbd-oracle/branches/pythian/oci8.c (original)
+++ dbd-oracle/branches/pythian/oci8.c Wed Dec 21 09:51:08 2005
@@ -1233,8 +1233,12 @@ dbd_describe(SV *h, imp_sth_t *imp_sth)
break;

case 2: /* NUMBER */
+ case 21: /* BINARY FLOAT os-endian */
+ case 22: /* BINARY DOUBLE os-endian */
+ case 100: /* BINARY FLOAT oracle-endian */
+ case 101: /* BINARY DOUBLE oracle-endian */
fbh->disize = 130+38+3; /* worst case */
- avg_width = 4; /* > approx +/- 1_000_000 ? */
+ avg_width = 4; /* NUMBER approx +/- 1_000_000 */
break;

case 12: /* DATE */
Sponsored Links





Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive | Programming forum archive

Copyright 2008 droptable.com