| sm_ahmeds |
Posted: Apr 25, 2007 02:42:44 PM |
Total Post: 53
Joined: Apr, 2007
|
Hi.....one more query....please post how to delete the duplicate rows from a table without disturbing the connected users
Thank U |
|
|
Ratnaker |
| Posted: Apr 26, 2007 03:52:04 AM | |
|
Total Post: 141
Joined: Apr, 2007
|
Hi Ahmed,
u can delete duplicate row from table using given below the query
DELETE FROM table A WHERE ROWID > (
SELECT min(rowid) FROM table B
WHERE A.id = B.id);
Ratnaker
|
|
|
|
|
sm_ahmeds |
| Posted: Apr 26, 2007 09:58:15 AM | |
|
Total Post: 53
Joined: Apr, 2007
|
|
|
|
|
sm_ahmeds |
| Posted: Apr 29, 2007 01:53:17 PM | |
|
Total Post: 53
Joined: Apr, 2007
|
This query is not working...its giving o rows deleted. I want to delete the duplicate rows from the same table please help.
Thanks
|
|
|
|
|
vikhardba |
| Posted: May 03, 2007 10:18:57 AM | |
|
Total Post: 86
Joined: Apr, 2007
|
Hai Ahmed!!
I hope you are striving hard for Oracle. I hope this query is helpful to delete duplicate rows from the table ( ex: dept )
delete from dept t1 where rowid>(select min(rowid) from dept t2 where t1.deptno=t2.deptno);
I hope this exact example will help you to clarify ur issue.
Regards,
Mohammed Vikhar Ahmed.
|
|
|
|
|
swinal |
| Posted: Jul 07, 2007 10:27:30 AM | |
|
Total Post: 4
Joined: Jul, 2007
|
hi
i hope this query will help u.
Suppose table name is "table1" and it has two Colms T1 and T2
DELETE FROM table1
WHERE ROWID NOT IN (SELECT min(rowid)
FROM table 1
GROUP BY T1,T2)
|
|
|
|
|
| Time Zone: EDT |
Send this thread to your friend |