Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Get Fabric certified for FREE! Don't miss your chance! Learn more
In Power Query,
I am trying to use Power Query to general a Fiscal Year.
Eg. If April 1, 2022, then Fiscal Year is FY22/23
Here is my Custom Column Formula:
if [Month] ❤️ then "FY" &
Text.End(Number.ToText([Year]),2) & "/" &
Text.End(Number.ToText([Year],2) else
"FY" &
Text.End(Number.ToText([Year]),2) & "/" &
Text.End(Number.ToText([Year}+1,2)
Result: Token Comma expected. When I click Show Error, it highlights "else."
How do I fix this?
Thanks.
Solved! Go to Solution.
Hi @BAFreedom ,
I think you have few typos there. There is bracket missing + one bracket ) is }.
Check my code:
if [Month] ❤️ then "FY" &
Text.End(Number.ToText([Year]),2) & "/" &
Text.End(Number.ToText([Year],2)) else
"FY" &
Text.End(Number.ToText([Year]),2) & "/" &
Text.End(Number.ToText([Year]+1,2))
Hi @BAFreedom ,
I think you have few typos there. There is bracket missing + one bracket ) is }.
Check my code:
if [Month] ❤️ then "FY" &
Text.End(Number.ToText([Year]),2) & "/" &
Text.End(Number.ToText([Year],2)) else
"FY" &
Text.End(Number.ToText([Year]),2) & "/" &
Text.End(Number.ToText([Year]+1,2))
Thank you
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
Check out the January 2026 Power BI update to learn about new features.
| User | Count |
|---|---|
| 68 | |
| 59 | |
| 47 | |
| 20 | |
| 15 |
| User | Count |
|---|---|
| 106 | |
| 102 | |
| 38 | |
| 27 | |
| 27 |