Discussion Board for collaboration on QlikView Scripting.
Here the above given table has duplicate customer ID(200).
While loadind data from the table I would like to have the result like below by removing the duplicates completely.
LOAD [Profile ID],
(html, codepage is 1252, embedded labels, table is @1);
Left Join (s2)
load CustId, count(CustId) as Cnt
Resident s2 group by CustId;
Right Keep (s2)
DROP Field Cnt;
You can also try this:
LOAD * Inline [
Profile ID, Status, CustId
780, INPROG, 100
88, INPROG, 200
789, INPROG, 200
800, INPROG, 300
Right Join (Table)
Where Count = 1;
Count(Status) as Count
Group By CustId;
I am also facing same problem.
u get the correct answer can u please mark as a answer otherwise can u have post the answer.
I didn't get u r answer can u pls explain briefly...
thanks& regards ,
in above example I need this output.
profile id Status Cust id
780 inprog 100
88 inprog 200
800 inprog 300
what are the change I do in script.
The below should give you want you want:
Where Count =1;
If(CustId<>Previous(CustId),1,0) as Count
Drop Table Table;
This is the other option using the Right join:
FirstValue([Profile ID]) as [Profile ID]
Load * Inline [
where CountID = 1;
Load CustId,count(CustId) as CountID
group by CustId;
Thnka you for the script.....
But this script works some records only........by using this script some records its deleting fst records and some time its removing scond records......