Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
I am trying to create a column that takes a date in mm/dd/yyyy and turns it into YearMonth. (The name of the column that I am working with is 'Procedure Request Form'[Date Request Submitted])
For example:
09/14/2001
10/15/2002
11/16/2003
will become
200109
200210
200311
I have tried using LEFT and RIGHT, but it doesn't work
Solved! Go to Solution.
oh....!!! This should work now. 🙂
Column = IF(ISBLANK('Table'[Column1]),BLANK(),FORMAT(DATEVALUE('Table'[Column1]),"YYYYMM"))
Best Regards,
Samarth
If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
Connect on Linkedin
I used DATEVALUE, and I still get an error.
@i820017 Please try this:-
Column =
var result = FORMAT(DATEVALUE('Table'[Column1]),"YYYYMM")
return IF(ISBLANK(result),BLANK(),result)
Best Regards,
Samarth
If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
Connect on Linkedin
I justs did that, and I am still getting the same error.
oh....!!! This should work now. 🙂
Column = IF(ISBLANK('Table'[Column1]),BLANK(),FORMAT(DATEVALUE('Table'[Column1]),"YYYYMM"))
Best Regards,
Samarth
If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
Connect on Linkedin
This worked...thanks!!
I am still getting an error.
This is weird because Date Request Submitted is a Date as seen below.
Hi @i820017 ,
How about this:
YearMonth = FORMAT ( Table[Date], "YYYYMM" )
Does this solve your issue? 🙂
/Tom
https://www.tackytech.blog/
https://www.instagram.com/tackytechtom/
Did I answer your question❓➡️ Please, mark my post as a solution ✔️ |
Also happily accepting Kudos 🙂 |
Feel free to connect with me on LinkedIn! | |
#proudtobeasuperuser | |
Hi @i820017
You can create a column this way, Column = FORMAT ([Date Request Submitted], "YYYYMM" )
And you will get the desired result.
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
72 | |
68 | |
53 | |
39 | |
33 |
User | Count |
---|---|
70 | |
63 | |
57 | |
49 | |
46 |