Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
Planet_Jeroen
Starting Member
3 Posts |
Posted - 2003-11-17 : 10:53:44
|
Hi all...I'm not at all good with Access, I just know my way around the help. I made a database that stores logging information. Below table overview:LOGS:-LOGID => Key-DATE/TIME => Obvious-EVENTID => Which Event ?Now I get thousands of events each day, and I want to be able to see the following:Within a date time selection select the following:Date/Time + Unique EventID + Count of occurence of EventID + Date First occurence and Date last occurence.To do this I created the following table:LOGS2:-LOGID -DATE/TIME } combined KEY-EVENTID } combined KEYThen I created querys that:1st Query: make a date time selection on LOGS2nd Query: append all records from LOGS to LOGS2 (filter out double occurences on key violation)3rd Query: Select from LOGS2 everything and count for each record how many times the EventID occurs within the date time selection on LOGSNow I realy want to be able to see the 'youngest' and 'oldest' occurence in LOGS as well. MS Access help does not provide help on this, or I use the wrong keywords... any hints ???Greetz |
|
Planet_Jeroen
Starting Member
3 Posts |
Posted - 2003-11-17 : 11:42:57
|
Reading this back I think should rephrase the last line..quote: Now I realy want to be able to see the 'youngest' and 'oldest' occurence in LOGS as well.
Translated to normal English (I hope) I ment the first Date/Time of the occurance and the last one.Greetz |
 |
|
X002548
Not Just a Number
15586 Posts |
Posted - 2003-11-17 : 11:51:04
|
SELECT MAX(datetimeCol), MIN(datetimeCol)???Brett8-) |
 |
|
Planet_Jeroen
Starting Member
3 Posts |
Posted - 2003-11-17 : 11:54:45
|
Thanx a lot ... I'm already off to the book store ;)Greetz |
 |
|
|
|
|