Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi everyone,
Need some help here.
Imagine that i load 2 tables and want to loop values from the first one in the second one, is that possible?
table1:
load a // String
from ...
table2:
load b // Specific Date
from...
Now i want for each value of a to get all of Data values in b
I thought to do something like to loops but dont know if is possible.
for i = 1 noofrows(table1)
for ii= 1 noofrows(table2)
Not lucky..
Can someone help me?
Regards,
EM
Hi EM,
I believe you need only to use the exists on the where clause.
Something like:
table1:
load a // String
date(a,'FORMAT') as key
from ...
table2:
load b // Specific Date
b as key
from...
where exists(key);
You need to pay attention to the date format, the key field should be in equal format.
Regards,
Carlos
Thanks.
In the case that i have,
Load Id
Name
from..
Imagine that i have one ID with 2 names and i want to load the first Name of each ID any suggestion?
Thanks,
EM