Hello
I try execute this statement
12:22:52 CREATE TABLE AddrLabels ("Name" VARCHAR(35) NULL, "Addr1" VARCHAR(35) NULL, "Addr2" VARCHAR(35) NULL, "City" VARCHAR(35) NULL, "State" VARCHAR(2) NULL, "Zip" VARCHAR(10) NULL, "User" VARCHAR(12) NULL, "DateAdded" DATETIME NULL)
from this code
try
SQLServerConnection.ExecSQL(SQL,[]);
except on E: Exception do
ErrorMsg(E.Message);
end;
and have this error
12:22:53 Incorrect syntax near the keyword 'User'.
SQL profiler show me next statement
CREATE TABLE AddrLabels ([Name] VARCHAR(35) NULL, [Addr1] VARCHAR(35) NULL, [Addr2] VARCHAR(35) NULL, [City] VARCHAR(35) NULL, [State] VARCHAR(2) NULL, [Zip] VARCHAR(10) NULL, [User] VARCHAR(12) NULL, [DateAdded] DATETIME NULL)
can I tune connection, execute statement without [] brackets ?
Win7 64 UniDac 4.1.4 Rad Studio XE2
Thanks
UniConnection SQL Server translate SQL statment
-
AndreyZ
Re: UniConnection SQL Server translate SQL statment
Hello,
I have executed the following code:, and there were no problems. Please try using the latest UniDAC version 4.5.9 and check if the problem persists. If it does, please specify the exact version of SQL Server you are using. You can learn it from the Info sheet of TUniConnection Editor.
I have executed the following code:
Code: Select all
UniConnection1.ExecSQL('CREATE TABLE AddrLabels ("Name" VARCHAR(35) NULL, "Addr1" VARCHAR(35) NULL, "Addr2" VARCHAR(35) NULL, "City" VARCHAR(35) NULL, "State" VARCHAR(2) NULL, "Zip" VARCHAR(10) NULL, "User" VARCHAR(12) NULL, "DateAdded" DATETIME NULL)', []);