Can please help me with the powerbi issue?
I am creating a report to count an age that will be calculated using today date by default of by the slicer in DAX. Therefore, I need to use Dynamic M Query parameters. This is the article about it. Dynamic M query parameters in Power BI Desktop (preview) - Power BI | Microsoft Docs
This bind to parameter option only can work on the direct query in the power query. Which has restriction to use the data type transformation. Therefore, I need to specify the preferred data type at the beginning of column creation that is using my parameter (p_Created_Date). This parameter will be linked to the slicer using the binding to parameter option at DAX. The formulation of the new column is:
= Table.AddColumn(#"Reordered Columns", "Age", each (if [Closed] = null then p_Created_Date else [Closed]) - [Opened], Int64.Type)
The calculation result for this column in Power Query is:
The Age column of the first row will be displayed at DAX using card visualization but somehow the value become like this instead of 14.
Anyone know know what is wrong and how to fix this?