Doug Nebeker <[EMAIL PROTECTED]>
wrote:
Imagine I have the following data:
TimeStamp | Person | Data1
-------------------------------
1 | Doug | X
2 | Doug | Y
2 | Fred | A
3 | Doug | Z
4 | Fred | B
How do I set all Data1 values for each person to the _first_ value
that
was seen for them (X for all Doug Data1 values, A for all Fred Data1
values)?
update tableName set data1 =
(select data1 from tableName t2 where t2.Person=tableName.Person
order by t2.TimeStamp limit 1);
Igor Tandetnik
-----------------------------------------------------------------------------
To unsubscribe, send email to [EMAIL PROTECTED]
-----------------------------------------------------------------------------