-
Hi Gurus!
I have a table with 2 cols colA and colB.
The data is as follows:
colA colB
john smith
smith john
I wish to select only one of these rows, or I wish to even delete one of these rows.
How would I do it?
Thanks!
Hemant
-
your delete statment should be like this:
------------------------------------------------------
delete from your_table t1
where rowid < (select max(rowid) from your_table t2
where
t1.colA || ' ' ||t1.colB = t2.colA || ' ' ||t2.colB
or
t1.colA || ' ' ||t1.colB = t2.colB || ' ' ||t2.colA)
;
------------------------------------------------------
-
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|