PDA

Click to See Complete Forum and Search --> : Data Environment & Jet Provider


d_humphrey
Mar 10th, 2000, 05:20 PM
Can anyone please help ?

I have a connection to an Access 7.0 database from
the Data Environment using Provider=Microsoft.Jet.OLEDB.3.51

I am using a parameterised command (detailed below) to insert values into a table.

INSERT INTO sickdays (UserID, ADate, Month, Reason)
VALUES (?, ?, ?, ?)


This works fine with the OLE 3.51 provider, however if I use the OLE 4.0 provider - the Insert statement doesn't work.

Can anyone please tell me why, or how to get the same effect with 4.0

Thanks, Daniel.

Bigley
Mar 11th, 2000, 05:40 AM
I'm not sure Daniel but I think 4.0 is designed with Access 2000 in mind

Clunietp
Mar 11th, 2000, 11:16 PM
Try putting brackets around MONTH. Change this

INSERT INTO sickdays (UserID, ADate, Month, Reason)

TO This

INSERT INTO sickdays (UserID, ADate, [Month], Reason)


If the jet 4 engine now recognizes the word 'month' as a special keyword, it will give you an error with your insert statement....

d_humphrey
Mar 12th, 2000, 03:04 AM
You are an absolute diamond.

Thanks very much - I really appreciate your help !

Daniel.