I need an advice on how to deal with SUCCESS_WITH_INFO
from a DBD writers point of view.

If ADO places an error into it's error collection,
this error may be one of 4 kinds (oledberr.h):

  00 - Success
  01 - Informational
  10 - Warning
  11 - Error

A good example for the first case is given on dbi-users:

  <http://www.xray.mpe.mpg.de/mailing-lists/dbi/2003-12/msg00241.html>

An ODBC function would return SQL_SUCCESS_WITH_INFO in
such a case.
Currently, DBD::ADO doesn't distinguish between these four
kinds of errors, i.e. something like

  return $h->set_err( ... ) if $lastError;

is always executed and the DBI user has to catch that error.
Is this the intended DBI behavior?
Alternatively, a DBD::ADO could ignore all but the last kind
of error. But I'm not enthusiastic in throwing away such kind
of information.
There may be less drastic solutions, e.g. putting that
information into special handle attributes.

Any suggestions?


Steffen

P.S.: I'm aware that this topic is on DBI's ToDo list:

  The DBI needs some standard way to handle the
  'success with info' concept

Reply via email to