Workflow / decision guides
ChatGPT CSV Analysis Looks Wrong? Fix the Input Before the Prompt
Cihan's view: Inspect the header, delimiter, empty rows, and one-record-per-row shape first; ask ChatGPT to report what it loaded before requesting calculations or conclusions.
ChatGPT can analyze a CSV, but a confident answer is not proof that it read the file the way you intended. A shifted delimiter, a blank header, or two tables in one sheet can turn a sensible question into a misleading result.
This is a documentation-based troubleshooting guide with a fictional input and illustrative output. It is not a recorded ChatGPT session or a claim about analysis quality.
The failure pattern
Imagine you upload weekly-orders.csv and ask for the total order value. ChatGPT reports one column called customer;region;units;unit_price instead of four columns, or it says some rows are missing. Do not repair the total in the prompt yet. First make the input visible.
OpenAI’s data-analysis documentation recommends descriptive headers in the first row, one record per row, and plain-language column names. It also says to review generated code, outputs, and assumptions before relying on them. The checks below turn that advice into a small diagnostic artifact.
What you need
- ChatGPT with file upload and data analysis available in your account or workspace. Availability varies by model, plan, and settings.
- A CSV you are permitted to upload. Use the fictional sample first.
- A spreadsheet or text editor for inspecting the original file.
The sample deliberately uses a semicolon delimiter so the problem is easy to see:
customer;region;units;unit_price
Acme Ltd;West;3;120
Northwind;East;2;80
Contoso;West;1;250
If your tool expects commas and you paste this unchanged, the first row may be treated as one header rather than four fields. The exact display depends on how the file is parsed; that is why the diagnostic request comes before any business calculation.
1. Ask for an input report, not an answer
Upload the file and paste this prompt:
Inspect only the attached weekly-orders.csv. Do not calculate revenue or make a business conclusion yet.
Return an input report with:
1. The exact column names you detected.
2. The number of data rows, excluding the header.
3. The delimiter you infer and the evidence for it.
4. The first three rows as a table, preserving values exactly.
5. Any empty headers, empty rows, inconsistent field counts, duplicate headers, or mixed data types.
6. Whether every row appears to represent one order.
Show the code or parsing steps used. Do not silently split, rename, remove, fill, or convert any value. If the file is ambiguous, stop and explain what I should fix outside ChatGPT.
The useful artifact is the input report. It should let you compare the detected structure with the original file before asking for a total.
2. Match the report to the source file
For the fictional sample, an acceptable report should identify four columns, three data rows, and a semicolon delimiter. It should show Acme Ltd, West, 3, and 120 as separate values in the first data row.
These are editor-written acceptance checks, not captured ChatGPT output. If the report shows one wide column, or the rows do not match the source, stop here. Export the file again with a comma delimiter, a single header row, and one order per line. Preserve a copy of the original; do not overwrite it before you know what changed.
A clean version would be:
customer,region,units,unit_price
Acme Ltd,West,3,120
Northwind,East,2,80
Contoso,West,1,250
Re-upload the clean copy and run the input report again. Do not assume that a file extension change repaired the structure.
3. Request the calculation with a reconciliation
Only after the input report passes, use this second prompt:
Using the attached weekly-orders.csv and only the columns you confirmed, calculate line_value = units * unit_price.
Return:
- a row-level table with customer, region, units, unit_price, and line_value;
- the number of input rows used;
- rows excluded and the exact reason for each exclusion;
- the grand total;
- the calculation code or steps.
Do not infer missing values, currency, tax, refunds, customer intent, or performance. Keep the original row identifiers or customer values visible. Mark the result as a review draft, not an approved financial report.
For the clean fictional sample, the illustrative line values are 360, 160, and 250, for a total of 770. These figures are calculated from the sample above, not produced by ChatGPT. Check them independently before using the workflow with real data.
Troubleshooting decision guide
- One wide column: inspect the delimiter. Re-export with the delimiter your spreadsheet and downstream tool both expect.
- Rows appear shifted: look for unquoted delimiters inside customer names or notes. Quote fields that contain the delimiter, then rerun the input report.
- The row count is too low: check for blank lines, merged cells, or a second header. Export a plain rectangular table with one record per row.
- Numbers are treated as text: inspect decimal and thousands separators. Do not ask the model to guess whether
1,250means one thousand two hundred fifty or two values. - The result seems incomplete: OpenAI notes that a file can be too large, complex, image-heavy, or poorly structured for complete analysis. Ask for specific rows, columns, or sections, or split the file into smaller approved files.
- The upload fails: check the current file limits and service status. Do not paste confidential data into a different account just to bypass an upload problem.
Limits and safe use
A correct parse does not make the business conclusion correct. Review formulas, assumptions, exclusions, and generated code. Do not upload customer, employee, financial, or regulated data unless your organization permits that exact environment and retention setting. Use a human owner for decisions involving payments, performance action, compliance, or customer commitments.
TRY / SKIP / USE: TRY this diagnostic on a fictional or approved sample when a CSV result looks suspicious. SKIP asking for totals while the detected columns or row count disagree with the source. USE the calculation only after the input report, reconciliation, and independent arithmetic check pass.
Sources and next step
- OpenAI: Data analysis with ChatGPT
- OpenAI: File Uploads FAQ
- OpenAI: Extracting insights with ChatGPT Data Analysis
- Use ChatGPT to Find Anomalies in a Sample Sales CSV
- Get The Weekly Verdict
Next, apply the same input-first discipline to a real report only after your data owner confirms the upload is allowed.