Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Mann
Resolver III
Resolver III

SUMMARIZECOLUMNS with a formatting changed

Hi Guys,

 

I created a simple query to give me list of dates available in Date column in one of my AAS table. I used "Order By" to sort it and used this query result in Power BI paginated report as follows:

EVALUATE 
SUMMARIZECOLUMNS('Table1'[Date])
		ORDER BY 'Table1'[Date] DESC

I am getting results in "MM/DD/YYYY hh:mm tt"

 

I need to get results in "MM/DD/YYYY" format.

 

How can I change the above query to give me results in "MM/DD/YYYY" format with Summarizecolumns.

 

Thanks

1 ACCEPTED SOLUTION

I achieved this in the query by this:

 

 

EVALUATE
VAR _TempTable= SUMMARIZECOLUMNS ( 'Table1'[Date] )
Return
SELECTCOLUMNS(_TempTable,"Date",FORMAT([Date], "DD MMM YYYY"))
order by [Date] desc

 

View solution in original post

3 REPLIES 3
jdbuchanan71
Super User
Super User

@Mann 

You should just be able to change the formatting on the column of your new table in the model and it will appear correctly wherever it gets used.

@jdbuchanan71 

I tried chnaging the formatting of this column to "MM/DD/YYYY" in AAS but when this query is used as a dataset in Power BI Paginated report it shows "MM/DD/YYYY hh:mm tt"

 

So I am thinking of changing the query in a way to give me "MM/DD/YYYY" only.

 

Thanks

I achieved this in the query by this:

 

 

EVALUATE
VAR _TempTable= SUMMARIZECOLUMNS ( 'Table1'[Date] )
Return
SELECTCOLUMNS(_TempTable,"Date",FORMAT([Date], "DD MMM YYYY"))
order by [Date] desc

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.