none
Limiting rows in query RRS feed

  • Question

  • I am pretty new to PQ so forgive my butchery of the terminology.

    I have an excel spreadsheet with a table on it. About 40,000 rows.  Loaded in PQ to Connection only

    I can import that into a PQ with a problem.

    I need to compare those 40,000 rows against the data in an ODBC SQL Server connection with over 4 million rows.

    When i create the query for the SQLServer connection, i filter the date range to the last 90 days.  This should limit my table to about 90,000 rows.  I want to load this to a Connection Only, and i think i did that correctly. But when I close and load, PQ goes out and pulls all 4million rows, taking about 30 minutes.

    Then, when i merge the queries, using a left join, PQ again goes out and pulls all 4 million rows again.

    What do i have to do to get PQ to only load the ~90,000 Rows?  

    Part two of question.  When i merge these queries (i will have  three queries to merge total), do i load each query to Connection Only, and not to the Data Model, except for the last merged query that has my desired output, or should i be loading the query to the Data Model?  

    thanks 


    • Edited by Jeff Green 88 Monday, August 29, 2016 6:11 PM part two
    Monday, August 29, 2016 3:37 PM

Answers