Query to get previous Day and week based on today's date

Automate query results

Just open tblCDCCodes.

Add a new record: CDC 99; Remarks: "No entries" (minus the quotes).

Then run AddDate(). Anytime you add new records to tblCDC, you'll need to call this sub to ensure that you've accounted for dates without entries. Don't worry, it'll only add one dummy record for any given date.


Bob

Bob,
Is there is anyway I can automate this query to run everyday and place output file in a network drive ??
 
I didnt read your complete post but cought this...
It is real easy to add fake values to your crosstab.

Just go to design view and add an IN clause, like so:
TRANSFORM Count( ) AS CountOf
In (Value, Value, Value)
SELECT
FROM
GROUP BY
PIVOT ;

Down side of this is that you need to list all values (IIRC), so any new values will fail to display unless added. But be sure to double check that cause I may be mistaken.

How to calculate values for Monthly ?? For Ex: If I run on Jun 30th, it should give me results asof each week of that month excludes Saturday and Sunday
06-June-0813-June-0820-June-0827-June-08
 
[Is there is anyway I can automate this query to run everyday and place output file in a network drive ??

The code needs to run anytime new entries are made, which it will. No point in running it everyday.

Bob
 
The code needs to run anytime new entries are made, which it will. No point in running it everyday.

Bob

Bob,
Can you also let me know how to get monthly data by week which is also posted in another thread
 

Users who are viewing this thread

Back
Top Bottom