Re: Getting the High and Low Tides from a Series of Data
From: Michel Walsh (vanderghast_at_VirusAreFunnierThanSpam)
Date: 10/29/04
- Next message: Petra: "Re: Write conflict"
- Previous message: Michel Walsh: "Re: Getting the High and Low Tides from a Series of Data"
- In reply to: Michel Walsh: "Re: Getting the High and Low Tides from a Series of Data"
- Messages sorted by: [ date ] [ thread ]
Date: Fri, 29 Oct 2004 12:48:30 -0400
Hi,
Erratum: should be
...
AND
myTable.Level IN( query1.ma , query1. mi)
since query1.ma and query1.mi are Level values, not DateTimeStamp values.
Vandergahst, Access MVP
"Michel Walsh" <vanderghast@VirusAreFunnierThanSpam> wrote in message
news:eSVD%23QcvEHA.716@TK2MSFTNGP10.phx.gbl...
> Hi,
>
> Sure. In the reference I supplied, methods 1, 2, and 4 (cascading
> queries, sub queries and virtual table) will extract all occurrences
> (dateTimeStamp) of an extremum. I prefer method 3, a total query, because
> it is the only one to be 100% "graphically" compatible with the query
> editor, but its limitation is to "naturally" retrieve just one occurrence
> of the extremum. Method 1, cascading queries, is probably the next simpler
> method. The idea is to make a query that find the min/max value for Level,
> per ActionID, in query1:
>
>
> SELECT ActionID, MIN(Level) As mi, MAX(Level) As ma
> FROM myTable
> GROUP BY ActionID
>
>
>
> and then, used it as virtual table:
>
>
> SELECT myTable.*
> FROM myTable INNER JOIN query1
> ON myTable.ActionID=query1.ActionID
> AND
> myTable.DateTimeStamp IN( query1.ma , query1. mi)
>
>
> You can change the inner join to a cross join, and bring the ON clause in
> a WHERE clause, if you prefer:
>
>
> SELECT myTable.*
> FROM myTable , query1
> WHERE myTable.ActionID=query1.ActionID
> AND
> myTable.DateTimeStamp IN( query1.ma , query1. mi)
>
>
>
>
>
> Hoping it may help,
> Vanderghast, Access MVP
>
>
- Next message: Petra: "Re: Write conflict"
- Previous message: Michel Walsh: "Re: Getting the High and Low Tides from a Series of Data"
- In reply to: Michel Walsh: "Re: Getting the High and Low Tides from a Series of Data"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|