A2K to A2003 Error 94

supmktg

Registered User.
Local time
Today, 17:06
Joined
Mar 25, 2002
Messages
360
I have an A2K FE with an A2003 user. The database is SQL Server via ODBC connection. The A2003 user is having several issues with 'Error 94 invalid use of null' when appending records. In A2K this error never occurs, even while appending EXACTLY the same data. Also, the Error 94 seems to be intermittent.

The vba code uses rst.addnew method as well as insert values method within the same procedure, writing different data to different tables. One procedure is writing to a temp table within the mdb and it also gets Error 94 intermittently.

Also, the A2003 user gets the append warning while it never pops up in A2K.

I am about to alter the code to check for null of each field, and to set warnings false before the append. Before I do, I would like to know if there is a setting in A2003 or some known issue that is causing these 2 issues.

I appreciate any feedback!

Thanks,
Sup
 
you could put Nz() around all the input fields. Which ensures that no Null value will pass.

You could use the command statement to fill your tables. It gives you more insight on the type of values which are expected in your table. But it is more work.
 
Also, the A2003 user gets the append warning while it never pops up in A2K.


Thanks,
Sup

If you look in the Options for A2003 under the Edit/Find tab there are settings for Confirm Record Changes, Document deletions and Action queries. Just set as required.
 
I have setwarnings false in code and added If not isnull() code before each field that could be null. Both fixes seem to be working.

Thanks for the replies,
Sup
 
Remember you can also use the NZ function if some fields could be Null
 

Users who are viewing this thread

Back
Top Bottom