Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Updating a column based on a 'Windows Function' formula

Updating a column based on a 'Windows Function' formula

From: RJ <ridwan.jeena_at_gmail.com>
Date: 15 Nov 2006 01:20:59 -0800
Message-ID: <1163582458.660092.315840@h48g2000cwc.googlegroups.com>


Hi All,

I want to make the following update:

update TIME_TABLE a
set a.end_date_time = lead(a.start_date_time) over (order by a.start_date_time)

what this does is it takes the next records start time and uses it as an end time.
If i use this in a select statement the results are perfect, but I cant update records using this function.

How can I update the end_date_time column?

Thanks in advance :) Received on Wed Nov 15 2006 - 03:20:59 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US