Re: Return only most recent date records
From: DataGuy (nospam_at_hotmail.com)
Date: 02/07/05
- Next message: Raymond Clarke: "Convert Single to Seconds"
- Previous message: DataGuy: "Re: Return only most recent date records"
- In reply to: Per Larsen: "Re: Return only most recent date records"
- Next in thread: Per Larsen: "Re: Return only most recent date records"
- Reply: Per Larsen: "Re: Return only most recent date records"
- Messages sorted by: [ date ] [ thread ]
Date: Mon, 7 Feb 2005 11:30:37 -0500
Per,
Can you explain the predicate 'TOP 1*'? Don't I need to tell the SELECT
statement which field to pick the TOP from?
This is my first use of 'select', so I'm on the learning curve here.
Thank you!
"Per Larsen" <perl.news@tiscali.no> wrote in message
news:M7MNd.98230$Vf.3861998@news000.worldonline.dk...
> DataGuy wrote:
>> Hello!
>>
>> I have a table that I use to track files being transferred to & from our
>> company. When a new file arrives, it's 'Transfer_Date' & 'Part_#' is
>> logged.
>>
>> I need to figure out a way to create a query to return only the most
>> recent record for each part number. I thought if I could maybe do
>> something like this:
>>
>> MIN=(Now - [CAD LOG]![Transfer Date])
>
> select top 1 *
> from <table>
> order by [Transfer Date] desc
>
> hth
> PerL
>
>>
>> But I cannot get it to return anything. It doesn't error out, but I get
>> no results, so I don't know what to fix.
>>
>> Any suggestions are appreciated.
>>
>> Thank you!
- Next message: Raymond Clarke: "Convert Single to Seconds"
- Previous message: DataGuy: "Re: Return only most recent date records"
- In reply to: Per Larsen: "Re: Return only most recent date records"
- Next in thread: Per Larsen: "Re: Return only most recent date records"
- Reply: Per Larsen: "Re: Return only most recent date records"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|