silentthread2k
asked on
MSAccess: Is there a query that will catch a streak? Details...
Example table....
Date,Sales
11-4-2011,$200
11-5-2011,$302
11-6-2011,$448
11-7-2011,$149
So based on the table above, the query will return the number 2, since the longest streak of sales over $300 was from 11-5 to 11-6.
I'll take answers in both MSAccess query and C# Linq, but I prefer the MSAccess query.
Date,Sales
11-4-2011,$200
11-5-2011,$302
11-6-2011,$448
11-7-2011,$149
So based on the table above, the query will return the number 2, since the longest streak of sales over $300 was from 11-5 to 11-6.
I'll take answers in both MSAccess query and C# Linq, but I prefer the MSAccess query.
ASKER CERTIFIED SOLUTION
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.