Hello again,
> > >
******************************************************************************************
> > > wats=# begin;
> > > BEGIN
> > > wats=# select vendor_remove(1);
> > > ERROR: <unnamed> referential integrity violation - key in vendor
still
> > > referenced from vendorforwellagreement
> > > wats=# commit;
> > > COMMIT
> > >
******************************************************************************************
> > >
> > > psql reports the error when I issue the SELECT statement, not when
I
> > > issue the commit. Shouldn't I be able to capture an exception when
I do
> > > an ExecuteSQL() from VC++, instead of a CommitTrans() ?
> >
> > Could you show me a reproducible example ?
Ok, I've managed to reproduce the bug. I'm attaching a .zip file that
contains a VC++ project that exhibits the bug along with a few sql files
needed to load the DB schema and some sample data. In order to load the
database, the file "SQL_Files\add_all.sql" needs to be loaded through
the psql client:
test=# \i add_all.sql
Hope this helps,
-Kristis