Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Selecting SIMILAR, not the same records (PROBABLE) duplicates
> kroger wrote:
>> Hi,
>>
>> I've been struggling with that for two days now...
>> There is a simple solution for finding duplicates - with GROUP BY and
>> HAVING COUNT(*)>1 but it is not enough in my case...
>>
>> For the example table as follows:
>>
>> id || name
>> 1 || aaa
>> 2 || aaa xxx
>> 3 || aaa
>> 4 || aaah
>> 5 || bbb
>> 6 || bbb p
>> 7 || ccc
> If you think ID1 = ID2 and ID1=ID4 you are not looking for duplicates.
> It is no wonder no one's proposed solution worked.
I know they are not duplicates. That;s why I put SIMILAR and PROBABLE
duplicates in the topic...
Bad thing is, I need to have some way to display say element A (of whatever
id 1-4) and all its PROBABLE duplicates... Tricky, but requested...
> My immediate thought is that you have two choices. One is regular
> expressions if you are in 10g or a PL/SQL procedure.
I'm using 9i unfortunately :( I was considering doing that in PL/SQL but -as I mentioned, I don't rely on myself as it comes to Oracle and its goodies... That's why I was posting this problem...
>
> Without knowing the business rules it is impossible to tell what
> would be required.
Since I cannot move to 10g, PL/SQL, I suppose..
>
> But by any normal definition the normal the only duplicates are
> ID1 and ID3 and I'd solve that problem by creating a unique constraint
> and dumping violations to an error table.
As I mentioned, it's not about dumping duplicates, but displaying possible user faults when entering data for further verification...
Thanks a lot, anyway!
BR,
Kroger
Received on Tue Sep 05 2006 - 15:01:29 CDT
![]() |
![]() |