Page 1 of 1

TMSQuery editor, SQL Generator - error generating SQL statem

Posted: Mon 12 Mar 2012 09:46
by Rnest
Autogenerated update, insert, strings are invalid in newest SDAC edition (6.1.5)
e.g. for TMSQuery.SQL.Text:

Code: Select all

SELECT [EMPNO]
      ,[ENAME]
      ,[JOB]
      ,[MGR]
      ,[HIREDATE]
      ,[SAL]
      ,[COMM]
      ,[DEPTNO]
  FROM [SDACDemos].[dbo].[emp]
as generated result for insert text you get

Code: Select all

INSERT INTO [dbo].[emp]
  ([EMPNO], [], [], [], [], [], [])
VALUES
  (:[EMPNO], :[], :[], :[], :[], :[], :[])
SET :[EMPNO] = SCOPE_IDENTITY()
and for update text:

Code: Select all

UPDATE [dbo].[emp]
SET
  [EMPNO] = :[EMPNO], [] = :[], [] = :[], [] = :[], [] = :[], [] = :[], [] = :[]
WHERE
  [ENAME] = :[Old_ENAME]
Tested on RAD Studio 2010, SQL Server 2008

Best regards
Ernest

Posted: Tue 13 Mar 2012 08:34
by AndreyZ
Hello,

Thank you for the information. We will fix this problem in the next SDAC build.

Posted: Sun 18 Mar 2012 15:03
by Badiboy
I have the same problem and it makes new form design hard.

It's also generate identity querying code "SET :PROJECT_PERSON_ID = SCOPE_IDENTITY()" while "QueryIdentity" option is FALSE.

When do you plan to release new version?

Posted: Mon 19 Mar 2012 12:04
by AndreyZ
We will release the new SDAC build approximately in two weeks.

Posted: Mon 19 Mar 2012 12:12
by Badiboy
Thanks for the reply, I'll be waiting for. :roll: