Hi All,
I have datatable which has close to 53 columns , in that I need to remove duplicates from one particular column based on two other columns logic. I am attaching below the input file few columns which are to be considered
Sequence No
Layer Number
Company Name
3
2
Syndicate
3
3
Hannover
3
3
Syndicate
3
4
Hannover
3
4
Swiss
4
2
Syndicate
4
3
Hannover
4
3
Syndicate
4
4
Hannover
4
4
Swiss
in this data I have to remove the duplicates if any at each layer. for eg at layer two we have two occurance of Syndicate so we should pick only one and that too with the highest sequence number. Requesting for suggestions as I m badly stuck with this
Please try this…So What I did is I did a orderby on the two columns you need then grouped on 3rd column and retrieved the first row from each as that has the highest number
Hi, Thank you for your response I have one more condition to validate, not in every case there will be duplicates at layer no , so is there a way to find out first whether there are duplicates and then remove
If you see the input and output…if there is a duplicate it would remove else it would use the same which is there…so it if no duplicate then it gives that row as well in the output
In the screenshot spr is not duplicate but even that is present in the output
Do you want to know separately if its duplicate or not?
Hi , This is not working as per my requirement , if at a particular l;ayer there are additional data which is there in other layer also it should not be eliminated , we need to check duplicate at each layer. For eg
Layer 2: abc
layer 2: def
layer2 : abc
Actually there are multiple scenarios that can come up in the datatable : I need to finf]=d a common fix if there are duplicates it handles if not then nothing