> For the complete documentation index, see [llms.txt](https://docs.dataexport.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.dataexport.io/faq/reports.md).

# Data Export Reports FAQ: Common Report Questions

Answers to common Data Export report questions: draft orders, payouts, timeline comments, CASE statements, tax reports, and best-selling products.

### Data Export Reports FAQ

This page answers common questions about reports in Data Export, including draft orders, payouts, timeline comments, calculated fields, tax reports, and best-selling products. Each answer explains what to do in the app, and where to get help if you need it.

#### Why are my reports not showing draft orders?

Sales and order reports only show real orders, which are orders marked as pending or paid. Draft orders are left out on purpose. If they were mixed in, your sales totals would be wrong.

To see draft orders, turn on draft order sync:

1. Open **Settings**.
2. Select the **Data Management** tab.
3. Switch on **Draft Orders Sync**.

Once the sync is done, open a report from the **Draft Order** category.

#### Can I see payouts in my sales report?

No. Sales reports do not include payout fields. To see your payout data, use the **Payout** or **Payout Line Items** report types. You can find them in the **Shopify Payments & Payout** category.

#### Which field shows timeline comments?

Timeline comments are saved as order events. To get them in your reports:

1. Open **Settings**.
2. Select the **Data Management** tab.
3. Switch on **Events Sync**.
4. Once the sync is done, [contact us](https://dataexport.io/contact/) and we will add a timeline comments field to your report.

#### Which language do I use to write calculated fields?

Calculated fields use PostgreSQL. You can use it to do math with your fields, compare values, work with dates, and write CASE statements. To learn more, see How to Create a Calculated Column.

#### How do I write a CASE statement?

A CASE statement checks conditions in order and returns a value for the first one that is true. It works like an “if this, then that” rule.

* Once a condition is true, it stops checking and returns that result.
* If no condition is true, it returns the value in the **ELSE** part.
* If there is no ELSE part and no condition is true, it returns an empty value (NULL).

**Syntax**

```
CASE
  WHEN condition1 THEN result1
  WHEN condition2 THEN result2
  WHEN conditionN THEN resultN
  ELSE result
END
```

**Example:** Label each order by size based on its total sales.

```
CASE
  WHEN [Total Sales] >= 1000 THEN 'Large'
  WHEN [Total Sales] >= 100 THEN 'Medium'
  ELSE 'Small'
END
```

| Total Sales | Result |
| ----------- | ------ |
| 1500        | Large  |
| 450         | Medium |
| 60          | Small  |

Put the biggest value first. Since CASE stops at the first true condition, an order of 1500 is labeled Large and never reaches the Medium check.

#### Can I add metafields or line item properties to my report?

Yes. You can add them yourself with **Custom Properties**, with no formula needed. You can add order, product, customer, variant, and collection metafields, as well as line item properties and note attributes. To learn how, see How to Add Order Line Item Properties to Your Report.

#### Can I see tax collected by county, city, and state?

Yes, if your Shopify store is set up to collect tax at those levels. Data Export pulls the tax data that Shopify collects, which is based on your store’s tax settings and the delivery address of each order. If your store does not collect tax by county, city, or state, that data will not be in your report.

To see your tax data, open a report from the **Tax Collected** category.

#### How do I see my best-selling products with their variant, SKU, vendor, and product type?

There are three ways to get this report:

1. **Use a pre-made report.** Open the **Best Selling Products** report in the **Product & Variants** category. Add any extra columns you need, such as Variant, SKU, Vendor, or Product Type, then click **Save**.
2. **Build your own report.** Create a custom report, choose the fields you need, sort by sales from largest to smallest, and save it. To learn how, see How to Create a Custom Report.
3. **Ask our team.** [Contact our support team](https://dataexport.io/contact/), and we will set up the report for you.

#### Have a question not answered here?

[Contact us](https://dataexport.io/contact/), and our support team will help you.
