Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I want to concat the tables. so I use this script but it doesn't work
I am sharing the errow below. how can I work on this?
thanks
FOR i = 0 to NoOfTables()
TableList:
LOAD TableName($(i)) as Tablename AUTOGENERATE 1
WHERE WildMatch(TableName($(i)), 'ZCS_BOM_EXPL_MAT_V2*');
NEXT i
FOR i = 1 to FieldValueCount('Tablename')
LET vTable = FieldValue('Tablename', $(i));
Concatenate (ZCS_BOM_EXPL_MAT_V2)
LOAD * RESIDENT [$(vTable)];
DROP TABLE [$(vTable)];
NEXT i;
DROP TABLE TableList;
It looks like your TableList does not autoconcatenate correctly. I notice TableList-6, TableList-7, TableList-8, etc.
What does your datamodel look like after the first loop and have you controlled the content of the Tablename field.
I am also concerned about your Where condition,
WildMatch(TableName($(i)), 'ZCS_BOM_EXPL_MAT_V2*');, as it will include the table you are concatenating everything into, the ZCS_BOM_EXPL_MAT_V2 table.
Hi Vegar,
tablelist tables include other table names. for excamle ZCS_BOM_EXPL_MAT_V2-3, ZCS_BOM_EXPL_MAT_V2-4 etc.
I want to concat some tables that are ZCS_BOM_EXPL_MAT_V2-3, ZCS_BOM_EXPL_MAT_V2-4, ZCS_BOM_EXPL_MAT_V2-5 etc. so I write ZCS_BOM_EXPL_MAT_V2* for find to all of them
I understand but by using ZCS_BOM_EXPL_MAT_V2* you will also include the ZCS_BOM_EXPL_MAT_V2 table in your TableList. And if so then you would probably drop that table somewhere in the final loop .