Click to See Complete Forum and Search --> : Oracle database
freek
July 26th, 1999, 09:37 AM
In Access I created a database with linked tables to Oracle through ODBC.
When 2 users try to add a record, it's possible that a double key is created and Oracle gives an error message, but I can' t trap the error in VB.
Does someone know how to trap this error?
Lothar Haensler
July 26th, 1999, 09:42 AM
unless your Oracle ODBC driver sucks, you should be able to inspect the DAO errors collection for any errors from the underlying database system.
freek
July 26th, 1999, 10:21 AM
Where should I put my code then?
I tried at afterupdate, beforupdate, lostfocus, beforinsert, afterinsert, ...
(I should work with on error goto... , right ?)
muthiahr
November 19th, 1999, 06:45 PM
You are right. You should be able to use Err.Number. Find out the number returned by not handling the error, then use that number to verify if Err.Number returns the same. If it does, Re-commit to the database.
Rajan
codeguru.com
Copyright Internet.com Inc., All Rights Reserved.