P
Peter Jamieson
I am using Perl 5.8 with the DBI module to routinely send parsed data to an
Access db.
Sometimes the incoming files may have errors so that numeric data appears as
text.
This causes my script to throw a warning:
DBD::ODBC::st execute failed: [Microsoft][ODBC Microsoft Access Driver] Data
type
mismatch in criteria expression. (SQL-22018) at C:\myscript.pl line 422.
When this happens the script contiues to run and on looking at the db the
particular
record is absent.
What I would like to happen is for my script to die when the above warning
occurs so that
I can examine the input file to see what was causing the data type mismatch
and rectify
the error.
I have checked some DBI tutorials but cannot locate any way of doing this.
Any suggestions or help appreciated!
Access db.
Sometimes the incoming files may have errors so that numeric data appears as
text.
This causes my script to throw a warning:
DBD::ODBC::st execute failed: [Microsoft][ODBC Microsoft Access Driver] Data
type
mismatch in criteria expression. (SQL-22018) at C:\myscript.pl line 422.
When this happens the script contiues to run and on looking at the db the
particular
record is absent.
What I would like to happen is for my script to die when the above warning
occurs so that
I can examine the input file to see what was causing the data type mismatch
and rectify
the error.
I have checked some DBI tutorials but cannot locate any way of doing this.
Any suggestions or help appreciated!