Posted by CK on 10/01/75 11:32
Would this only give the the value of max ID as a result? I think Sandy
wants the complete row which has the max ID value.
"Jens" <Jens@sqlserver2005.de> wrote in message
news:1132566796.857987.84390@g49g2000cwa.googlegroups.com...
> This could be a solution:
>
>
> Select MAX(ID) FROM SomeTable
> Where Time =
> (
> Select MAX(Time) From SomeTable
> )
>
> You were missing the aliases:
>
>
> select max(ID) from
> (
> select * from A where time in
> (
> select max(time) from A
> ) SubQuery1
> ) SubQuery2
>
>
> HTH, Jens Suessmeyer.
>
Navigation:
[Reply to this message]
|