Hi Team, I want to get the min date in GoodData. H...
# gooddata-cloud
c
Hi Team, I want to get the min date in GoodData. How to make it shown as a date. I made the metric below and the link is 10. Product Performance - GoodData Cloud
k
Getting MIN Date to Display as a Formatted Date I can see your metric
Start Date (Game)
is using:
Copy code
SELECT MIN(EGM Effective From - Date {label/effective_to.day})
Unfortunately, this is a known platform limitation. MAQL metrics always return numeric values — so
MIN(date)
will return an internal numeric representation (e.g.,
2022
) rather than a readable date like
17/10/2022
. Date formatting for metric outputs is not currently supported. [Community Slack] What You Can Do 1. Recommended: Handle it upstream in your data source Compute the minimum/start date as a proper date column in your ETL/SQL layer, then expose it as a date dimension or attribute in GoodData's Logical Data Model. This is the most reliable approach. [Community Slack] 2. Use MIN(date) for filtering, not display The supported pattern is to use
MIN(date)
inside a
WHERE
clause to filter another metric, rather than displaying it directly. For example: [MIN docs]
Copy code
SELECT SUM({fact/snapshot_value}) 
WHERE {attribute/snapshot_date.day} =
      (SELECT MIN({attribute/snapshot_date.day},{dataset/fact_dataset}))
3. Display the date as an attribute instead Rather than using a metric, add the date dimension directly as an attribute in your visualization (drag the Date field into Rows/Columns or View by). Date attributes do display in proper date format (e.g.,
MM/DD/YYYY
by default), and you can change the display format via your localization settings. [Change Date Format] Summary GoodData's product team is aware of this limitation and date formatting for metrics is on their roadmap, but it is not yet available. [Community Slack] 👍 0 button 👎 0 button â„šī¸ Tip: Mention @kapa.ai in the thread for follow-ups. 👀 Our Support team monitors all messages and will jump in if needed., with interactive elements