
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
how to determine the number of duplicate rows each record has
Hi, how do I determine the number of duplicate rows each record has? Do I use recno function? I have many records that have many duplicates and also records that only appear once, and I want to create another column that displays the number of duplicate rows for each record. Thanks.
- « Previous Replies
-
- 1
- 2
- Next Replies »
Accepted Solutions


- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Select date, site, person as dimensions of straight table, and write expression Count(date)
Sergey


- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Try to use count(any field) ... group by all other fields.
Hope this helps.
Andrei


- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi
select dimension like uniqe key and expression
Count(1)
Sergey


- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
in a list box u can write the expression and check how many times that record is coming
keep two listbox 1.count (distint urfieldname) 2. count(urfieldname)

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
hi, i did not try this but, you can
1 sort your table ( you can Count the number of records)
2 create a Composite key with all columns (if they are not so many)
3 use autonumber and create a numeric key, same records will receive the same numeric key
4 use previous function and compare if the sorted keys are the same and flag it, then you can recognize the duplicates

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Where should I type this? I cant seem to type in edit script.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Sorry I don't get how I should type this


- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
If you want to add this coloumn permanently, just make like this:
ur_tbl:
Load
field1
, field 2
, field 3
, 'key' as ArtificialKey
from (...);
noconcatenate
new_ur_tbl:
LOAD field 1
, field 2
, field 3
, count(ArtificialKey) as Qty
Resident ur_tbl
Group By
field 1
, field 2
, field 3 ;
drop table ur_tbl;
But if you want use it in chart only better use Sergey's approach, just count(1)
Andrei


- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Rachel
PFA an example
In this example the row with Id=1 repeats two times
Sergey

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Sorry but I'm not able to open the file actually...could you maybe type out the example? thanks:)

- « Previous Replies
-
- 1
- 2
- Next Replies »