Playground is a web-based tool which allows executing queries and previewing their results.
Playground is available in Cube Cloud on all tiers (opens in a new tab).
Cube Core and Cube Cloud both provide the Playground experience; however, a few additional features are available in Cube Cloud.
Playground is available out of the box to authenticated Cube Cloud (opens in a new tab) users.
When editing the data model through the data model editor, Playground will switch to the Development API and its status will be visible in Playground:
You can use query tabs to keep results of previous queries while still being able to make new queries. The query tabs can be found at the top of the Developer Playground:
You can also double-click a query tab to give it a meaningful name:
The security context used for queries can be modified by clicking Add Security Context:
You can paste in an existing JWT if desired; or create a brand-new one by providing a JSON object that represents the decoded JWT.
To see the SQL generated by a query, click Generated SQL:
If you're using Cube Cloud, you can copy this SQL and run it in your data source using the SQL Runner.
The Rollup Designer provides an easy way to create and edit pre-aggregations from within the Playground. For example, when you execute a query that has no matching pre-aggregations, the Playground also displays some information above the results:
Clicking Query was not accelerated with pre-aggregation will open the Rollup Designer with a suggested pre-aggregation that will accelerate the query:
Click Add to the Data Schema to add the pre-aggregation to the data model. You can then run the query again to see the results: