All -- I think I've got most, if not all the patches except the array
binding in now.
I have bind_param_inout in DBD::ODBC working for Oracle's ODBC driver --
however, I have found a problem, where I can't bind a null (undef). I'm not
sure what the issue is, at this time, but I can't pass a null to an in/out
parameter.
1 2 3
{ ? = call testfunc(?, ?) }
If parameters 2 or 3 are in/out and the bind value is null, then the Oracle
ODBC driver crashes. I don't know, yet, if it's something I'm doing or
something Oracle's doing. I'm going to look at it a bit further to see, but
I'd like to prepare a "developer" release privately available, so that it
can be tested by others. I'm working on that now. You should be able to
get to it by:
ftp://63.76.230.5/pub/perl/DBD-ODBC-0.29.tar.gz
(I'm having an issue where ls doesn't show directories in FTP clients, but
dir or ls -l do...so, if you don't see any files/directories, just cd to
pub/perl anyway...)
I have not yet tackled the array binding, as that requires a little more
thinking.
Here is the list of updates (from odbc.pm)
Cygwin patches from Neil Lunn (untested by me). Thanks Neil!
SQL_ROWSET_SIZE attribute patch from Andrew Brown
> There are only 2 additional lines allowing for the setting of
> SQL_ROWSET_SIZE as db handle option.
>
> The purpose to my madness is simple. SqlServer (7 anyway) by default
> supports only one select statement at once (using std ODBC cursors).
> According to the SqlServer documentation you can alter the default setting
> of
> three values to force the use of server cursors - in which case multiple
> selects are possible.
>
> The code change allows for:
> $dbh->{SQL_ROWSET_SIZE} = 2; # Any value > 1
>
> For this very purpose.
>
> The setting of SQL_ROWSET_SIZE only affects the extended fetch command as
> far as I can work out and thus setting this option shouldn't affect
> DBD::ODBC operations directly in any way.
>
> Andrew
>
VMS and other patches from Martin Brimer (thanks!)
[1] a fix for Makefile.PL to build DBD::ODBC on OpenVMS.
[2] fix trace message coredumping after SQLDriverConnect
[3] fix call to SQLCancel which fails to pass the statement handle properly.
[4] consume diagnostics after SQLDriverConnect/SQLConnect call or they
remain
until the next error occurs and it then looks confusing (this is due to
ODBC spec for SQLError). e.g. test 02simple returns a data truncated
error
only now instead of all the informational diags that are left from the
connect call, like the "database changed", "language changed" messages
you
get from MS SQL Server.
Replaced C++ style comments with C style to support more platforms more
easily.
Fixed bug which use the single quote (') instead of a double quote (") for
"literal" column names. This
helped when having a colon (:) in the column name.
Fixed bug which would cause DBD::ODBC to core-dump (crash) if DBI tracing
level was greater than 3.
Fixed problem where ODBC.pm would have "use of uninitialized variable" if
calling DBI's type_info.
Fixed problem where ODBC.xs *may* have an overrun when calling
SQLDataSources.
Fixed problem with DBI 1.14, where fprintf was being called instead of
PerlIO_printf for debug information
Fixed problem building with unixODBC per patch from Nick Gorham
Added ability to bind_param_inout() via patches from Jeremy Cooper. Haven't
figured out a good, non-db specific
way to test. My current test platform attempts to determine the
connected database type via
ugly hacks and will test, if it thinks it can. Feel free to patch and
send me something...Also, my
current Oracle ODBC driver fails miserably and dies.
Updated t/02simple.t to not print an error, when there is not one.