Hi John,
The following are my fields of the database:
1. [ID] - Autonumber
2. [Trading Date] - Date
3. [Stock Name] - Text
4. [Close] - Number (Stock closing price)
I have a main (Stock Historical) database where i collect all the historical
stock prices of different stock names. Then a use a query (combo box) to
select a particular stock name and append these data into a new table show as
above.
As the Trading Date is not in sequence......meaning stock market only open
on weekdays except public holiday and weekend. If a use date as reference, I
presume that the 14days will not be accurate as the Access will also count
the public holidays and weekend even it is not a trading days.
Hope the above information will be sufficient. Thank for your response.
Nelson Chou
John W. Vinson said:
I can only help you if you help me do so, Nelson. I cannot see your database,
and have no idea how your records are stored. I don't know how trading days
are defined in your database.
You would certainly use a query, but since I don't know the basis - the tables
- I cannot suggest how that query might be written!
Please post a more thorough description of your table and an example of the
date range that you would like to calculate.
John W. Vinson [MVP]