Extract order lines from a two-page purchase order with AI
Extract three traceable order lines, keep an unknown delivery date open and catch a subtotal carried onto the next page.
22 min readAs of Nov 2026
Lesson guide · goals & preparation
By the end of this lesson
- Identify subtotals at a page break.
- Keep separate dates for identical products and preserve an unknown date.
Who this is for
- Office staff turning supplier documents into tables.
What you need
- All you need is the ability to locate a numbered line on a page.
1 / 4
Theory
Understand what to ask AI to do, how to ask, and the ideas behind the workflow.
Why would identical folders have different line numbers?
On 7 May the receiving desk expects twelve folders. A second line promises five more for 9 May. “Seventeen folders” would be a perfectly good answer to a buyer asking about overall volume. It gives the warehouse the wrong expectation for the first delivery. Decide who will use the answer before asking for a summary.
F-04 identifies a product. L10 identifies one commitment inside a particular order. Keep that smaller unit whenever different delivery dates will change what somebody does.
So which table is correct? Both are. A budget owner wants one line reading seventeen F-04 folders; the warehouse wants two lines, twelve on the seventh and five on the ninth. Before writing a request, write the reader's question at the top of the page. "How many that day?" keeps dated rows. "How much this quarter?" groups by product. The same records, a different question, a different table.
Read the page break before collecting numbers
Read the record from top to bottom. A dash marks an empty cell. “Blue cover” continues the notebook description. The subtotal of 20 adds up entries already printed above it, and the next page repeats that subtotal as a carry-forward. Neither entry carries a line identifier.
Illustration: Order lines enter the table while the carried subtotal stays on the page · AI Ping
- Carry over L10 with twelve units and L20 with eight as separate lines.
- The subtotal of twenty reappears as a carry-forward. Neither is a new order.
- Add L30’s five units on a new line for three lines totalling twenty-five.
Read every step as text
- Six lines carry a number. Added together they make 90, yet the order total printed at the bottom is 25. Read from the top to see which lines are orders.
- L10 has a line identifier, so it is an order. Its twelve folders become the first row of the register.
- L20 is an order line too. Eight notebooks make the second row and the total reaches 20.
- “Blue cover” has no identifier and no quantity. It becomes a note under L20 and is not counted as an order.
- “Page subtotal 20” has no identifier. It repeats the 12 and 8 already carried over, so it stays behind.
- Page two opens with “Brought forward 20”, the same 20 again. It only marks the page break, and the total stays at 20.
- L30 is a new order line. Its five folders bring the total to 25.
- “Order total 25” is used as a check and is not carried over. It equals the three rows, so nothing was dropped or counted twice.
Preserve page position and neighbouring text when copying data. A bare list of numbers removes the evidence you need to distinguish a quantity from a subtotal. If a scan obscures an identifier, retain its position for manual review. The fictional transcription below is sufficient for the exercise.
A bare 20 at the page foot looks like an order too. Two quick checks separate them. First, does the line start with an L identifier? Subtotals, carry-forwards and totals do not. Second, does the number equal the sum of the lines above it? Twelve plus eight is twenty, so that footer is not new stock. When both hold, use the line for checking, never for a table row.
PO-18, a teaching document in its original page order Page / position Record Quantity Requested date 1 / top L10 F-04 folder 12 7 May 1 / middle L20 N-02 notebook 8 — 1 / next line ↳ blue cover — — 1 / footer Page subtotal 20 — 2 / header Brought forward 20 — 2 / middle L30 F-04 folder 5 9 May 2 / footer Order total 25 —
2 / 4
Step by step
Learn what to prepare, how to request help and how to revise the result through examples and explanations.
Tell the assistant what one row represents
Imagine the receiving clerk asking, “Has anyone actually promised a date for L20?” Design the output so the clerk can answer by looking at one cell. Ask for a source location such as “page 1, middle” alongside the extracted value.
Collect the order lines before summing them. You can always group by product afterwards. Keeping an auditable register gives the buyer a way to reconstruct either view.
Test your instruction before you send it. Walk the "blue cover" line through it in your head. "One row per L identifier" leaves that description attached to L20, because it carries no number. "One row per line" would turn the cover colour into an empty row with no quantity. A single sentence decides whether a product survives or noise appears. When unsure, spell out the exception: attach continuation text to its item.
Example prompt Build a receiving register from PO-18. Use one row per L identifier. Return line ID, item and quantity, requested date, source position and notes. Attach continuation text to its item. Mark missing dates for review. Use printed totals only to check arithmetic. PO-18, a teaching document in its original page order Page / position | Record | Quantity | Requested date 1 / top | L10 F-04 folder | 12 | 7 May 1 / middle | L20 N-02 notebook | 8 | — 1 / next line | ↳ blue cover | — | — 1 / footer | Page subtotal | 20 | — 2 / header | Brought forward | 20 | — 2 / middle | L30 F-04 folder | 5 | 9 May 2 / footer | Order total | 25 | —
Repair a draft with the right total and the wrong dates
Here is an editor-written test draft: “F-04, 17 folders due 7 May; N-02, 8 notebooks due 7 May. Total 25.” Its arithmetic passes. Five folders now appear two days early and the notebook has acquired a date without supporting text.
Name the broken relationship in your next request. Point to L30 and to the empty cell beside L20. Also identify what should survive the correction, including the eight blue notebooks.
When the corrected table returns, check only the cells that should have moved. The draft's single "F-04, 17, 7 May" must split into "F-04, 12, 7 May" and "F-04, 5, 9 May". The notebook's date must change from "7 May" to a review flag. Confirm all three spots by hand before moving on. Re-reading the total of 25 alone would miss every one of them.
Example prompt Split the 17 folders back into L10 and L30. Use only the date printed on each line. Flag L20’s date for review. Then report the quantity confirmed for 7 May.
Worked example & explanation Only twelve folders are confirmed for 7 May. The other five are due on the ninth. No notebook date is recorded.
Hand over a three-line register
Trace each output line to a page and verify 12 + 8 + 5 against the printed total of 25. These checks answer different questions. A second check on due dates still leaves one real action for the buyer.
Illustration: Two separate folder lines and an unfilled notebook date · AI Ping Keep PO-18 with the register. L10 in a new purchase order could describe something else entirely. Build a product summary from this register for colleagues who only need purchasing totals.
Imagine a buyer asking where the blue cover and the unknown date came from. Both describe L20, but only the colour appears on the continuation line. The date was checked against the original line itself. A later confirmation should update that date without overwriting the colour note.
Register for the receiving desk Line Item / quantity Requested date Source / note L10 F-04 folder × 12 7 May Page 1, top L20 N-02 notebook × 8 Ask buyer Page 1, middle · blue cover L30 F-04 folder × 5 9 May Page 2, middle
3 / 4
Self-check
Think about what you would ask AI, then read the explanation. Written submissions and external AI use are optional.
This is a learning check, not a test you must pass. Use the explanations to understand the ideas.
Q1Which PO-26 rows and total survive?
Write your thoughts (optional)
Your writing is not sent anywhere. It disappears when you leave or reload this page, so copy anything you want to keep.
Read the answer and explanation
L01 has 6, L02 has 4 and L03 has 3, for 13 packs. The subtotal and carry-forward repeat earlier values in this fictional order.
This is your own review, not an automatic score.
Q2A draft says all ten envelope packs are due on 4 June. What changes?
Write your thoughts (optional)
Your writing is not sent anywhere. It disappears when you leave or reload this page, so copy anything you want to keep.
Read the answer and explanation
Only six packs on L01 have that date. Ask the buyer about the other four on L02.
This is your own review, not an automatic score.
Q3The buyer later confirms 8 June for L02. What do you edit?
Write your thoughts (optional)
Your writing is not sent anywhere. It disappears when you leave or reload this page, so copy anything you want to keep.
Read the answer and explanation
Update L02’s date and identify the confirmation. The order still contains thirteen packs.
This is your own review, not an automatic score.
Common mistakes
- Grouping solely by product conceals different delivery dates.
- Filling an empty date from above hides an open question.
Your learning record
Completion is optional. Mark this lesson when you feel ready, or move to the next lesson without marking it.
Completion is saved in this browser.
4 / 4
Apply to your work
Consider how new material changes the workflow and checking criteria. Trying an external AI tool is optional.
Try it with envelopes and labels
Build an independent register for PO-26. Start with two piles on paper: order lines and numbers printed for checking. If you use an assistant, replace the entire PO-18 example with the new record.
A colleague asks how many envelope packs are actually due on 4 June. Can your register answer without guessing the remaining delivery date? Write down the exclusions before opening the worked answers.
Here is one more self-check. After filling your table, count two things. First, does the sum of the order lines you kept match the number printed at the foot of the original? If not, you probably carried a subtotal or a carry-forward by mistake. Second, how many dates are filled and how many are blank? List each blank as a question for the buyer. Count both before opening the answers below.
Fresh purchase order PO-26 Page Original entry 1 L01 envelopes, 6 packs, 4 June 1 L02 envelopes, 4 packs, date blank 1 Subtotal 10 2 Brought forward 10 2 L03 labels, 3 packs, 6 June 2 Total 13
Write a note (optional)
Use this only if you want to record a prompt or your understanding. This is a notebook, not a connected AI assistant.
Your writing is not sent anywhere. It disappears when you leave or reload this page, so copy anything you want to keep.
References
- Get a three-line summary of a long report — AI Ping
- Power Query PDF connector — Microsoft Learn