Advertisement

07.07.2006 at 10:38AM PDT, ID: 21911772
[x]
Attachment Details

one time UPDATE for correcting data

Asked by chsrinivas123 in Oracle 3rd Party Tools

Tags: time, column, correcting, date, updates

I have a table called CAS_SRCO_STAT which has columns : CHG_ORD_REQ_NBR(NUMBER type column),SRCO_STAT_EFF_DATE (DATE type column), SRCO_STAT_TY_NAME(VARCHAR2 type column)
CHG_ORD_REQ_NBR is the primary key for this table.SRCO_STAT_EFF_DATE gives the date and time when any status(given by SRCO_STAT_TY_NAME)is inserted into this table.i don't want multiple status to be inserted into this table with same date and time.
I found all such CHG_ORD_REQ_NBR from this table by using this query :

select CHG_ORD_REQ_NBR,SRCO_STAT_EFF_DATE  from CAS_SRCO_STAT where SRCO_STAT_TY_NAME in ('CHANGE ORDER COMPLETE','CO RECONCILED') group by  CHG_ORD_REQ_NBR,SRCO_STAT_EFF_DATE having count(*) > 1

Now i want to update srco_stat_eff_date by increasing the time by 1 sec for the rows which have status as ''CHANGE ORDER COMPLETE' and have the same date and time as the ones which have status as 'CO RECONCILED' Start Free Trial
 
Loading Advertisement...
 
[+][-]07.07.2006 at 10:53AM PDT, ID: 17060538

View this solution now by starting your 7-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zone: Oracle 3rd Party Tools
Tags: time, column, correcting, date, updates
Sign Up Now!
Solution Provided By: sathyagiri
Participating Experts: 2
Solution Grade: B
 
 
[+][-]07.07.2006 at 11:11AM PDT, ID: 17060699

Assisted solutions are selected by the member who asked the question as a comment that contributed to their question's solution.

Start your 7-day free trial to view this Assisted Solution or ask the Experts your question.

 
[+][-]07.10.2006 at 08:45AM PDT, ID: 17073866

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
 
Loading Advertisement...
20080716-EE-VQP-32