Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How do I get just the latest edit dates
Message
De
21/03/2005 12:58:11
 
 
À
21/03/2005 10:06:58
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Syntaxe SQL
Divers
Thread ID:
00997819
Message ID:
00997897
Vues:
11
You need to do what's called a "correlated sub-query". I haven't done one in a few, so If I make a mistake in this example, I'm sorry but it's something like:

Select location, part, editdate from inventory A where editdate = (select
max(editdate) from inventory B where b.part = a.part and b.location = a.location)

Pf

>IF I wanted to just get the latest edit dates from a table
>
>i.e.
>
>select location, part, editdate
>Form inventory
>
>How would I just get the records from the most recent editdate?
>
>Thanks
>Jim

(On an infant's shirt): Already smarter than Bush
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform