Sigma is a cloud-native analytics platform that gives users instant insights from their Hydra warehouse. Please enjoy this free guide to get started. If you have custom needs that are better served by a professional services partner, our sales team is happy to connect you with a certified data partner.
d. Once the table has been created, upload the .csv by utilizing the following command: \COPY sales_data FROM 'go_daily_sales.csv' DELIMITER ',' CSV HEADER;
You should now have a sales-oriented table populated with approximately 150,000 rows.
part 2. Setup
Creating the Connection
Now we can configure Sigma to access our sample data in Hydra.
Start by creating a trial account, or logging in if you have already done so.
Open your Admin Portal by selecting Administration in the user menu at the top right of your screen.
Select the Connections page from the top left-hand panel.
Click the Create Connection button on the top right.
Choose a name for the connection (we went with hydra-sales_data_2023) and select PostgreSQL as the type of database you'd like to connect to.
Retrieve your database credentials from your Hydra dashboard. You will need Hostname, User, Password, and Database. Keep all other options unchanged. Once all the information has been entered, select Create on the top right.
Once created, you will be able to view the connection details.
Creating Your First Hydra-backend Dashboard
Back on the main page, click Create New on the top left followed by selecting Workbook. You will see a banner entitled DATA ELEMENTS on the toolbar to the left.
Within the aforementioned toolbar, select VIZ followed by clicking on TABLES AND DATASETS. This will bring you to the Hydra database and will show you the available schemas. Your data should exist within the public schema.
Navigate to the aforementioned schema, select sales_data, and then confirm your selection by clicking the button on the bottom right.
Congratulations! You've connected Hydra with Sigma! What next?
Building the Metrics
Now that your data is connected, you're able to utilize your Hydra tables and create insights using Sigma's visualization. Let's experiment with creating the below dashboard showcasing some important KPIs relating to YoY revenue and profit.
Within the dashboard, click the + symbol on the top left.
Navigate to Layouts and click on the layout showcasing two visuals side-by-side (third from the bottom).
Select the left empty visual, and then select sales_data as the table/data source.
Create two new columns, one for Revenue and one for Profit Margin, by clicking the Add Column button on the toolbar to the left.
Revenue: Change the column name to Revenue and enter the following formula onto the formula bar at the top: [Unit Price] * [Quantity].
Profit Margin: Change the column name to Profit Margin and enter the following formula onto the formula bar at the top: ([Unit Price] - [Unit Sale Price]) * [Quantity].
Now that we have the two columns used for these KPI's, let's add them to the metrics. Click on the left empty visual and, from the top left toolbar, change its type from Bar to Single Value.
Drag Revenue into both the Value and Comparison section in the toolbar.
Select the newly added column under Value (should be automatically renamed to Sum of Revenue and change the formula, located in the top-middle, to SumIf([Revenue], Year([Date]) = 2017). Change the formula of the newly added column under Comparison, now entitled Sum of SumIf of Revenue, to SumIf([Revenue], Year([Date]) = 2016).
Rename Sum of Revenue, under Value, to Annual Sales and Format the type to currency by hovering over the column and clicking on the arrow to the right. You should now have something looking like this:
Repeat steps 5-8 for YoY Profit, but use the Profit Margin column instead of Revenue. When adding a new visual, choose Annual Sales as your data source when prompted, as it will include the new columns created in the visual prior.
The Quarterly revenue graph is also made in similar fashion, with the addition of adding a date range and aggregation filter.
Add a new visual.
Change the visual type from Bar to Line.
Drag Revenue into the y-axis, and Date into the x-axis.
On the x-axis toolbar, click on the arrow and navigate to Truncate date. Select Quarter.
Hovering over the data element again, click the arrow and then Filter. Change the filter type from Between to Before, and select December 31, 2017 as the date.
You're now done! Congratulations on creating your first Hydra x Sigma KPI dashboard!
part 3. Tutorial
Integrating Hydra with Sigma
The focus of this guide is to showcase the ease of integrating Hydra with Sigma by developing several KPI metrics based on data within a Hydra database.
To cater to a large audience, the data and KPIs were chosen to be as agnostic as possible. The data used is mock sales data from IBM, and the metrics are the following:
YoY Revenue Growth (card)
YoY Net Profit Growth (card)
QoQ Revenue Growth (time-series line chart)
Your KPIs will likely differ, but this will hopefully serve as a foundation for the development of more metrics.
Ensure you have the details of your Hydra instance handy.