Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I wonder if it is possible to use a variable as a table name.
Explanation, i have a lot of reportings and i would love to ad a variable to a tabel name.
vDate = 20130901
the table name from the file is [IZ] and i would love to rename the table name like this $(vDate) IZ
Anyone?
THX in advance.
Hi,
Yes you can use variable as table name. See the below script:
SalesIV:
LOAD * INLINE [
Dept, Name, Sales
Inventory, A, 10
Inventory, B, 15
Inventory, D, 2
Sales, A, 14
Sales, C, 30
];
set vtabname = 'Sales';
Test:
NoConcatenate
load
Dept
Resident
$(vtabname)IV;
Hope this help,
Anosh
Yes ,should not be a big problem. Have you tried something like
[$(vDate) IZ]:
Load ... From ...;
Hi,
Yes you can use variable as table name. See the below script:
SalesIV:
LOAD * INLINE [
Dept, Name, Sales
Inventory, A, 10
Inventory, B, 15
Inventory, D, 2
Sales, A, 14
Sales, C, 30
];
set vtabname = 'Sales';
Test:
NoConcatenate
load
Dept
Resident
$(vtabname)IV;
Hope this help,
Anosh