Compare the source file with the imported table before changing the template. If the imported values are already wrong, correct and re-export the source. If the table is right but the PDF is wrong, inspect field connections and invoice grouping.
Find the first place where the data changes
Keep the original spreadsheet and make a small test file with two or three records. Include the record that fails and one that works. Compare three stages: the values in the source, the data shown after import, and the populated PDF.
Use a plain-text editor to inspect a CSV when necessary. Opening the file in a spreadsheet application can reinterpret dates or number-like identifiers, which can hide where the change happened. Microsoft explains the role of import settings in its text and CSV import guide.
If the original CSV is correct but an application displays it differently, do not overwrite the original until you understand the conversion.
Match the symptom to a likely cause
| Symptom | Check first | Try next |
|---|---|---|
| All values appear in one column | The file's actual delimiter | Export a comma-separated CSV or try a clean XLSX file. |
| A description shifts later columns | Commas and quotation marks inside the value | Re-export from the spreadsheet so fields are quoted correctly. |
| Invoice IDs lose leading zeros | Whether the source stored them as text | Restore the verified IDs and export them as text. |
| Names contain broken characters | The file's character encoding | Export a UTF-8 CSV and check the source text again. |
| The PDF contains blank fields | The imported headers and field links | Reconnect renamed or missing columns. |
| Separate invoices become one | The grouping identifier | Use invoice number rather than customer name. |
Fix shifted columns without breaking the file
A comma inside a description or amount needs to stay within that field. In a comma-separated file, double quotes surround a field containing a comma. A quotation mark within a quoted field is represented by two quotation marks.
Invoice #,Customer Name,Description,Total
INV-1001,Avery Johnson,"Consulting, phase 1","$1,250.00"
INV-1002,Maya Chen,"Design ""launch"" package",$860.00
This example has four columns on every row. Let your spreadsheet export the CSV instead of adding or deleting commas manually. Do not replace every comma with another character: some commas belong inside the actual customer data.
Remove title banners, merged header cells, and subtotal rows from the export table. Each column needs a clear, unique name. If the first imported record looks like column labels, check whether an extra heading row was exported above the real headers.
Preserve identifiers, dates, and display values
Identifiers are labels, even when they contain only digits. Store invoice numbers and customer codes as text before entering them when leading zeros matter. If the source already lost digits or rounded a long identifier, go back to a verified source; changing the display format cannot prove what the original value was.
Use unambiguous dates such as 2026-09-17 in a text export, then compare the imported value with the source. For currency, confirm both the number and the intended display. A formatted string such as $1,250.00 is useful for a printed field; keep separate numeric values in your workbook for calculations.
If a CSV shows a formula error or an outdated result, correct and recalculate the workbook before saving the export. For an XLSX file with unexpected formula results, make a values-only copy of the approved data and compare the import again.
When the table is correct but the PDF is wrong
Check which column supplies the incorrect PDF field. A template linked to Total cannot be assumed to follow a later rename to Amount Due. Reconnect the field and regenerate a small output batch.
Next inspect grouping. A customer name is usually not a reliable invoice identifier. If the same client has two invoices, grouping by name can combine unrelated lines. Use a stable invoice number and ensure every row in that group belongs to the same invoice.
For an item table, connect descriptions, quantities, and amounts to the intended line-item columns. An invoice-level total repeated on every row is different from a line total. Check the invoice with the most rows to catch missing or misplaced values.
Retest with one known-good example
Import the LinkoPDF sample CSV in a separate test layout. If that imports correctly, compare its headers, row structure, and quoting with your export. For grouping, use the itemized invoice sample.
After fixing the cause, generate the small test again and compare all fields with the source. Only then use the full billing file. See the invoice CSV format guide for a clean starting structure, or the invoice numbering guide if identifiers are the recurring problem.
