View Single Post
  #4  
Old April 9th, 2010, 06:40 AM posted to microsoft.public.access.gettingstarted
John W. Vinson
external usenet poster
 
Posts: 18,261
Default How to show time for day's stock market high/low

On Thu, 8 Apr 2010 18:20:01 -0700, Seano
wrote:

I've set up a database of stock market intraday data going back two years,
showing Open/High/Low/Close data for every one minute bar of the day. I'm
trying to find 1) the high and low of each day, and 2) the times they
occurred.

Using: Date By Day: Format$([Stock Data].[Date],'yyyy.mm.dd') I can find the
Max of High and Min of Low to give me the day's high and low, but how do I
find the minute these occurred (there may be more than one, so if only one
could be displayed, the first occurence would be best ).

Many thanks


The Format function isn't necessary (or even a very good way to do this): the
DateValue() function will extract just the date portion for grouping. To get
the high for the day and its time you can use a subquery. Could you post the
actual fieldnames of your table, and indicate which field contains the price
of interest? Is there in fact a high/low/open/close field for each *minute*?
And does the field (misnamed, it's a reserved word) Date contain the date and
time?

--

John W. Vinson [MVP]