AK
2012-04-04 19:13:18 UTC
Hello,
Before posting this question, I did the search the forums and didn't get a clear answer for this.
I am using PD v15.3 and I have created a Column Extended Attribute (AuditColumn) in the DBMS Resource File. This attribute is of type of boolean. I checked the Template checkbox while defining the extended attribute. I am able to view this attribute in the Table Columns view and I am able to check the columns which are considered audit columns.
I am developing a procedure template using GTL where I am creating a SQL statements for which I would like to skip all the columns which are set as AuditColumns. In the foreach_item loop what is the GTL syntax to access the AuditColumn value?
I tried the following and none of them worked:
1) .foreach_item(Table.Columns, "\n",",\n", %AuditColumn% = False)
%COLUMN%
.next(",\n")
2) Added generation path (Test)
.foreach_item(Table.Columns, "\n",",\n", %Test.AuditColumn% = False)
%COLUMN%
.next(",\n")
3) Used VB script
.foreach_item(Table.Columns, "\n",",\n", .vbscript ScriptResult = ActiveSelection.Item(0).GetExtendedAttribute("Test.AuditColumn").endvbscript = False)
%COLUMN%
.next(",\n")
Any help is appreciated.
Thanks.
Before posting this question, I did the search the forums and didn't get a clear answer for this.
I am using PD v15.3 and I have created a Column Extended Attribute (AuditColumn) in the DBMS Resource File. This attribute is of type of boolean. I checked the Template checkbox while defining the extended attribute. I am able to view this attribute in the Table Columns view and I am able to check the columns which are considered audit columns.
I am developing a procedure template using GTL where I am creating a SQL statements for which I would like to skip all the columns which are set as AuditColumns. In the foreach_item loop what is the GTL syntax to access the AuditColumn value?
I tried the following and none of them worked:
1) .foreach_item(Table.Columns, "\n",",\n", %AuditColumn% = False)
%COLUMN%
.next(",\n")
2) Added generation path (Test)
.foreach_item(Table.Columns, "\n",",\n", %Test.AuditColumn% = False)
%COLUMN%
.next(",\n")
3) Used VB script
.foreach_item(Table.Columns, "\n",",\n", .vbscript ScriptResult = ActiveSelection.Item(0).GetExtendedAttribute("Test.AuditColumn").endvbscript = False)
%COLUMN%
.next(",\n")
Any help is appreciated.
Thanks.