Create a new Report
How to create a new report?
Section titled βHow to create a new report?β- Click on Analyze from the navigation bar and navigate to Reports .
- Click on β+ Create Reportβ to create a new report.
- On the Build Report Using page - Choose SQL Editor, to build detailed reports using the SQL Queryβs Output table using your data warehouse tables.
- Report info popup will appear and click on the βStart Building Reportβ
- The Create Reports form opens up. Give a name to your report.
- SQL Reports Builder window will open up in Edit Mode where you can write your SQL code to get the desired data.
- By default, the result/output of your SQL query is visualized as a Table.
- You may choose from other visualization options from the visualization selector dropdown appearing just below the SQL Editor.
- After running the SQL code in SQL Editor you may go to the Visualization tab on the left-hand side and choose the relevant Visualization (by default it will be Table) to enhance your data storytelling.
- Add/ Drop the table output columns obtained from running the SQL query in SQL Editor into the relevant sections under the Visualization tab.
- Click on Visualize button and your report will be ready.
Build a Report using SQL Editor
Section titled βBuild a Report using SQL EditorβLetβs say you have an Order_details raw table which you need to modify first using some SQL query and then use the final table to perform some analysis like βProduct Category wise Total Ordersβ.
- Click on β+ Create Reportβ and choose SQL Editor.
- Give a name to the Report and now you will land on the Report -SQL Editor UI.
- Now in the SQL Editor tab write the SQL query which you want to use to modify the Order_details table and click the Run button.
For eg: If you want to analyze only the North region orderβs data and also want to combine order_id and location_id columns to create a new column tracking_id then you can write the following Code
Select a.*, concat(a.order_id,'-',a.location_id) as tracking`` id
from orders_details
where a.region ='North';
- You will now have a final table as the Output of the above SQL query.
- Now go to the Visualization Tab below the Schema Browser tab and choose the Pie Chart option.
- In the Build panel go to the Chart Setting section and select Measure column Count of Order_id in the Values section and select Product Category column in the Labels section.
- Click on the Visualize Button and your Pie Chart will be ready showcasing βProduct Category wise Total Ordersβ for only the North region as you require.
.png)
Product Category wise Total Orders
Note: SQL Reports in the new version is an update from the SQL Explores legacy feature.