Analyzing an Excel File with ChatGPT: From Transactions to Insights
Turn an Excel file full of transactions into actionable insights without coding: upload the file, assign a role and validate every result before deciding.
ChatGPT can turn an Excel file full of transactions into actionable insights without requiring programming skills. The workflow has three parts: upload the file, assign the model a role, and validate every result before making business decisions. The example is a real e-commerce sales report.
The dataset used in the exercise
- Excel report of e-commerce sales in USD.
- Contents: sales by month, revenue and average ticket size value.
- Volume: 1,000 products, 1,000 customers and 99,000 transactions.
- Intentional error: a formula that fails in Excel but works in Google Sheets.
1. Load the file and give context
- Click the plus icon in ChatGPT and attach the file.
- Write an instruction that includes a role.
- ChatGPT shows a preview of the file, its sheets and how it interprets each table.
Act as a data analyst, read the Excel file and tell me what you find.2. Try different roles
Assigning a role focuses the type of analysis and changes the angle of the conclusions. Roles to try: data analyst (works well for reports), data scientist, marketing expert, sales expert. The rule of thumb: the role shapes the perspective of the answer, so choose it based on the decision you need to make.
3. How ChatGPT actually analyzes data
LLMs are not good at math. Their purpose is to understand language and generate text. The workaround: the model writes programming code, executes it, and uses the output as its answer. If you can program, you can read the generated code and learn from it; if you cannot, you don't need to understand the code, only to know this is how the calculations are done.
If the model gets stuck "thinking," click the pause icon, then "try again" to retry with GPT-5.
A typical initial analysis returns:
- Data structure.
- Data quality.
- Detected columns.
- Main KPIs.
- Trends.
- Rankings.
- Anomalies.
- Suggested next steps.
4. Charts: generate and validate
Create a sales trend chart for 2024.The model can produce a chart in two ways: by generating an image, or by building the chart from code (closer to what you would make in Excel).
What went wrong in the exercise: the model returned a trend based on record count, which did not match the real sales chart. The cause was an ambiguous prompt: the model found no column named "sales," so it searched for alternatives such as billing or subtotal.
5. Avoid ambiguous prompts
When a prompt is ambiguous, the model improvises and picks columns it considers relevant. The fix is to be explicit from the first instruction: name the sheet (for example, the transactions sheet), the exact column (for example, revenue) and the operation (sum, average, count).
Show me the sales trend for 2024.Using the transactions sheet, sum the revenue column by month for 2024 and plot it as a line chart.Practice challenge
You are the chief marketing officer of the e-commerce company. Using the product, customer and transaction data, decide where to invest the budget next month to grow sales. Recommended approach:
- Define a clear role (data analyst, data scientist, marketing or sales expert).
- Specify exact columns and metrics (for example, revenue in transactions).
- Request charts that support the decision.
- Use prompt chaining (linking several prompts in sequence) when the analysis requires it.
When done, share the prompt you used, the role assigned, the constraints you set, where you would invest, and the prompt sequence if you built a chain.
Key takeaways
- Upload the file and give the model a role to frame the analysis.
- ChatGPT reads values, not formulas.
- LLMs handle math by generating and running code.
- Always validate outputs, especially charts.
- Ambiguity causes wrong metrics: always specify sheet + column + operation.
- Use prompt chaining for multi-step analysis.