You can customize a view of your data by creating a data product with a complex query. To create a data product with a complex query, you must create and define an SQL query asset in a project and then add the asset to the data product. By using a complex query, you can create and then drop temporary or transient tables. Complex queries require a Snowflake connection.
- Required roles
- Collaborator roles: Editor or Admin
With complex queries, you can create data products that include Snowflake tables or contain SQL assets that query a Snowflake database. The SQL assets can optionally include a custom parameter set. You can create temporary and transient tables for your query, join them if needed, and then drop them after the query executes.
The first step is to add a SQL asset to a project. Complex queries execute in stages and each stage requires certain SQL commands.
Adding a query to a data product
- From the Data Product Hub navigation menu, click New data product.
- Enter a name for the data product and click the Add from project tile.
- Click Select items and add your query. You can use the advanced filters to locate and add your query quickly from your list of data assets.
- Verify the connections of all assets. To verify a connection, click the connection status and complete the fields by providing credentials. Make sure that you use an appropriate set of credentials as these credentials are used to deliver the data product to consumers following a subscription.
- Click Create draft to confirm your data asset selection. When your draft is successfully created, a static visualization of your data product is generated and viewable by the consumer.
Next steps
After you create your data product draft, see Completing a data product to finish preparing your data product for publication.
Learn more
Parent topic: Creating a data product