Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
I have fields Form Id, service1, service2, service3, fulfillment1, fulfillment2, fulfillment3, quality1, quality2, quality3.
I want to combine all similar columns and rename them as service, fulfillment and quality.
How can I achieve this? Thank you so much!
Try below code
Load
Form ID,
service1 as Service,
fulfillment1 as Fulfillment,
quality1 as Quality
from table;
Concatenate
Load
Form ID,
service2 as Service,
fulfillment2 as Fulfillment,
quality2 as Quality
from table;
Concatenate
Load
Form ID,
service3 as Service,
fulfillment3 as Fulfillment,
quality3 as Quality
from table;
Regards,
Prashant Sangle
If you have a longer list of column groups then it could be effective to perform a loop. Something like this:
FOR i =1 TO 3
LOAD
[Form ID],
[service$(i)] as Service,
[fulfillment$(i)] as Fulfillment,
[quality$(i)] as Quality
FROM Sourec;
NEXT i
Try below code
Load
Form ID,
service1 as Service,
fulfillment1 as Fulfillment,
quality1 as Quality
from table;
Concatenate
Load
Form ID,
service2 as Service,
fulfillment2 as Fulfillment,
quality2 as Quality
from table;
Concatenate
Load
Form ID,
service3 as Service,
fulfillment3 as Fulfillment,
quality3 as Quality
from table;
Regards,
Prashant Sangle
If you have a longer list of column groups then it could be effective to perform a loop. Something like this:
FOR i =1 TO 3
LOAD
[Form ID],
[service$(i)] as Service,
[fulfillment$(i)] as Fulfillment,
[quality$(i)] as Quality
FROM Sourec;
NEXT i