write a query to delete similar records in same table
Answer Posted / umadevi
--deletes records within table without changing table name
delete from temp t1 where rowid<(select max(rowid) from temp
t2 where t1.empno=t2.empno) order by empno;
or
--create new table n insert records.
create table t1 as select distinct * from temp;
or
(truncate table)
truncate table t1;
insert into t1 select distinct * from temp;
| Is This Answer Correct ? | 1 Yes | 5 No |
Post New Answer View All Answers
can a stored procedure call itself or recursive stored procedure? How much level sp nesting is possible? : Sql dba
Mention what is the function that is used to transfer a pl/sql table log to a database table?
How many commands are in sql?
what is the difference between where clause and having clause? : Sql dba
what is single byte over head in oracle..?
Is sql between inclusive?
What is secondary key?
name 3 ways to get an accurate count of the number of records in a table? : Sql dba
What mean sql?
explain the delete statements in sql
What is a constraint? Tell me about its various levels.
What is sql in java?
Define the select into statement.
What is transaction control language (tcl)?
What is trigger explain it?