Simon Lejeune
03/23/2023, 11:37 AMcurl --request POST 'https://{ENDPOINT}/api/v1/entities/workspaces/{WORSKPACEID}/metrics' --header 'Content-Type: application/vnd.gooddata.api+json' --header 'Authorization: Bearer {TOKEN}' --data @- <<'EOF'
{
"data": {
"attributes": {
"title": "mytitle",
"description":"",
"content": {
"format": "#,##0",
"maql": "SELECT SUM({fact/{COLUMNNAME}}) BY {dataset/{TABLENAME}"
}
},
"id": "{COLUMNNAME}",
"type": "metric"
}
}
EOF
If I create the same metric with the editor (in the browser, by copy pasting the MAQL query and selecting the rounding), then it is working fine.
Is this a bug, am I missing something?
Thanks in advanceIvana Gasparekova
03/23/2023, 2:55 PMSimon Lejeune
03/23/2023, 3:03 PMSELECT SUM({fact/sbuyornot__secondprod____sjourney__accessories}) BY {dataset/feedbacks}
here are two screenshots: first one is created through the api and second one manuallySimon Lejeune
03/23/2023, 5:31 PMIvana Gasparekova
03/28/2023, 12:21 PM