Microsoft Query & Pivot table?

M

Mark J

I have created 2 pivot tables in an excel workbook.

1. The first pivot table brings in values from midnight to 6am.

2. The second pivot table brings in values from the previous 5 days.

My question is how do i state the [Date] criteria in Microsoft Query to
include the last 5 days but not today?

Right now I have a field called [Date] and the criteria is set as;
[>=getdate()-5]

this works, but i do not want today's values. Any ideas?
 
D

Debra Dalgleish

Use an And in the criteria, e.g.: >=date()-5 And <date()

Mark said:
I have created 2 pivot tables in an excel workbook.

1. The first pivot table brings in values from midnight to 6am.

2. The second pivot table brings in values from the previous 5 days.

My question is how do i state the [Date] criteria in Microsoft Query to
include the last 5 days but not today?

Right now I have a field called [Date] and the criteria is set as;
[>=getdate()-5]

this works, but i do not want today's values. Any ideas?
 
Top