Find stalled quotes in Excel with Power Query
Build a refreshable list of quotes still waiting for approval from two weekly exports. A quote that moved to Scheduled should drop off, even when its old waiting row is still in the folder.
Start the guideSee the waiting list you will build
If you called everyone who had ever had a waiting status, you would call customers who already have a job booked. This list keeps one latest status per quote. Use the timestamp on the source row to decide which status is current.
Open the finished workbook to see the expected result. To run the queries on your own files, use desktop Excel for Windows with Power Query and permission to read a local folder. The workbook starts with a saved example. The guide kit includes the queries you will connect to your copy. A waiting status means the desk has a case to check. You would also need an agreed time limit to label it overdue.
| Quote | Latest local update | Status |
|---|---|---|
| Q101 | Apr 6, 09:03 | Waiting for approval |
| Q104 | Apr 7, 11:12 | Waiting for approval |
- Excel guide kit (ZIP)The example workbook, two starter CSV exports, two test files, query code and setup instructions.
- Finished example workbook (Excel)Inspect the example results before connecting your local folder.
- View the example queue (PNG)
Prepare a folder with just the two exports
Extract the ZIP to your computer first. Inside the exports folder, keep week-01.csv and week-02.csv. Leave the test CSVs outside it until you reach the refresh checks. All timestamps use the same local clock.
Open the two CSVs and check their headers. Each file needs QuoteID, UpdatedAt and Status. Close them without saving changes. There are six rows and four IDs. Q101 has the same 09:03 waiting event in both files. The course follows its separate, completed history. Here, the queue can only reflect the updates these exports contain.
- Open quote-queue-example.xlsx and use File, Save As to make a working copy outside exports. Keep the saved example tabs for comparison. Your new tabs will be the ones that refresh.
- In File Explorer, open the extracted exports folder and copy its full path from the address bar. You will use that path in the next step.
| Source file | Quote and update | What reaches the desk |
|---|---|---|
| week-01.csv | Q101, Apr 6 09:03, Waiting for approval | Waiting queue, once |
| week-01.csv | Q102, Apr 6 09:15, Waiting for approval | Superseded by its scheduled update |
| week-01.csv | Q103, Apr 6 10:20, Scheduled | No follow-up |
| week-02.csv | Q101, Apr 6 09:03, Waiting for approval | Exact repeat of the first row |
| week-02.csv | Q102, Apr 7 11:00, Scheduled | No follow-up |
| week-02.csv | Q104, Apr 7 11:12, Waiting for approval | Waiting queue, once |
Create the latest-status query
This first query reads the source files, parses the update time as a date and time, and removes exact duplicate records. For each QuoteID it finds the latest timestamp and keeps every distinct status recorded at that time. Conflicting statuses need a person to decide which one is correct.
- Choose Data, Get Data, From Other Sources, Blank Query. In Power Query Editor, use the Name field in Query Settings to name the query QuoteSnapshot.
- Open QuoteSnapshot.pq from the queries folder in a plain text editor. Copy its full contents. Choose Home, Advanced Editor in Power Query, replace everything there and paste the code.
- Replace the example folder path near the top of the code with your exports folder path. Keep the surrounding double quotes. Select Done and check that the preview has four quote IDs.
- On Home, open the Close & Load menu, choose Close & Load To, select Only Create Connection, then OK. QuoteSnapshot will feed both outputs.
See a worked example
Q102 entered the waiting queue on April 6 at 09:15. It became Scheduled on April 7 at 11:00. Filtering for Waiting for approval before finding the latest update would leave Q102 on the call list.
Load the waiting list and the review list
The two shorter queries refer to QuoteSnapshot by name. One produces the queue the desk can act on. The other collects cases where different latest statuses share the same timestamp.
- Create a second blank query. Name it WaitingQueue and paste the entire contents of WaitingQueue.pq into Advanced Editor. Choose Done, then Close & Load To, Table, New worksheet.
- Create a third blank query named ConflictReview. Paste ConflictReview.pq and load it as a table on another new worksheet. Save the workbook.
- Compare WaitingQueue with the two rows above. ConflictReview should have column headers and zero cases. Scheduled quotes such as Q102 and Q103 belong in neither list.
Refresh twice and prove it works
Use the two test files in order. These changes teach you what an old waiting row and a genuine conflict look like in a live queue.
- Copy week-03.csv from test-cases into exports. Choose Data, Refresh All and wait for Excel to finish. Q104 has a later Scheduled update. WaitingQueue should now contain Q101 alone.
- With week-03.csv still present, copy week-04.csv into exports and refresh again. Its two Q101 updates share the latest timestamp and disagree. WaitingQueue should be empty. ConflictReview should contain Q101, with both statuses available to the reviewer.
- Remove the two test files from exports and refresh once more. The original two-row waiting list should return. For your own exports, use filenames starting with week- and ending in .csv. Match the starter headers, timestamp format and status labels.
Check your result
Two starter files give six input rows, five distinct updates and four unique IDs. The waiting queue holds Q101 and Q104. Adding week-03.csv leaves Q101. Adding week-04.csv moves Q101 to review. Removing the test files restores the starting queue.
If your result looks different
If Q102 appears, check that WaitingQueue reads from QuoteSnapshot after the latest update was selected. If a test changes nothing, confirm Excel points at the extracted exports folder, the test file is inside it, and Refresh All has finished. If dates fail to parse, inspect UpdatedAt against the starter format yyyy-MM-dd HH:mm:ss. If a query name is missing, match all three names to the supplied files.
Resources
- Excel guide kit (ZIP)The example workbook, two starter CSV exports, two test files, query code and setup instructions.
- Finished example workbook (Excel)Inspect the example results before connecting your local folder.