This thread looks to be a little on the old side and therefore may no longer be relevant. Please see if there is a newer thread on the subject and ensure you're using the most recent build of any software if your question regards a particular product.
This thread has been locked and is no longer accepting new posts, if you have a question regarding this topic please email us at support@mindscape.co.nz
|
I have a tabled named User in my database (it's a db already in production for years and I can't change the name of the table). When I run any Linq query on it, the following is returned: "Incorrect syntax near the keyword 'User'." Looking at the SQL code that is being generated shows that there are no square brackets around the table name which is causing the problem. The generated SQL is:
SELECT where it should be like this:
SELECT |
|
|
Hi, You need to set QuoteIdentifiers to True on your LightSpeedContext. Information on how to do this both in code or .config and why it is not enabled by default can be found in this thread: http://www.mindscape.co.nz/forums/Thread.aspx?PostID=9043 I hope that helps, John-Daniel Trask |
|
|
Found the answer, need to set QuoteIdentifiers = true in the context. |
|