Click to See Complete Forum and Search --> : how do i insert data into table?


pelegk1
09-17-2003, 11:25 AM
i have access DB
i want to insert values into col's that are called :x1,y1
how do i do it?
thanks in adfvance
epelg

Ribeyed
09-17-2003, 05:47 PM
hi,



DBConn.execute "INSERT INTO tblTable1 (x1, y1) VALUES ("&xvalue1&", "&value2&")"



this is correct syntax for inserting numeric data into numeric fields, if the fields are char then this is correct syntax, please not the difference it will help you in future



DBConn.execute "INSERT INTO tblTable1 (x1, y1) VALUES ('"&xvalue1&"', '"&value2&"')"