Click here to Skip to main content
15,881,938 members
Please Sign up or sign in to vote.
3.00/5 (2 votes)
See more:
Im trying to Insert a record into a table with a column named "VALUE", but keep getting the error

"Invalid use of keyword. Token: VALUE) VALUES ("

Im new to Delphi + DB2, and have tried encapsulating the query in "" and [] to bypass the reserved word but still no luck.

Thanks in advance!
Posted

Try to use double quotes, as is described here: Encapsulation of SQL Identifiers in Double Quotes[^]. More about reserved words: Reserved schema names and reserved words[^]
 
Share this answer
 
Comments
nebiam 9-Jul-13 23:35pm    
Tried your solution but still no luck. I ended up changing the column name to a non-reserved word and it worked fine. Not sure why the double quotation's wouldn't work in DB2.. Thanks anyway!
Maciej Los 10-Jul-13 7:14am    
You're welcome.
I ended up renaming the column to a non-reserved word and it fixed the issue. Not sure why the double quotation's wouldn't work in DB2. I know this isn't an exact solution, but its a work around if anyone else is experiencing the same problem.
 
Share this answer
 
Comments
Maciej Los 10-Jul-13 7:15am    
Can you mark this answer as a solution (green button)? It is necessary for removing your question from unanswered list.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900