> For the complete documentation index, see [llms.txt](https://help.qtech.co.nz/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.qtech.co.nz/datran/datran-vi-scada/datran-reporting/create-reports.md).

# Create and run reports

Design a report with the report designer and query wizard, then print, archive, export, email or delete it from the Report Explorer.

DATRAN Reporting v6 is built on a new “ReportBuilder” engine which provides significant improvements to the user interface and speed of report generation.

{% hint style="info" %}
**Applies to:** DATRAN Reporting V6.x. These templates give you some “out of the box” functionality and provide a solid base for developing your own reports. See [Report templates and examples](https://help.qtech.co.nz/datran/datran-vi-scada/datran-reporting/templates.md).
{% endhint %}

## The main window

* **Report Explorer:** from here you can browse the existing reports and also preview, print, save, email or send to a FTP server an existing report in various different file formats.
* **Scheduled Reports:** from here you can add, change or remove a schedule for any of the existing reports. See [Schedule, email and FTP reports](https://help.qtech.co.nz/datran/datran-vi-scada/datran-reporting/schedule.md).
* **Settings:** Settings view allows you to set the following system configurations: DATRAN Database, Utility to Start, Stop and Restart DATRAN Reporting Services, Launch Windows Event Viewer, Launch Windows Services, Manually Add New Analogue View, Change Program Options.

The application scales and fits to any size screen as all the aspects on the schedule window scale appropriately allowing maximum viewable space at all times. Minimizes to a tray icon when main form is hidden.

## Create a report

1. Click on the main menu and select **File > New > Report** or just click the new report button.
2. In the ReportBuilder Enterprise: New Report window, click on **Data** tab.
3. Click on the **File** menu and select **New**.
4. Choose the **Query Wizard** and click the **OK** button.
5. Double click on **Analogues View** to choose that (virtual) table.
6. Click on the **Next >** button.
7. Ensure that the selection is on **All Fields**. This will determine that all the fields in the tables are chosen.
8. Click on the **Next >** button.
9. Ensure that the selection is on **No Calculations**. We will skip this for this simple example.
10. Click on the **Next >** button.
11. Ensure that the selection is on **No Grouping**. We will skip this for this simple example.
12. Click on the **Next >** button.
13. Click on the **Define Search Criteria** radio button.
14. Right click on the Criteria list box and select **Insert Criteria**.
15. In the Field combo box, select **Analogues View\.Point Name**.
16. In the Operator combo box, select **Like**.
17. In the Value text box, type in "%pump%run%". This will include any points that have the word 'pump' followed by 'run' in it regardless of case.
18. Click on the **OK** button.
19. Repeat the last 5 steps for these additional criteria:
    * Analogues View\.Log Time >= 01/01/01
    * Analogues View\.Log Time <= 07/01/01
20. Click on the **Next >** button.
21. Click on the **Set Order** radio button.
22. Select the fields by double clicking on them in this order:
    * Analogues View\.Station Name
    * Analogues View\.Point Name
    * Analogues View\.Log Time
23. Click on the **Finish** button.
24. Notice that the Analogues\_View query appears within the **Data** tab.
25. Click on the **Design** tab.
26. Click on the **DBText** button on the Data Components toolbar.
27. Click on the **Detail** section.
28. Notice that a DBText will be placed there.
29. Use the Edit toolbar to select the source of the data. For the first one, select **Station Name**.
30. Repeat the previous 4 steps for **Point Name**, **Log Time** and **Value**.
31. Click on the **Preview** tab to get a preview of the report.
32. Close the ReportBuilder Pro and save the report as "Pump Run".

For the views and tables you can report on, see [Database tables and views for reports](https://help.qtech.co.nz/datran/datran-vi-scada/datran-reporting/database-views.md).

## Run a report with a date range

If the Search dialogue box comes up, enter the required values and click **OK**. A new calendar makes it easier and faster to select the required date range.

## Print a report

1. Click on the folder where the report is located.
2. Click on the report that you want to print.
3. Click on the main menu and select **File | Print**.
4. Make the required changes to the Search dialogue box if one appears.
5. Make the required changes to the Print dialogue box.
6. Click on the **OK** button in the Print dialogue box.

## Save a report to a file

In the main menu, select **File | Print To File...** In the Choose a Report Type dialogue box, select the type:

| Type                                         | Gives you                                                                                                                                                                                                                                                                                                                                                    |
| -------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| Archive file (`.raf`)                        | Archive reports contain both the data and also the formatting of the report seen on the screen. This is so that you do not need to regenerate the report especially if the report takes a long time. To view an archived report, click on the main menu and select File, then select Open Archive File... It is usually saved with a RAF extension (\*.RAF). |
| CSV or ASCII text                            | Reports in this format contains only the data and do not contain any of the formatting seen on the screen. This is useful when data within the report is used for further analysis.                                                                                                                                                                          |
| Report emulation text, PDF, RTF, Word, Excel |                                                                                                                                                                                                                                                                                                                                                              |
| BMP, GIF, JPEG, EMF                          |                                                                                                                                                                                                                                                                                                                                                              |

If the Search dialogue box appears, enter the required values for the parameters and click **OK**. Specify a location where the file will be saved. Click on the **OK** button. Remember the path where the last file was printed to. Automatically open a report that was manually printed to file.

## Email or FTP a report now

* **Email:** In the main menu, select **File | Send File...** If you have not configured your Simple Mail Transfer Protocol (SMTP) connection login, do so via the main menu **Tools | Options...** See [Set up email](https://help.qtech.co.nz/datran/datran-vi-scada/datran-reporting/schedule.md#set-up-email).
* **FTP:** In the main menu, select **File | Transfer As File...** If you have not configured your File Transfer Protocol (FTP) connection login, do so via the main menu **Tools | Options...** See [Set up FTP](https://help.qtech.co.nz/datran/datran-vi-scada/datran-reporting/schedule.md#set-up-ftp).

## Delete a report

1. Click on the folder where the report is located.
2. Click on the report that you want to delete.
3. Click on the main menu and select **File | Delete** or click on the Delete button.
4. Click on the **Yes** button at the "Are you sure you want to delete '\<Report Name>'?" prompt.

This action will move the report into the Recycle Bin folder. You can retrieve the report at a later time. If the Recycle Bin is emptied while the report is in it, the report will be permanently deleted.

## Enter values by hand

Allows manual entry of analogue values.
