Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
i have a table
PNR Ticket No Amount
1 1,2 100
2 3 100
but when i split ticket with subfield
PNR Ticket No Amount
1 1 100
1 2 100
2 3 100
now it gives me amount 200 for PNR 1 .. how to come out from this ![]()
Try this:
a:
load * Inline [PNR, Ticket No, Amount
"1", "1,2","100"
"2", "3","100"];
NoConcatenate
load PNR
, subfield([Ticket No],',') as [Ticket No]
, Amount / count as Amount;
load * , substringcount([Ticket No],',') + 1 as count
Resident a;
drop Table a;
Hi Rajni ,
PFA Application.
Hope it helps you.
Regards
Kamal