Home » SQL & PL/SQL » SQL & PL/SQL » Select Statement after deletion (Oracle 10g)
Select Statement after deletion [message #383156] Tue, 27 January 2009 07:37 Go to next message
raopapa
Messages: 10
Registered: January 2009
Junior Member
create table test
(
slr_no number(10),
name varchar2(20)
)

insert into test values(1,'test');
insert into test values(2,'test');
insert into test values(3,'test');
insert into test values(4,'test');
insert into test values(5,'test');

hi everyone,
if i delete the one of the row in the table, again the data should be in a serial order.

example

delete from test where slr_no = 4;

again data in the table should be :

Expected Resule:-
------------------
1,test
2,test
3,test
4,test


pl give the solution for this.
Re: Select Statement after deletion [message #383158 is a reply to message #383156] Tue, 27 January 2009 07:39 Go to previous messageGo to next message
dr.s.raghunathan
Messages: 540
Registered: February 2008
Senior Member
update using row number
Re: Select Statement after deletion [message #383162 is a reply to message #383158] Tue, 27 January 2009 07:58 Go to previous messageGo to next message
joy_division
Messages: 4644
Registered: February 2005
Location: East Coast USA
Senior Member
dr.s.raghunathan wrote on Tue, 27 January 2009 08:39
update using row number


This indeed does answer the OP question 100% based on their description. However, I am guessing that their example was oversimplified.

My guess is that what they really want to do is something ridiculous that I would not want to attempt.
Re: Select Statement after deletion [message #383168 is a reply to message #383162] Tue, 27 January 2009 08:13 Go to previous message
dr.s.raghunathan
Messages: 540
Registered: February 2008
Senior Member
Quote:

My guess is that what they really want to do is something ridiculous that I would not want to attempt.


i am curious to know even OP has no view on this
yours
dr.s.raghunathan
Previous Topic: URGENT:Deciding function or procedure at runtime.. (merged)
Next Topic: How to copy records from one table to another?
Goto Forum:
  


Current Time: Fri Dec 09 17:24:10 CST 2016

Total time taken to generate the page: 0.43555 seconds