- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
remove duplicate 1 value only in load script
My loadscript looks like this and I would like to remove duplicates for Trading Co only, adding distinct next to load doesn’t work. Don’t know how to remove duplicates for the specific value Trading Co only, how to integrate this in the load script. See also attachment
- « Previous Replies
-
- 1
- 2
- Next Replies »
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Can you please post some examples of how removing duplicates for only one field would look like?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi @MarcoWedel see attachment
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
@KirstenKa you can use firstsortedvalue function based on date if you have date field
https://help.qlik.com/en-US/sense/May2023/Subsystems/Hub/Content/Sense_Hub/ChartFunctions/BasicAggre...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello, @KirstenKa
You Can try By doing Group By,
Eg.
Load *,
Resident [Table Name]
Group by "Trading Co", "Item Id";
If This Helpful for You Please mark Answer as solution!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Kristen,
if you use
Load distinct "Trading Co" from MySource;
this will result in a table containing only unique "Trading Co" values.
I don't know how you want to analyse the data afterwards and thus don't understand why duplicate values of the "Trading Co" field do matter. Could you please provide some further details?
Kind regards,
Thilo
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks @tealowk
It doesn't work in my script, also tried "mysource" between brackets and "Distinct" right before Trading Co. See also attachment
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Ok thanks I need to look into it and try
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
maybe like this?
table1:
LOAD [Trading code],
Item
FROM [https://community.qlik.com/cyjdu72974/attachments/cyjdu72974/new-to-qlik-sense/233798/1/Remove%20duplicates%20based%20on%201%20value.xlsx] (ooxml, embedded labels, table is Sheet1)
Where not Exists([Trading code]);
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You need to replace MySource by your actual source and remove all the other fields that you load in the table.
- « Previous Replies
-
- 1
- 2
- Next Replies »