Piotr Kardaś
03/01/2023, 11:22 AMSELECT {metric/revenue} - {metric/revenue_baseline}
and I would like to get a full PostgresSQL statement which would be executed on the database when I use this metric. Something like
SELECT my_table.revenue - my_table.revenue_baseline FROM my_db.my_table
Is it possible?Ivana Gasparekova
03/01/2023, 11:47 AMPiotr Kardaś
03/01/2023, 11:49 AMPiotr Kardaś
03/01/2023, 11:50 AMmetrics = sdk.catalog_workspace_content.get_metrics_catalog(workspace_id=workspace_id)
but it does not seem like I could get what I want using CatalogMetric object (i don’t see any SQL formula definition easily accesible)Jan Soubusta
03/01/2023, 12:05 PMedit
with debug
in insight URL
Metric Editor:
• when you turn a feature flag on, it provides a completely new experience allowing you to execute metrics, view SQL , data preview, and even slice metrics by attributes
• In gooddata-cn-ce I turn the feature flag like this:
environment:
GDC_FEATURES_VALUES_ENABLE_METRIC_SQL_AND_DATA_EXPLAIN: 'ENABLED'
Jan Soubusta
03/01/2023, 12:06 PMPiotr Kardaś
03/01/2023, 1:38 PMPiotr Kardaś
03/01/2023, 2:31 PMtable_name_YYYY_MM_DD
. For that reason I am able to create metrics for individual partitions only.Jan Soubusta
03/01/2023, 4:29 PM