Excel 2010 x32 on Win 7 x64
I have multiple tables coming into Powerpivot via SQL connection. They have some relationships pre-defined from the source.
I need to reduce the amount of data I'm bringing in for my testing. One of the tables has great granularity, containing every event in the database. One field in this data is "Event Type".
A separate table has a short list of the event types of interest.
I'd like to filter the first table's data pull (SQL refresh) to only include the event types that are listed (and visible) in the second table, in addition to an existing date range filter that is already in place. Ultimately my goal is to widen the date range I can pull in before hitting Excel's memory limits, by eliminating the events I don't care about.
Currently I'm using a SQL query to pull in the granular data;
SELECT
[Fact RawData].*
FROM
[Fact RawData]
WHERE
[Fact RawData].[Event Date] >= N'2014-06-01T00:00:00'
How would I adjust this to also say "only where [Fact RawData].[Event Type] IN {a column in a data pull that is already in powerpivot}"
and how will that work under a "refresh all" scenario, where I would need the event table to update before this SQL is executed each time?
Many thanks!