SQL窗口中的insert语句中的“Grid”表

时间:2022-01-10 22:24:04

How to identify a "Grid column" in an insert statement as they are dynamically created I'm not able to refere these. When I try to add columns in the grid they appare with the correct title, but still not able to refere in an INSERT. The "Grid" is loaded from an .xls.

如何在insert语句中标识“Grid列”,因为它们是动态创建的,我无法引用它们。当我尝试在网格中添加列时,它们使用正确的标题进行修饰,但仍然无法在INSERT中引用。 “网格”从.xls加载。

Thanks

1 个解决方案

#1


You can refer with hashtag with column index: tblData#1, tblData#2, tblData#3, tblData#4, ...etc.

您可以使用列索引引用hashtag:tblData#1,tblData#2,tblData#3,tblData#4,...等。

Where "tblData" is Child Table Name and #1, #2,... are column indexes.

其中“tblData”是子表名称,#1,#2,...是列索引。

Example:

Call SqlPrepareAndExecute( hSql, 'insert into TABLE(id, name) values(:tblData#1, :tblData#2)' )

#1


You can refer with hashtag with column index: tblData#1, tblData#2, tblData#3, tblData#4, ...etc.

您可以使用列索引引用hashtag:tblData#1,tblData#2,tblData#3,tblData#4,...等。

Where "tblData" is Child Table Name and #1, #2,... are column indexes.

其中“tblData”是子表名称,#1,#2,...是列索引。

Example:

Call SqlPrepareAndExecute( hSql, 'insert into TABLE(id, name) values(:tblData#1, :tblData#2)' )