jasonjasonjason
Technical User
Hi,
I'm having a problem when trying to executre an SQL statement. It's a very strange problem I've got to say...
Let me explain myself -
I have an Access DB. I've managed to execute a SELECT sql statement and show the records on a console window. Now I want to insert information to the database.
The following sql statement will be executed just fine:
INSERT INTO Users (UserId) VALUES(1)
The problem starts when I want to insert string values, the next statement will not go through and will end up in an exception - "Syntax error in INSERT INTO statement":
INSERT INTO Users (UserId, UserName) VALUES (1, 'Test')
There is no problem with the syntax because on an SQL application it ran without any problems...
Thanks
I'm having a problem when trying to executre an SQL statement. It's a very strange problem I've got to say...
Let me explain myself -
I have an Access DB. I've managed to execute a SELECT sql statement and show the records on a console window. Now I want to insert information to the database.
The following sql statement will be executed just fine:
INSERT INTO Users (UserId) VALUES(1)
The problem starts when I want to insert string values, the next statement will not go through and will end up in an exception - "Syntax error in INSERT INTO statement":
INSERT INTO Users (UserId, UserName) VALUES (1, 'Test')
There is no problem with the syntax because on an SQL application it ran without any problems...
Thanks