one of the column in my table contains the data like
SAL
----
1000
1000
2000
3000
3000
So my requirement is i want output like
SAL
---
1000
2000
3000
it mean i want to delete duplicate rows in the table
permanently and i want output in the above formatow should u
write query?
Answer Posted / abin
Select sal from (Select *,ROW_NUMBER() over (partition by
sal order by sal asc)num from emp) a
Where num=1
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
what are the join types in tsql? : Transact sql
What is a dirty read sql?
How do I edit a trigger in sql developer?
Can two tables have same primary key?
describe mysql connection using mysql binary. : Sql dba
How do you delete data from a table?
what is the difference between rownum pseudo column and row_number() function? : Sql dba
What is program debugging?
What is function and procedure in pl sql?
What are % type and % rowtype?
What is the process of debugging?
how to select first 5 records from a table? : Sql dba
How do you rename a table in sql?
What is percent sign in sql?
what are the different tables present in mysql? : Sql dba