den 22 maj 2002 08:13
> Till: [EMAIL PROTECTED]; Jonny Stendahl
> Ämne: AW: Subselect or other way?
>
> I think my english ist too bad
>
> My table looks like this
>
> id nr
> ---
> 1 123
> 1 456
> 1 678
> 2 457
> 2
This is a simple SELECT statement:
SELECT id
FROM Table
WHERE nr=3D123
AND id = 3D456
this gives you probably one record, or you could use OR:
SELECT id
FROM Table
WHERE nr=3D123
OR id = 3D456
this gives you all records with nr 3D123 OR id 3D456
//
Jonny
> -Ursprunglig
Hi Rich,
Use the LIMIT 2 and sort the SELECT with ORDER BY family ID DESC
//
Jonny
> -Ursprungligt meddelande-
> Från: R.Dobson [SMTP:[EMAIL PROTECTED]]
> Skickat: den 21 maj 2002 14:57
> Till: [EMAIL PROTECTED]
> Ämne: returning top two values
>
> Hi,
> I have a table containi