Forum Discussion
Error in queries
- 5 years ago
Anonymous , to me it seems like your date format(system) is mm/dd/yyyy and you are getting the date in dd/mm/yyyy format or vice versa.
If you want to change the setting https://community.powerbi.com/t5/Desktop/How-to-apply-UK-date-format-dd-mm-yyyy-in-Date-slicer/td-p/599712
Or you want to change to the format
in dax
DD/MM/YYYY to MM/DD/YYYY
date(year( right(DD__MM__YY[date],4)), month(mid(DD__MM__YY[date],4,2)) ,day(left(DD__MM__YY[date],2)))
mid(DD__MM__YY[Version_Id],4,2) &"/"& left(DD__MM__YY[Version_Id],2) & "/" & right(DD__MM__YY[Version_Id],4)MM/DD/YYYY to DD/MM/YYYY
date(year( right(DD__MM__YY[date],4)), month(left(DD__MM__YY[date],2)),day(mid(DD__MM__YY[Version_Id],4,2)) )We have the same function as power query too start mid and end, Show in this video
https://www.youtube.com/watch?v=vky4wPqm0O0
Anonymous , to me it seems like your date format(system) is mm/dd/yyyy and you are getting the date in dd/mm/yyyy format or vice versa.
If you want to change the setting https://community.powerbi.com/t5/Desktop/How-to-apply-UK-date-format-dd-mm-yyyy-in-Date-slicer/td-p/599712
Or you want to change to the format
in dax
DD/MM/YYYY to MM/DD/YYYY
date(year( right(DD__MM__YY[date],4)), month(mid(DD__MM__YY[date],4,2)) ,day(left(DD__MM__YY[date],2)))
mid(DD__MM__YY[Version_Id],4,2) &"/"& left(DD__MM__YY[Version_Id],2) & "/" & right(DD__MM__YY[Version_Id],4)
MM/DD/YYYY to DD/MM/YYYY
date(year( right(DD__MM__YY[date],4)), month(left(DD__MM__YY[date],2)),day(mid(DD__MM__YY[Version_Id],4,2)) )
We have the same function as power query too start mid and end, Show in this video
https://www.youtube.com/watch?v=vky4wPqm0O0