Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

How can we Get the Updated Rows? ie, There is 100s of Rows i
updated the Rows who have salary 5000. then i want to select
the Updated Rows. How can we achieve it?

Answer Posted / sudipta santra

create table t1 as select * from emp;
truncate table t1;

create or replace trigger tri_t1
before update on emp
for eachrow
begin
insert into t1
values(old.empno,old.ename,old.job,old.hiredate,old.sal,
old.comm,old.deptno);

end;
after create trigger
then if u update then the old updated values will be kept
in t1 table.

Is This Answer Correct ?    1 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is varchar sql?

1140


How to display the records between two range in Oracle SQL Plus?

1146


How does join work in sql?

1012


Explain architecture of sql server notification services?

1060


What is sql used for?

1124


How insert into statements in sql?

1072


What is thread join () in threading?

1015


What is difference between sql function and stored procedure?

1003


Why left join is used in sql?

979


What are the benefits of pl/sql packages?

1107


What is the plv (pl/vision) package offers?

1052


How does index help in query performance?

1028


What is an intersect?

1102


Does execute immediate commit?

1219


What are the commands used in sql?

1079