DBD-ODBC
view release on metacpan or search on metacpan
creating the test table first.
[MISCELLANEOUS]
Try and make the test suite run ok for SQLite ODBC driver so I can use it
in travis-ci.
1.51_3 2015-01-17
[BUG FIXES]
RT101579 - using bound input parameters for numeric columns (e.g.,
SQL_NUMERIC) only works the first time and will quite likely fail
with "string data, right truncation" on the second and subsequent
calls to execute. Thanks to Laura Cox for finding.
1.51_2 2014-11-19
[BUG FIXES]
The table_info method (ANSI version only) was incorrectly passing
the table name for the type argument. I think this bug was
introduced last year. Thanks to Nick Gorham for spotting and providing
a fix.
1.51_1 2014-11-14
[BUG FIXES]
RT100186 - handle VARBINARY(MAX) parameters with SQL Server native
client. Identify "libmsodbcsql*" as the MS ODBC Driver for Linux as
there are some specific workarounds for MS Native Client ODBC driver.
1.50 2014-07-25
[BUG FIXES]
The 80_odbc_diags.t test could fail if a driver fails a table does
not exist test in the prepare instead of the execute.
1.49_4 2014-07-08
[BUG FIXES]
Fixed sql_type_cast.t test which assumed column aliases which stay
lowercase.
Fixed 87_odbc_lob_read.t test which did not bow out of the test
properly if the database was not MS SQL Server.
[DOCUMENTATION]
Revised the query notification example and documentation.
Added a link to a better Query Notification article.
1.49_3 2014-05-01
[CHANGE IN BEHAVIOUR]
As warned years ago, this release removes the odbc_old_unicode attribute.
If you have a good reason to use it speak up now before the next non-development
release.
[BUG FIXES]
Fix rt89255: Fails to create test table for tests using PostgreSQL odbc driver.
Change test suite to fallback on PRECISION if COLUMN_SIZE is not found.
[ENHANCEMENTS]
Added support for MS SQL Server Query Notification. See the new
section in the pod.
Added a currently undocumented (and experimental)
odbc_describe_param method on a statement handle which takes a
parameter number as the only argument and returns an array of the
data type, parameter size, decimal digits and nullable (as per
SQLDescribeParam).
[DOCUMENTATION]
Added FAQ on truncated column names with freeTDS.
[MISCELLANEOUS]
I have removed the "experimental" tag for odbc_getdiagfield and odbc_getdiagrec
methods.
1.49_2 2014-04-26
[BUG FIXES]
Change to data_sources in 1.49_1 could lead to a compile error since
data_sources was not returning a value if an error occurred.
1.49_1 2014-04-25
[BUG FIXES]
If you had a lot of DSNs on Windows (more than 280 but it depends on
the length of their names) and called the data_sources method it
could crash your script. Code internally changed to stop putting the DSNs
returned on the stack.
[CHANGE IN BEHAVIOUR]
As warned years ago, the private data_sources method has been
removed - use DBI one instead.
[MISCELLANEOUS]
Added FAQ entry of maximum number of allowed parameters.
1.48 2014-03-03
[MISCELLANEOUS]
Manifest has wrong filename for 90_trace_flags.t
Forgot to remove warning from ODBC.pm that this is a development
release and unicode change when I released 1.47.
1.47 2014-02-19
Full release of the 1.46 development releases.
[MISCELLANEOUS]
Just some tidying up of dbdimp.c - shouldn't make a difference to anyone.
Further changes to this change file to make it CPAN::Changes spec.
NOTE the changes.cpanhq.com site does not yet support "unknown" for
dates.
1.46_2 2013-12-17
[BUG FIXES]
When built with unicode support and odbc_old_unicode is not enabled
columns reported as SQL_LONGVARCHAR were not by default bound as
SQL_WCHAR and hence were not returned correctly unless the bind was
overridden.
[MISCELLANEOUS]
Added test 90_trace_flag.t
1.46_1 2013-11-16
[CHANGE IN BEHAVIOUR]
As warned in release 1.45, the binding of unicode parameters to
char/varchar columns has changed significantly. If you don't attempt
to insert unicode into char/varchar columns or if you only inserted
unicode into nchar/nvarchar columns you should see no difference.
From this release, unicode data inserted into
char/varchar/longvarchar columns is bound as SQL_WCHAR and not
whatever the driver reports the parameter as (which is mostly
SQL_CHAR).
Previously if DBD::ODBC received an error or (SQL_SUCCESS_WITH_INFO)
from an ODBC API call and then the driver refused to return the
error state/text DBD::ODBC would issue its own error saying "Unable
to fetch information about the error" and state IM008. That state
was wrong and has been changed to HY000.
[BUG FIXES]
Some drivers cannot support catalogs and/or schema names in
SQLTables. Recent changes set the schema/catalog name to the empty
string (good reasons below) which causes "optional feature not
implemented" from MS Access (which does not support schemas - even
for a simply ping (which uses SQLTables)). Now we call
SQLCATALOG_NAME and SQLSCHEMA_USAGE on connect to ascertain support
which modifies SQLTables call.
[MISCELLANEOUS]
Added test 45_unicode_varchar.t for MS SQL Server only so far.
1.45 2013-10-28
[CHANGE IN BEHAVIOUR]
There is no intentional change in behaviour in this release but I'm
adding a warning that the next development release is highly liking
to contain some significant unicode changes in behaviour to fix some
bugs which have been around for quite a long time now.
[BUG FIXES]
If an SQLExecute ODBC API call returned SQL_NO_DATA DBD::ODBC was
still calling SQLError (which was a waste of time).
Since 1.44_1 odbc_out_connect_string stopped returning anything.
[MISCELLANEOUS]
Added another link to resources for supplementary characters.
Added 1 more test to 20SqlServer.t for update statement.
Small changes to 20SqlServer.t test to skip some tests and note the
problem if SQLExecute returns SQL_NO_DATA on a non searched update.
1.44_4 2013-10-16
[BUG FIXES]
Fix method redefinition warnings in threads on Perl >= 5.16 thanks
Dagfinn Ilmari Mannsåker
[MISCELLANEOUS]
Changed this Changes file to be closer to the version 0.03 change
file spec.
Added t/version.t test.
Added recommends Test::Version.
Updates to the odbc_more_results pod to help clarify its use after
some confusion was seen in a perlmonks thread.
1.44_3 2013-10-11
[CHANGE IN BEHAVIOUR]
If you attempt to set the ReadOnly attribute and the underlying
ODBC driver does not support this (SQL_SUCCESS_WITH_INFO and "option
value changed" is returned) a warning is issued. However, until RT
89015 "You cannot issue a warning in the STORE method" in DBI is
resolved you won't get this warning. As DBI 1.628 it is not
resolved. I've only seen the SQLite ODBC driver do this.
If you set ReadOnly and the underlying ODBC driver does not
support this then any subsequent attempts to fetch the ReadOnly
attribute will return the value you set.
[BUG FIXES]
The 82_table_info test assumed all database and ODBC Drivers
supported catalogs and schemas (some don't). Use get_info to
find out if catalogs and schemas are supported before
running these tests.
The rt_79190.t could incorrectly fail if your test DSN contained
[MISCELLANEOUS]
New rt_81911.t test case.
1.42_0 2012-11-28
[BUG FIXES]
MS Access requires a longchar column to be bound using SQL_LONGVARCHAR.
However, MS Access does not support SQLDescribeParam and we default to
SQL_VARCHAR in this case. The point at which we switch to SQL_LONGVARCHAR
was defaulted to 4000 (for MS SQL Server). We now default to SQL_LONGVARCHAR
for MS Access when data is > 255. This means you can remove those
{TYPE => SQL_LONGVARCHAR} from your bind_param calls for longchar columns
in MS Access.
I seem to have introduced a bug in the test suite for MS Access.
The last test in the 09bind test binds dates as varchars (by
default) and this cannot work in MS Access (it needs to be a
timestamp). This test was skipped in the past and the skip got
removed.
[MISCELLANEOUS]
Steffen Goeldner reported some issues with execute_array in
DBD::Oracle where if ArrayTupleStatus was not specified and an error
occurred DBD::Oracle did not do the right thing. As I used
DBD::Oracle as a base when I wrote execute_for_fetch in DBD::ODBC I
added tests to the test suite to ensure these issues did not exist
in DBD::ODBC.
Minor change to sql_type_cast.t test which attempts to insert an
integer into a varchar. No databases so far have complained about
this until we ran the test against Derby. Changed to use '100'.
RT 80446 - fix spelling mistake - thanks to Xavier Guimar.
1.41 2012-10-23
A full release of the 1.40 development release series.
1.40_3 2012-10-08
[BUG FIXES]
Oops, changes to some rt tests fail when not run to MS SQL Server
and they should not be run for other drivers - there was a double
done_testing call.
[CHANGE IN BEHAVIOUR]
As I warned literally years ago DBD::ODBC's private function
DescribeCol has been removed. You can use DBI's statement attributes
like NAME, PRECISION etc, instead. All test code has been changed to
remove calls to DescribeCol and GetTypeInfo.
[MISCELLANEOUS]
New example sqlserver_supplementary_chrs.pl added which shows that
in MS SQL Server 2012 you can now store unicode characters
over 0xFFFF (ones which are surrogate pairs).
More documentation for odbc_out_connect_string.
1.40_2 2012-09-06
[BUG FIXES]
Fixed rt 78838 - bind_param does not correctly stringify blessed
objects when connected to MS SQL Server
Fix issue in dbd_bind_ph where if you passed a sql type and were
also attempting to change from in to out or vice versa or increasing
the size of an output bound param it would not spot this error.
Allowed the test cases to spot DB2 driver as libXXXdb2.
[MISCELLANEOUS]
New test cases added for some rts.
Added Test::NoWarnings to some tests where it was missing.
1.40_1 2012-09-04
[BUG FIXES]
Debian/Ubuntu have moved unixODBC into /usr/lib/i386-linux-gnu
so look in this dir for unixODBC as well - thanks to Meastro for finding.
Fixed rt 78838
I had a sequence point error which is only seen with some compilers
as it is sometimes optimized out. It could cause DBD::ODBC to omit
adding the UID/PWD to the end of the connection string when using DSN=.
Thanks to Zsolt Cserna for spotting it and to ilmari and Leon for
explaining it to me.
Fixed rt 79397
Output bound parameters may be incorrectly bound if changed after
bind_param_inout is called. If you start with an undef bound param
and change it to a defined string/number less than 28 characters
before calling execute the original undef will probably be bound.
Thanks to runrig on perl monks for providing an example.
[CHANGE IN BEHAVIOUR]
If you attempt to bind an rv without amagic DBD::ODBC will now
croak - related to rt 78838.
1.39 2012-07-07
[BUG FIXES]
Manifest mentioned 2 files in examples which do not exist - they
should have been execute_for_fetch.pl.
execute_for_fetch.pl example had not be changed since
odbc_disable_array_operations became odbc_array_operations.
1.38_3 2012-06-25
* Fix bug in execute_for_fetch where it would ignore the parameters
processed when creating the ArrayTupleStatus and hence could
attempt to call SQLGetDiagRec on a parameter row which was not
executed. See the logs in rt 75687 which show this although this
is not a fix for this rt.
* The code wasn't catching success with info from SQLExecute in
execute_for_fetch.
* Add support for drivers (DB2 in this case) which return
SQL_PARAM_DIAG_UNAVAILABLE in bound parameter status array when
running execute_for_fetch. Any driver returning doing
SQL_PARC_NO_BATCH from SQLGetInfo(SQL_PARAM_ARRAY_ROW_COUNTS)
might do this.
* Fix test code for execute_for_fetch to a) handle drivers doing
SQL_PARC_NO_BATCH and b) add "not null" to primary key fields for
drivers like DB2 which require it.
[CHANGE IN BEHAVIOUR]
* In execute_for_fetch set the parameter status array to all 9999
(which is invalid) so we can see if the ODBC driver actually sets
them and we can warn if they don't.
* For freeTDS default odbc_disable_array_operations to 1 as no
version of the freeTDS driver can be found that works. I was
requested to do this by the dbix-class guys. I may revert this
later if freeTDS is fixed.
* as above for MS Access. It is a shame I cannot find any way of
finding out if a driver is capable of array operations.
[ENHANCEMENTS]
* execute_for_fetch code now checks the
ODBC_DISABLE_ARRAY_OPERATIONS environment variable which can
be set to 1 or 0 to override the internal default.
[DOCUMENTATION]
* Fixed ColAttributes example in pod which used a $dbh instead of a
$sth.
* Fixed DescribeCol example in pod which used a $dbh instead of a
$sth.
* new FAQ on SQLRowCount, freeTDS and execute_for_fetch
* Fix typo shown in rt 75860.
[OTHER]
* Reduced usage of D_imp_xxx to avoid calls to dbih_getcom2. See
thread on dbi-dev at
http://www.mail-archive.com/dbi-dev@perl.org/msg06675.html
* Changed the 70execute_array.t test to run it twice, once using
DBI's methods and once using the native one in DBD::ODBC.
* Made the 2 unicode tests work with DB2 ODBC driver.
1.35 2012-03-06
Full release of the 1.34 development releases
1.34_7 2012-03-02
[BUG FIXES]
* Fixed more compiler errors highlighed by a smoker using MS Visual
C where some code come before a variable definition.
1.34_6 2012-02-27
[BUG FIXES]
* Fixed some compiler warnings and a compile error highlighed by a
smoker using MS Visual C where some code come before a variable
definition.
1.34_5 2012-02-17
[BUG FIXES]
* The 40UnicodeRoundTrip tests counts could be 1 off in some cases.
* Fix for t/03batt.t which could fail a test if the data source had
no table - Kenichi Ishigaki
* If a driver misbehaves during global destruction e.g. SQLFreeStmt
fails but no error is available DBD::ODBC issues an error saying
an error occurred but no error diagnostics could be found. This is
pointless and irritating during global destruction. This stems
from a change in 1.28. Thanks to Peter Rabbitson for reporting
and suggested fix.
[CHANGE IN BEHAVIOUR]
* Prior to this release if you called selectall_* methods with a
non-select statement DBD::ODBC would raise an error saying "no
select statement currently executing". See RT 68720. After
discussions on dbi-dev the concensus seems to be that issuing a
warning in this case is better so that is what I've done. As a
result t/rt_68720.t has been removed and
t/85_selectall_non_select.t has been added.
[DOCUMENTATION]
* odbc_getdiagfield was incorrectly named odbc_getdiagrec in the pod
* add DBI version required for StrictlyTyped and DiscardString to
pod
* Added new FAQ on why a transaction may be committed when
AutoCommit is turned off.
[OTHER]
* Make examples\odbc_diag.pl more tolerant of drivers which do not
handle diagnostic calls properly.
* New FAQ entries.
1.34_2 2012-01-25
[BUG FIXES]
* Fixed rt73734 - debian moved where unixODBC libs are stored.
* Fixed memory leak of the parameter status array introduced in
previous release when execute_for_fetch used. When the statement
handle is destroyed the parameter status array was not freed.
[ENHANCEMENTS]
* Added environment variable PERL_DBD_ODBC_PREFER_UNIXODBC as a
synonym for -x from Rafael Kitover (Caelum).
[DOCUMENTATION]
* Add a deviation from DBI spec for type_info_all.
[OTHER]
* Added example execute_for_fetch.pl
1.34_1 2011-12-11
[ENHANCEMENTS]
* Added experimental execute_for_fetch support and associated
attributes odbc_batch_size and odbc_disable_array_operations.
1.33 2011-12-01
This is simply the official release of the 1.32 development
releases.
1.32_5 2011-11-24
[ENHANCEMENTS]
* Enable multiple active statement support in 70execute_array.t for
drivers we recognise which support MAS.
* Change column_info to support Unicode catalog/schema/table/column
names.
1.32_4 2011-11-22
[BUG FIXES]
* remove debugging printf which output "HERE" in some rare cases.
rt 72534 - thanks John Deighan for spotting this.
* The test 70execute_array.t could fail due to warning being output
if the driver does not support Multiple Active Statements.
[ENHANCEMENTS]
* Use SQLGetTypeInfoW on unicode builds.
1.32_3 2011-11-15
[BUG FIXES]
* Fix bug in utf16_copy which was not adding a trailing NUL but I'm
not sure this affected anyone until I changed table_info this
release.
[ENHANCEMENTS]
* DBD::ODBC now allows unicode catalog/schema/table parameters to be
passed to table_info. Of course they will only reliably work with
a supporting Unicode ODBC driver.
1.32_2 2011-10-22
[ENHANCEMENTS]
* Added new odbc_driver_complete attribute allowing the ODBC Driver
Manager and ODBC Driver to throw dialogues for incomplete
connection strings or expired passwords etc.
[OTHER]
* added more examples
[DOCUMENTATION]
* new FAQ entries
* added note saying you cannot pass unicode schema/table/column
names to metadata calls like table_info/column_info currently.
1.32_1 2011-06-24
[BUG FIXES]
* I omitted rt_68720.t from the 1.31 distribution which leads
to a warning as it is mentioned in the MANIFEST.
[OTHER]
* Changed line endings in README.af and README.unicode to be unix
line endings and native eol-style in subversion.
* Minor changes to Makefile.PL to save the opensuse guys patching.
* Added unicode_sql.pl and unicode_params.pl examples
1.31 2011-06-21
[BUG FIXES]
Recently introduced test sql_type_cast.t cannot work with DBI less
than 1.611.
Minor change to Makefile.PL to avoid use of unitialised warning on
$ENV{LD_LIBRARY_PATH} in warning when it is not set.
1.30_7 2011-06-15
[BUG FIXES]
Some time ago (I don't know when) a few internal errors generated by
DBD::ODBC got ignored. There are about 5 of them but I seriously
doubt anyone would hit any other than the data truncated error
(which is reported by the ODBC driver anyway) and "no select
statement currently executing". You can see rt_68720.t in the t
directory for an example of the latter.
[ENHANCEMENTS]
An extra argument has been added to the sub associated with
odbc_err_handler. The arguments passed to the odbc_err_handler are
now state (string), error (string), native error code (number) and
the status returned from the last ODBC API. The status will be
SQL_ERROR (-1) for errors or SQL_SUCCESS_WITH_INFO (1) for
informational messages.
1.30_6 2011-06-04
[BUG FIXES]
* When DBD::ODBC calls SQLExecDirect (the do method) it was not
reporting informational diagnostics (SQL_SUCCESS_WITH_INFO) and
not calling the error handler.
Arguably, this is a change in behaviour but one I've struggled to
resolve since in all other cases of warnings DBD::ODBC's error
handler is called. However, DBI does not call its error handler
for warnings so was DBD::ODBC wrong to call it's error in the
first place for warnings? I decided it was better to leave this as
it is but add checking of SQLExecDirect/do. Apart from anything
else if DBD::ODBC does not call its error handler for
informational diagnostics there is no way to retrieve print
statements etc from procedures.
* The odbc_describe_parameter.t test could fail with some versions
of MS SQL Server ODBC Driver. It was down to when
SQLDescribeParameter is disabled, the column_size passed to
SQLBindParameter is 0.
* pod example of odbc_err_handler incorrectly used \$err_handler
instead of \&err_handler.
1.30_5 2011-05-24
[BUG FIXES]
1.30_4 2011-05-18
[BUG FIXES]
* Fix issue described in
http://www.nntp.perl.org/group/perl.dbi.dev/2011/05/msg6567.html.
If you prepare a statement, disconnect and then try and execute the
statement you get an error but it does not tell what is wrong.
[ENHANCEMENTS]
* Added support for StrictlyTyped and DiscardString to the bind_col
method.
[OTHER]
* Minor changes to META.yml for mailing list, dynamic_config,
homepage and keywords.
* The pod was missing = before the heads on a couple of sections in
"Private DBD::ODBC Functions"
* TreatAsLob was incorrectly documented as BindAsLob.
1.30_3 2011-05-17
[BUG FIXES]
* Made the new odbc_describe_parameters work and added test case.
1.30_2 2011-05-16
[ENHANCEMENTS]
* Added the new odbc_describe_parameters attribute.
1.30_1 2011-05-12
[BUG FIXES]
* Fixed some compiler warnings shown with -Wall including some
printf formats that had extra/missing arguments.
* Fixed t/70execute_array.t which was missing an "order by" in the
check_data sub which could cause failures for drivers not
returning the rows in the order they were inserted.
* Minor fix to Makefile.PL to avoid issuing variable used in void
context.
[CHANGE IN BEHAVIOUR]
* DBD::ODBC used to quietly rollback any transactions when
disconnect was called and AutoCommit was off. This can mask a
problem and leads to different behaviour when disconnect is called
vs not calling disconnect (where you get a warning). This release
issues a warning if you call disconnect and a transaction is in
progress then it is rolled back.
* DBD::ODBC used to bind char/varchar/longvarchar columns as SQL_CHAR
meaning that in the unicode build of DBD::ODBC the bound column
data would be returned 8bit in whatever character-set (codepage) the
data was in, in the database. This was inconvenient and arguably a
mistake. Columns like nchar/nvarchar etc were bound as SQL_WCHAR and
returned as Unicode. This release changes the behaviour in a unicode
build of DBD::ODBC to bind all char columns as SQL_WCHAR. This may
inconvenience a few people who expected 8bit chars back, knew the
char set and decoded them (sorry). See odbc_old_unicode to return
to old behaviour.
[ENHANCEMENTS]
* added -w option to Makefile.PL to add "-Wall" to CCFLAGS and
-fno-strict-aliasing so I can find warnings.
* Cope with broken ODBC drivers that describe a parameter as SQL
type 0.
[OTHER]
* Add "disconnect and transactions" to pod describing what DBD::ODBC
does if you call disconnect with an outstanding transaction.
* Reorganised FAQ for bound parameter issues and added a lot on
bound parameter problems.
* Added new FAQ entry for Firebird
* Removed some unused variables and added some missing function
prototypes
1.29 2011-03-08
* An official release of the 1.28 development releases.
[NOTE]
* The 1.28 development releases made a change which causes a generic
error to be reported when an ODBC call fails but an error message
is not retrieved from the ODBC Driver. It appears this has caught
out a few ODBC drivers - notably freeTDS and Firebird. You now may
see errors that were missed before e.g., DBIx::Class's tests for
Firebird now errors test 21 "outer txn rolled back" (and others)
because SQLRowCount returns an error after "ROLLBACK TO SAVEPOINT
savepoint_0"; before this error was missed.
1.28_5 2011-03-06
[BUG FIXES]
* rt_59621.t had wrong skip count
* Fixed missing SQL_MAX_TABLE_NAME_LEN definition from test.
* Fixed problem with some drivers which batch "insert;select" where
SQLMoreResults is not required and an extra describe is done.
* Fixed "select 1" in 02simple.t for Firebird ODBC Driver.
* disconnect call added to 70execute_array.t was in the wrong place.
* In non-unicode mode we bind strings as SQL_CHAR but the driver may
have described them as SQL_WCHAR and we were not doing ChopBlanks
processing in that case.
[REQUIREMENTS]
* Now needs Test::Simple 0.90.
[OTHER]
* Added dml_counts.pl example
* worked around a problem in freeTDS in the 20SqlServer.t test
provided by Ralph Doncaster.
* Changed test rt_62033.t to try and make it work with freeTDS - I
failed. It now skips attempts to fetch when the insert fails.
* Worked around problem in Firebird ODBC driver which reports
timestamps have a display size of 24 characters but then can
return 29 which could lead to data truncation errors.
See http://tracker.firebirdsql.org/browse/ODBC-112
* Worked around problem in Firebird ODBC driver which reports
VARCHARs have a maximum length of 32765 but in fact it is 4000.
See http://tracker.firebirdsql.org/browse/ODBC-111
* Improvements in tracing to take account of DBI's neatsvpv lops 5
characters off maxsize on a string.
1.28_4 2011-02-24
[BUG FIXES]
* Fixed compilation problems with DBIf_TRACE_TXN
* Added missing disconnect call to 70execute_array.t
1.28_3 2011-02-22
[BUG FIXES]
* Fixed MANIFEST in 1.28_2 which named 2 files incorrectly.
* Fixed use of PREREQ_PRINT in versions of ExtUtils::MakeMaker which
don't support it.
* Fixed a check on LD_LIBRARY_PATH for unixODBC which could report
you've not set LD_LIBRARY_PATH correctly.
[ENHANCEMENTS]
* Added Perl and ExtUtils::MakeMaker version output to build process.
* Added support for DBI's new trace flags ENC, CON, TXN and
DBD. From DBI 1.617 you should be able to use: DBI_TRACE=DBD to
ONLY get DBD::ODBC tracing without DBI tracing ENC and CON DBI
flags are synonymous with DBD::ODBC's odbcconnection and
odbcunicode trace flags which you can still use for now.
[OTHER]
* From now on I'm changing the way the Changes file is written as
per article at
http://blog.urth.org/2011/01/changes-file-how-and-how-not-to.html
* Some broken drivers (freeTDS in this case) can return SQL_ERROR
from an ODBC API function and then SQLError does not return
error details. In this case set a generic error saying an error
occurred but we could not retrieve it.
* Added FAQ entry on MS Access and text columns limited to 255 chrs.
* Added 70execute_array.t test.
1.28_2 2011-01-24
Added -x argument to Makefile.PL saying you prefer unixODBC over
iODBC driver managers as a) we need to look for iODBC first on some
platforms to detect iODBC and b) some platforms (Debian/Ubuntu)
people have both binary packages installed but only unixODBC dev
package.
Patch from Rafael Kitover (Caelum) for better Cygwin handling.
Minor change to data sources test to cope with someone having no
data sources and using a DSN-less connection for testing.
Fixed MARS test when a DSN-less connection used for testing - thanks
to Rafael Kitover (Caelum) for spotting this.
pod patch for "CPAN Testers Reporting" to point at cpan testers wiki
from Rafael Kitover (Caelum).
Fixed some broken links in the FAQ.
Add a multiple active statement document link to random links and
the FAQ entry.
A call to SQLNumResultCols was not checked to test it succeeded.
Not seen anyone run into this as yet.
1.28_1 2010-12-29
Rewrote documentation on odbc_SQL_ROWSET_SIZE and added loads of
notes so I don't have to go through a huge irc conversation with
ribasushi again.
Workaround bug in DBI (prior to 1.616) which mistakenly issues a
FETCH on any attribute passed to the connect method and sometimes
driver managers error on SQL_ROWSET_SIZE in SQLGetConnectAttr.
ChopBlanks was not working on UCS-2 encoded data written into bound
columns and was also sometimes reading off the end of the bound
array.
Minor FAQ changes:
Added an additional way to read MS Access dbs from Unix
Clarified versions for MARS_Connection
1.26_4 2010-12-14
Fixed bug highlighted by investigation into rt 62033 where the
active flag was sometimes not set on the statement after
SQLMoreResults indicates a result-set exists.
Fix rt 63550 reported by John Corcoran where if a do method call
fails the SQL C<Statement> is not available in an error handler as
we never created a DBI statement in the first place. Added a note
to "do" deviations pod.
Minor fix to head at wrong level in the pod.
Fix a possible snprintf buffer overflow in GetTypeInfo when
the type is specified and it is negative.
1.26_3 2010-11-18
Fixed rt 63108. The change to column binding in 1.24_2 was not
complete and causes bound columns to be rebound on each execute
wasting time and leaking memory. Found, diagnosed and proposed fix
by Steve Bentley.
1.26_2 2010-11-09
Fixed bug found by frew where an snprintf can overflow when binding
a lot of parameters.
1.26_1 2010-10-24
There are over 200 block changes in the source code for this release
from the previous one (see below). If you are using DBD::ODBC in
production you should not upgrade without testing this release first
as it introduces a lot of internal changes. DBD::ODBC has now gone
entirely ODBC 3 and relies on an ODBC Driver Manager to map calls
to ODBC 2.0 drivers (why are you still using ODBC 2.0 drivers?).
From now on DBD::ODBC needs to be linked with an ODBC Driver Manager
and I recommend unixODBC on UNIX and the MS ODBC Driver Manager
on Windows. There are really good reasons for this but mainly it
is because an ODBC Driver Manager will map ODBC 2.0 calls to an
ODBC 3.0 driver and vice versa and handle UNICODE transparently.
Bumped Test::Simple requirement up to 0.90 so we can use done_testing
and note.
Bump Perl requirement to 5.8 as per DBI.
Workaround a bug in mdbtools which fails to set the out connection
string in a SQLDriverConnect call. This can lead to:
Fixed panic: sv_setpvn called with negative strlen at
blib/lib/DBD/ODBC.pm line 107.
Added rt_61370.t for rt 61370.
Removed last remaining sprintf calls and replaced with snprintf.
Changed the point at which DBD::ODBC switches from VARCHAR to
LONGVARCHAR or WVARCHAR to WLONGVARCHAR when SQLDesribeParam fails. It
was 4000 and is now 2000 for unicode builds. Works around a daft issue
in the MS SQL Server driver which will not allow 'x' x 2001 converted to
wide characters to be inserted into a varchar(8000).
Minor change to Makefile.PL to print out found libs for iODBC and
unixODBC.
Added some FAQs for problems with iODBC and a recent bug in DBI.
Added FAQ on my_snprintf problem.
Fixed some pod errors in FAQ document.
Fixed warning on 64 bit Strawberry Perl when compiling dbdimp.c for
cast from ptr to UDWORD.
Moved to_do items from Changes to TO_DO.
Reformatted this file to save Jens work.
Changed calls to SQLTransact (ODBC 2.0) to SQLEndTran (ODBC 3.0).
There really shouldn't be any ODBC 2.0 drivers still around but even
if there are, the ODBC driver manager should do the mapping for us.
Changed calls to SQLGetConnectOption/SQLSetConnectOption to
to SQLGetConnectAttr/SQLSetConnectAttr for ODBC 3.0.
Changed calls to SQLColAttributes (ODBC 2.0) to SQLColAttribute
(ODBC 3.0).
Bumped requirement on DBI to 1.609 because that is the first version
to contain a dbipport.h which defined my_snprintf - see
https://rt.cpan.org/Public/Bug/Display.html?id=62346 and
http://www.nntp.perl.org/group/perl.dbi.dev/2010/10/msg6335.html
Various small changes to dbdimp.c which should have no effect other
than to make it leaner:
Removed all dTHR occurrences from dbdimp.c as it is a NOOP since 5.8
and we need 5.8 at least.
Removed dbd_param_err as it was not used
Removed odbc_get_query_timeout as it was never compiled
Removed eod field from statement as it was never used
Removed a load of commented out code
Replaced some SvPV calls with SvPV_nolen when we didn't used the
length
Removed some silly code from dbd_db_execdirect which attempted to
return -3 - don't think it could ever get run.
Minor tracing output tidy up
Removed dbd_caution as it was no used
Localised more variable declarations
1.25 2010-09-22
Official release of 1.25 combining all the changes in the 1.24_x
development releases.
1.24_6 2010-09-16
rt 61370 - default XML type parameters in SQL Server to SQL_WCHAR so
they accept unicode strings.
1.24_5 2010-09-15
Fixed missing SvSETMAGIC on a bound scalar which was causing length() to
return the wrong result - see http://www.perlmonks.org/?node_id=860211
and a big thank you to Perl Monks and in particular ikegami.
Changed bind_col so it actually pays attention to the TYPE attribute as
you could not override the bind type of a bound column before.
1.24_4 2010-09-08
Left a sv_undef in - thanks smoke testers for finding that.
Change sprintf to snprintf for safety.
1.24_3 2010-09-06
Added note from Robert Freimuth for obtaining the last insert ID in MS
Access.
Changed all &sv_yes/&sv_no occurrances in XS to PL_sv_yes/PL_sv_no as
the originals have now gone from blead Perl.
Minor change to fix missing newline in trace output.
Added a FAQ entry for how "use regional settings" in MS SQL Server
breaks things.
1.24_2 2010-07-23
Fix rt57957 reported by Marc Prewitt. DBD::ODBC was not ignoring named
placeholders and ? inside comments. Comments are deemed as text between
"/*" and "*/" (if not in a literal) and line comments begin with "--".
Added a FAQ on procedures not completing in MS SQL Server. Thanks to
Peter Rabbitson for hitting this problem and reminding me I'd seen it a
couple of times before.
Added a FAQ on equality comparisons with ntext columns.
Added pod for last_insert_id which is not currently supported.
Fix bug where if SQLMoreResults was called and failed it was not
reported.
Removed some unused fields from the fbh structure which should save a
little memory for each column in a result-set.
Started adding support for DBI's DiscardString and StrictlyTyped but not
complete yet so don't use them yet.
Added experimental odbc_lob_read method - see pod. Thanks to tye and
ikegami on perlmonks for pointing out some problems with my initial
implementation.
Moved the binding of columns to the first call to fetch instead of after
execute is called as it prevents bind_col overrriding the type used for
binding and I needed it to support odbc_lob_read. This may have
undesired affects so any testing of this release would be appreciated.
1.23_3 2010-03-24
Minor changes to Makefile.PL and dbdimp.c to remove some compiler
warnings.
Fix some calls to SQLMoreResults which were not passing informational
messages on to DBI's set_err. As you could not see all the informational
messages from procedures, only the first.
Fix minor issue in 02simple test which printed the Perl subversion
before the version.
Changes to 20SqlServer.t to fix a few typos and make table names
consistent wrt to case - (as someone had turned on case-sensitivity in
SQL Server) Similar changes in rt_38977.t and rt_50852.t
1.23_2 2010-01-26
Fixed bug in Makefile.PL which could fail to find unixODBC/iODBC header
files but not report it as a problem. Thanks to Thomas J. Dillman and
his smoker for finding this.
Fixed some compiler warnings in dbdimp.c output by latest gcc wrt to
format specifiers in calls to PerlIO_printf.
Added the odbc_force_bind_type attribute to help sort out problems with
ODBC Drivers which support SQLDescribeParam but describe the parameters
incorrectly (see rt 50852). Test case also added as rt_50852.t.
1.23_1 2009-10-21
makefile.PL changes:
some formatting changes to output warn if unixodbc headers are not
found that the unixodbc-dev package is not installed use $arext
instead of "a"
pattern match for pulling libodbc.* changed
warn if DBI_DSN etc not defined
change odbc_config output for stderr to /dev/null
missing / on /usr/local wheb finding find_dm_hdr_files()
New FAQ entries from Oystein Torget for bind parameter bugs in SQL
Server.
rt_46597.rt - update on wrong table
Copied dbivport.h from the latest DBI distribution into DBD::ODBC.
Added if_you_are_taking_over_this_code.txt.
Add latest Devel::PPPort ppport.h to DBD::ODBC and followed all
recommendations for changes to dbdimp.c.
Added change to Makefile.PL provided by Shawn Zong to make
Windows/Cygwin work again.
Minor change to Makefile.PL to output env vars to help in debugging
peoples build failures.
Added odbc_utf8_on attribute to dbh and sth handles to mark all strings
coming from the database as utf8. This is for Aster (based on
PostgreSQL) which returns all strings as UTF-8 encoded unicode. Thanks
to Noel Burton-Krahn.
1.23 2009-09-11
Only a readme change and version bumped to 1.23. This is a full release
of all the 1.22_x development releases.
1.22_3 2009-08-19
Fix skip count in rt_38977.t and typo in ok call.
Workaround a bug in unixODBC 2.2.11 which can write off the end of the
string buffer passed to SQLColAttributes.
Fix skip count in rt_null_nvarchar.t test for non SQL Server drivers.
Fix test in 02simple.t which reported a fail if you have no ODBC
datasources.
In 99_yaml.t pick up the yaml spec version from the meta file instead of
specifying it.
Change calls to SQLPrepare which passed in the string length of the SQL
to use SQL_NTS because a) they are null terminated and more importantly
b) unixODBC contains a bug in versions up to 2.2.16 which can overwrite
the stack by 1 byte if the string length is specified and not built with
iconv support and converting the SQL from ASCII to Unicode.
Fixed bug in ping method reported by Lee Anne Lester where it dies if
used after the connection is closed.
A great deal of changes to Makefile.PL to improve the automatic
detection and configuration for ODBC driver managers - especially on
64bit platforms. See rt47650 from Marten Lehmann which started it all
off.
Add changes from Chris Clark for detecting IngresCLI.
Fix for rt 48304. If you are using a Microsoft SQL Server database and
nvarchar(max) you could not insert values between 4001 and 8000
(inclusive) in size. A test was added to the existing rt_38977.t test.
Thanks to Michael Thomas for spotting this.
Added FAQ on UTF-8 encoding and IBM iSeries ODBC driver.
Add support for not passing usernames and passwords in call to connect.
Previously DBD::ODBC would set an unspecified username/password to '' in
ODBC.pm before calling one of the login_xxx functions. This allows the
driver to pull the username/password from elsewhere e.g., like the
odbc.ini file.
1.22_1 2009-06-16
Applied a slightly modified version of patch from Jens Rehsack to
improve support for finding the iODBC driver manager.
A UNICODE enabled DBD::ODBC (the default on Windows) did not handle
UNICODE usernames and passwords in the connect call properly.
Updated "Attribution" in ODBC.pm.
Unicode support is no longer experimental hence warning and prompt
removed from the Makefile.PL.
old_ping method removed.
Fixed bug in 02simple.t test which is supposed to check you have at
least one data source defined. Unfortunately, it was checking you had
more than 1 data source defined.
rt_null_varchar had wrong skip count meaning non-sql-server drivers or
sql server drivers too old skipped 2 tests more than were planned.
1.22 2009-06-10
Fixed bug which led to "Use of uninitialized value in subroutine entry"
warnings when writing a NULL into a NVARCHAR with a unicode-enabled
DBD::ODBC. Thanks to Jirka Novak and Pavel Richter who found, reported
and patched a fix.
Fixed serious bug in unicode_helper.c for utf16_len which I'm ashamed
to say was using an unsigned short to return the length. This meant you
could never have UTF16 strings of more than ~64K without risking
serious problems. The DBD::ODBC test code actually got a
*** glibc detected *** /usr/bin/perl: double free or corruption
(out): 0x406dd008 ***
If you use a UNICODE enabled DBD::ODBC (the default on Windows) and
unicode strings larger than 64K you should definitely upgrade now.
1.21_1 2009-06-02
Fixed bug referred to in rt 46597 reported by taioba and identified by
Tim Bunce. In Calls to bind_param for a given statement handle if you
specify a SQL type to bind as, this should be "sticky" for that
parameter. That means if you do:
$sth->bind_param(1, $param, DBI::SQL_LONGVARCHAR)
and follow it up with execute calls that also specify the parameter:
$sth->execute("a param");
then the parameter should stick with the SQL_LONGVARCHAR type and not
revert to the default parameter type. The DBI docs (from 1.609) make it
clear the parameter type is sticky for the duration of the statement but
some DBDs allow the parameter to be rebound with a different type -
DBD::ODBC is one of those drivers.
1.21 2009-04-27
Change 02simple test to output Perl, DBI and DBD::ODBC versions.
Fixed bug where if ODBC driver supports SQLDescribeParam and it succeeds
for a parameterised query but you override the parameter type, DBD::ODBC
was still using the size returned by SQLDescribeParam. Thanks to Brian
Becker for finding, diagnosing and fixing this issue.
Added FAQ entry about SQL Server and calling procedures with named
parameters out of order.
Added test_results.txt containing some supplied make test results.
1.20 2009-04-20
Fix bug in handling of SQL_WLONGVARCHAR when not built with unicode
support. The column was not identified as a long column and hence the
size of the column was not restricted to LongReadLen. Can cause
DBD::ODBC to attempt to allocate a huge amount of memory.
Minor changes to Makefile.PL to help diagnose how it decided which
driver manager to use and where it was found.
Offer suggestion to debian-based systems when some of unixODBC is found
(the bin part) but the development part is missing.
In 20SqlServer.t attempt to drop any procedures we created if they still
exist at the end of the test. Reported by Michael Higgins.
In 12blob.t separate code to delete test table into sub and call at
being and end, handle failures from prepare there were two ENDs.
In ODBCTEST.pm when no acceptable test column type is found output all
the found types and BAIL_OUT the entire test.
Skip rt_39841.t unless actually using the SQL Server ODBC driver or
native client.
Handle drivers which return 0 for SQL_MAX_COLUMN_NAME_LEN.
Double the buffer size used for column names if built with unicode.
1.19 2009-04-02
Some minor diagnostic output during tests when running against freeTDS
to show we know of issues in freeTDS.
Fixed issue in 20SqlServer.t where the connection string got set with
two consecutive semi-colons. Most drivers don't mind this but freeTDS
ignores everything after that point in the connection string.
Quieten some delete table output during tests.
Handle connect failures in 20SqlServer.t in the multiple active
statement tests.
In 02simple.t cope with ODBC drivers or databases that do not need a
username or password (MS Access).
In 20SqlServer.t fix skip count and an erroneous assignment for
driver_name.
Change some if tests to Test::More->is tests in 02simple.t.
Fix "invalid precision" error during tests with the new ACEODBC.DLL MS
Access driver. Same workaround applied for the old MS Access driver
(ODBCJT32.DLL) some time ago.
Fix out of memory error during tests against the new MS Access driver
(ACEODBC.DLL). The problem appears to be that the new Access driver
reports ridiculously large parameter sizes for "select ?" queries and
there are some of these in the unicode round trip test.
Fixed minor typo in Makefile.PL - diagnostic message mentioned "ODBC
HOME" instead of ODBCHOME.
12blob.t test somehow got lost from MANIFEST - replaced. Also changed
algorithm to get a long char type column as some MS Access drivers only
show SQL_WLONGVARCHAR type in unicode.
Added diagnostic output to 02simple.t to show the state of
odbc_has_unicode.
1.18_4 2009-03-13
A mistake in the MANIFEST lead to the rt_43384.t test being omitted.
Brian Becker reported the tables PERL_DBD_39897 and PERL_DBD_TEST are
left behind after testing. I've fixed the former but not the latter yet.
Yet another variation on the changes for rt 43384. If the parameter is
bound specifically as SQL_VARCHAR, you got invalid precision
error. Thanks to Ãystein Torget for finding this and helping me verify
the fix.
If you attempt to insert large amounts of data into MS Access (which
does not have SQLDescribeParam) you can get an invalid precision error
which can be worked around by setting the bind type to
SQL_LONGVARCHAR. This version does that for you.
08bind2.t had a wrong skip count.
12blob.t had strict commented out and GetTypeInfo was not quoted. Also
introduced a skip if the execute fails as it just leads to more obvious
failures.
In dbdimp.c/rebind_ph there was a specific workaround for SQL Server
which was not done after testing if we are using SQL Server - this was
breaking tests to MS Access.
1.18_2 2009-03-09
Added yet another workaround for the SQL Server Native Client driver
version 2007.100.1600.22 and 2005.90.1399.00 (driver version 09.00.1399)
which leads to HY104, "Invalid precision value" in the rt_39841.t test.
1.18_1 2009-03-06
Fixed bug reported by Toni Salomäki leading to a describe failed error
when calling procedures with no results. Test cases added to
20SqlServer.t.
Fixed bug rt 43384 reported by Ãystein Torget where you cannot insert
more than 127 characters into a Microsoft Access text(255) column when
DBD::ODBC is built in unicode mode.
1.18 2009-01-16
Major release of all the 1.17 development releases below.
1.17_3 2008-12-19
Reinstated the answer in the FAQ for "Why do I get invalid value for
cast specification" which had got lost - thanks to EvanCarroll in
rt41663.
rt 41713. Applied patch from JHF Remmelzwaal to handle ODBC drivers
which do not support SQL_COLUMN_DISPLAY_SIZE and SQL_COLUMN_LENGTH
attributes in the SQLColAttributes calls after SQLTables and
SQLColumns. Specifically, the driver he was using was the "Infor
Integration ODBC driver".
Added notes from JHF Remmelzwaal on resolving some problems he came
across building DBD::ODBC on Windows with Visual Studio 6.0 and SDK Feb
2003.
New odbc_column_display_size attribute for when drivers does not return
a display size.
Loads of tracing changes to make it easier for me to debug problems.
Fixed bug in tracing of dbd_execute when parameter is char but undef
which was leading to an access violation on Windows when tracing
enabled.
Minor changes to diagnostic output in some rt tests.
One of the rt tests was not skipping the correct number of tests if the
driver was not SQL Server.
1.17_2 2008-11-17
Changed ParamTypes attribute to be as specification i.e.,
{
parameter_1 => {TYPE => sql_type}
parameter_2 => {TYPE => sql_type}
...
}
and changed the tests in 07bind.t to reflect this.
A few minor perlcritic changes to ODBC.pm.
Added 99_yaml.t test to check META.yml.
Added patch from Spicy Jack to workaround problems with Strawberry Perl
setting INC on the command line when running Makefile.PL.
1.17_1 2008-10-10
Missing newline from end of META.yml upsets cpan
Add code to Makefile.PL to spot command line containing INC, outline
problem and resolution and not generate Makefile to avoid cpan-testers
failures.
Loads of pod formatting changes including a section in the wrong place
New kwalitee test
Fix rt 39841. Bug in SQL Server ODBC driver which describes parameters
by rearranging your SQL to do a select on the columns matching the
parameters. Sometimes it gets this wrong and ends up describing the
wrong column. This can lead to a varchar(10) being described with a
column-size less than 10 and hence you get data truncation on execute.
Added a test case for rt 39841.
Fix rt 39897. 1.17 added support for varchar(max) in SQL Server but it
broke support for SQL_VARCHAR columns in that they had LongReadLen and
LongTruncOk applied to them. This means that in 1.16 you could retrieve
a SQL_VARCHAR column without worrying about how long it was but in 1.17
if the same column was greater than 80 characters then you would get a
truncated error. The only way the around this was to set LongTruncOk or
LongReadLen.
Added a test case for rt 39897.
1.17 2008-09-22
In the absence of any bug reports since 1.16_4 this is the official 1.17
release. See below for changes since 1.16.
Minor pod changes.
Added support for ParamTypes (see DBI spec) and notes in DBD::ODBC pod.
1.16_4 2008-09-12
Small change to Makefile.PL to work around problem in darwin 8 with
iODBC which leads to "Symbol not found: _SQLGetPrivateProfileString"
errors.
Added new [n]varXXX(max) column type tests to 20SqlServer.t.
Fixed support for SQL_WCHAR and SQL_WVARCHAR support in non-unicode
build. These types had ended up only being included for unicode builds.
More changes to ODBC pod to 1) encourage people to use CPAN::Reporter,
2) rework contributing section, 3) mention DBIx::Log4perl 4) add a BUGS
section 5) add a "ODBC Support in ODBC Drivers" section etc.
Changed default fallback parameter bind type to SQL_WVARCHAR for unicode
builds. This affects ODBC drivers which don't have
SQLDescribeParam. Problem reported by Vasili Galka with MS Access when
reading unicode data from one table and inserting it into another table.
The read data was unicode but it was inserted as SQL_CHARs because
SQLDescribeParam does not exist in MS Access so we fallback to either a
default bind type (which was SQL_VARCHAR) or whatever was specified in
the bind_param call.
Fixed bug in 20SqlServer.t when DBI_DSN is defined including "DSN=".
1.16_3 2008-09-03
Changed Makefile.PL to add "-framework CoreFoundation" to linker line on
OSX/darwin.
Disallow building with iODBC if it is a unicode build.
More tracing for odbcconnect flag.
Fix bug in out connection string handling that attempted to use an out
connection string when SQLDriverConnect[W] fails.
Fixed yet more test count problems due to Test::NoWarnings not being
installed.
Skip private_attribute_info tests if DBI < 1.54
About a 30% rewrite of bound parameter code which started with an
attempt to support the new VARBINARY(MAX) and VARCHAR(MAX) columns in
SQL Server when the parameter length is > 400K in size (see elsewhere in
this Changelog). This is a seriously big change to DBD::ODBC to attempt
to be a bit more clever in its handling of drivers which either do not
support SQLDescribeParam or do support SQLDescribeParam but cannot
describe all parameters e.g., MS SQL Server ODBC driver cannot describe
"select ?, LEN(?)". If you specify the bound parameter type in your
calls to bind_param and run them to an ODBC driver which supports
SQLDescribeParam you may want to check carefully and probably remove the
parameter type from the bind_param method call.
Added rt_38977.t test to test suite to test varchar(max) and
varbinary(max) columns in SQL Server.
Moved most of README.unicode to ODBC.pm pod.
Added workaround for problem with the Microsoft SQL Server driver when
attempting to insert more than 400K into a varbinary(max) or
varchar(max) column. Thanks to Julian Lishev for finding the problem and
identifying 2 possible solutions.
1.16_2 2008-09-02
Removed szDummyBuffer field from imp_fbh_st and code in dbd_describe
which clears it. It was never used so this was a waste of time.
Changed the remaining calls to SQLAllocEnv, SQLAllocConnect and
SQLAllocStmt and their respective free calls to the ODBC 3.0
SQLAllocHandle and SQLFreeHandle equivalents.
Rewrote ColAttributes code to understand string and numeric attributes
rather than trying to guess by what the driver returns. If you see any
change in behaviour in ColAttributes calls you'll have to let me know as
there were a number of undocumented workarounds for drivers.
Unicode build of DBD::ODBC now supports:
column names
The retrieval of unicode column names
SQL strings
Unicode in prepare strings (but not unicode parameter names) e.g.,
select unicode_column from unicode_table
is fine but
select * from table where column = :unicode_param_name
is not so stick to ascii parameter names if you use named
parameters.
Unicode SQL strings passed to the do method are supported.
SQL strings passed to DBD::ODBC when the odbc_exec_direct attribute
is set will not be passed as unicode strings - this is a
limitation of the odbc_exec_direct attribute.
connection strings
True unicode connection string support will require a new version of
DBI (post 1.607).
Note that even though unicode connection strings are not
supported currently DBD::ODBC has had to be changed to call
SQLDriverConnectW/SQLConnectW to indicate to the driver manager it's
intention to use some of the ODBC wide APIs. This only affects
DBD::ODBC when built for unicode.
odbcunicode trace flag
There is a new odbcunicode trace flag to enable unicode-specific
tracing.
Skipped 40Unicode.t test if the ODBC driver is Oracle's ODBC as I cannot
make it work.
Changes internally to use sv_utf8_decode (where defined) instead of
setting utf8 flag.
Fix problems in the test when Test::NoWarnings is not installed.
Removed some unused variables that were leading to compiler warnings.
Changed a lot of tracing to use new odbcconnection flag
Changed to use dbd_db_login6_sv if DBI supports it.
Commented out a diag in 20SqlServer.t that was leading to confusion.
Added diag to 20SqlServer.t in mars test to explain why it may fail.
Various pod changes for clarification and to note odbc_err_handler is
deprecated.
Removed odbcdev trace flag - it was not really used.
New odbc_out_connect_string attribute for connections which returns the
ODBC driver out connection string.
1.16_1 2008-08-28
Fixed bug in odbc_cancel which was checking the ACTIVE flag was on
before calling SQLCancel. Non-select statements can also be cancelled so
this was wrong. Thanks to Dean Arnold for spotting.
Minor changes to test 01base to attempt to catch install_driver failing,
report it as a fail and skip other tests.
Fixed bug reported by James K. Lowden with asynchronous mode and
SQLParamData where the code was not expecting SQL_STILL_EXECUTING and
did not handle it
Added odbc_putdata_start attribute to determine when to start using
SQLPutData on lobs.
Fixed bug in lob inserts where decimal_digits was being set to the size
of the bound lob unnecessarily.
Minor change to connect/login code to delete driver-specific attributes
passed to connect so they do not have to be processed again when DBI
calls STORE with them.
New 12blob.t test.
A lot of code tidy up but not expecting any real benefit or detriment
when using DBD::ODBC.
Fixed retrieving [n]varchar(max) columns which were only returning 1
byte - thanks to Fumiaki Yoshimatsu and perl monks for finding it. See
http://markmail.org/message/fiym5r7q22oqlzsf#query:Fumiaki Yoshimatsu
odbc+page:1+mid:fiym5r7q22oqlzsf+state:results
Fixed bug in 20SqlServer test for multiple results that was passing but
for the wrong reason (namely, that the odbc_err_handler was being called
when it should not have been).
Fixed bug in odbc_err_handler that prevented it from being reset so you
don't have an error handler. Looks like the problem was in
dbd_db_STORE_attrib where "if(valuesv == &PL_sv_undef)" was used to
detect undef and I think it should be "if (!SvOK(valuesv))".
Improvements to odbc_err_handler documentation.
Added 10handler.t test cases.
More tests in 02simple.t to check NUM_OF_FIELDS and NAMES_uc.
Bit of a tidy up:
Removed some unused variable declarations from dbdimp.c.
Lots of changes to DBD::ODBC tracing, particularly in dbd_describe, and
dbd_error2 and login6.
Removed a lot of tracing code in comments or #if 0 as it never gets
built.
Changed dual tests on SQL_SUCCESS and SQL_SUCCESS_WITH_INFO to use
SQL_SUCCEEDED.
1.14 2007-07-17
Fix bug reported where ping crashes after disconnect thanks to Steffen
Goeldner.
Fix bug in dbd_bind_ph which leads to the error Can't change param 1
maxlen (51->50) after first bind in the 20SqlServer test. This is caused
by svGROW in Perl 5.8.8 being changed to possibly grow by more than you
asked (e.g. up to the next longword boundary).
Fix problem with binding undef as an output parameter. Reported by
Stephen More with IBM's ODBC driver for iSeries.
Removed comment delimiters in comments in dbdimp.h leading to warnings.
Removed some unused variable declarations leading to warnings.
Removed PerlIO_flush calls as it is believed they are not required.
Add logging for whether SQLDescribeParam is supported.
Fixed use of unitialised variable in dbd_bind_ph where an undef is bound
and tracing is enabled.
Fixed issue with TRACESTATUS change in 20SqlServer.t tests 28, 31, 32
and 33 leading to those tests failing when testing with SQL Server 2005
or Express.
Many compiler warnings fixed - especially for incompatible types.
Add provisional Unicode support - thanks to Alexander Foken. This change
is very experimental (especially on UNIX). Please see ODBC.pm
documentation. Also see README.unicode and README.af. New database
attribute odbc_has_unicode to test if DBD::ODBC was built with UNICODE
support. New tests for Unicode. New requirement for Perl 5.8.1 if
Unicode support required. New -[no]u argument to Makefile.PL. New
warning in Makefile.PL if Unicode support built for UNIX.
Fix use of unitialised var in Makefile.PL.
Fix use of scalar with no effect on Makefile.PL
Added warning to Makefile.PL about building/running with LANG using
UTF8.
Added warning to Makefile.PL about using thread-safe ODBC drivers.
Updated MANIFEST to include more test code from mytest and remove
MANIFEST.SKIP etc.
Removed calls to get ODBC errors when SQLMoreResults returns
SQL_NO_DATA. These are a waste of time since SQL_NO_DATA is expected
and there is no error diagnostic to retrieve.
Changes to test 17 of 02simple.t which got "not ok 17 - Col count
matches correct col count" errors with some Postgres ODBC
drivers. Caused by test expecting column names to come back
uppercase. Fixes by uppercasing returned column names.
Changes to tests in 03batt.t which correctly expects an ODBC 3 driver to
return the column names in SQLTables result-set as per ODBC 3.0
spec. Postgres which reports itself as an ODBC 3.0 driver seems to
return the ODBC 2 defined column names. Changed tests to catch ODBC 2.0
names are pass test put issue warning.
For postgres skip test (with warning) checking $sth->{NAME} returns
empty listafter execute on update
Updated FAQ, added a few more questions etc.
DBD::ODBC requires at least 5.6.0 of Perl.
Many updates to pod documentation.
Removed some dead HTTP links in the pod I could not find equivalents for
- let me know if you have working replacements for ones removed
Add some HTTP links to useful tutorials on DBD::ODBC
1.13 2004-11-08
Fix inconsistency/bug with odbc_exec_direct vs. odbc_execdirect
settings. Now made consistent with odbc_exec_direct. For now, will
still look for odbc_execdirect in prepare, but not as DBH attribute as a
backup (which is what it was doing), but that support will be dropped at
some time in the future. Please use odbc_exec_direct from now on...
Fix handling of print statements for SQL Server thanks to Martin Evans!
Thanks for all your work on this!
Due to bug in SQL Server, you must use odbc_exec_direct. See
t/20SqlServer.t for example. You will need to call
$sth->{odbc_more_results} to clear out any trailing messages.
( run in 1.252 second using v1.01-cache-2.11-cpan-39bf76dae61 )