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

Level up your Power BI skills this month - build one visual each week and tell better stories with data! Get started

Reply
Khalid1988
New Member

Seeking Advice on Bracket Usage in Semantic Model

Hi everyone,

I'm working on a new Semantic Model, and I wanted to share something I'm encountering. The names of the measures and columns in the model are formatted like this: `Production [Kwh]`, with spaces and square brackets.

Whenever I try to use these measures or columns in scripts, I often have to add more brackets than expected. For example:

```DAX


Branch1Prod = CALCULATE(
Production [Kwh],
Branch[branch [no]]] = "Branch1"
))
```

The engine forces me to add the extra red bracket, and then the measure doesn't work properly.

Could this issue be related to the use of brackets in the names of columns and measures, or might it be something else?

Thanks!

 

1 ACCEPTED SOLUTION
uzuntasgokberk
Super User
Super User

Hello @Khalid1988,

 

In the DAX syntax, you have to use ]] in order to reference a single ] in a measure name.

 

    CALCULATE(
        SUM(Efficient[Consumption [kWh/t Product]]]),
        FILTER(Efficient,
            Efficient[Consumption [kWh/t Product]]] > 50
            )
          )

 

İf your measure doesn't work properly that you mean the output of measure values are wrong. Probobly you need to check validation values or whether you wrote metric correctly or not

Kind Regards,
Gökberk Uzuntaş

📌 If this post helps, then please consider Accepting it as a solution and giving Kudos — it helps other members find answers faster!

🔗 Stay Connected:
📘 Medium |
📺 YouTube |
💼 LinkedIn |
📷 Instagram |
🐦 X |
👽 Reddit |
🌐 Website |
🎵 TikTok |

 



View solution in original post

2 REPLIES 2
Krina234pestro
New Member

Hello,

You are sharing some advice on DAX syntax, specifically about referencing a single ] in a measure name. Here’s a cleaner version of your DAX code snippet: CALCULATE(
SUM(Efficient[Consumption [kWh/t Product]]),
FILTER(Efficient,
Efficient[Consumption [kWh/t Product]] > 50
)
)

If the measure isn’t working correctly, it might be due to validation issues or incorrect metric maximtimeclock references. 

 

Hope that helps. 

uzuntasgokberk
Super User
Super User

Hello @Khalid1988,

 

In the DAX syntax, you have to use ]] in order to reference a single ] in a measure name.

 

    CALCULATE(
        SUM(Efficient[Consumption [kWh/t Product]]]),
        FILTER(Efficient,
            Efficient[Consumption [kWh/t Product]]] > 50
            )
          )

 

İf your measure doesn't work properly that you mean the output of measure values are wrong. Probobly you need to check validation values or whether you wrote metric correctly or not

Kind Regards,
Gökberk Uzuntaş

📌 If this post helps, then please consider Accepting it as a solution and giving Kudos — it helps other members find answers faster!

🔗 Stay Connected:
📘 Medium |
📺 YouTube |
💼 LinkedIn |
📷 Instagram |
🐦 X |
👽 Reddit |
🌐 Website |
🎵 TikTok |

 



Helpful resources

Announcements
Fabric SQL PBI Data Days

Data Days 2026 coming soon!

Sign up to receive a private message when registration opens and key events begin.

New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.