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

The Power BI Data Visualization World Championships is back! It's time to submit your entry. Live now!

Reply
Anonymous
Not applicable

Column '' in Table '' contains blank values and this is not allowed for columns on the one side of a

Error I get: "Column '' in Table '' contains blank values and this is not allowed for columns on the one side of a many-to-one relationship or for columns that are used as the primary key of a table."

 

The formula is:

DateFormatted = if( [DATE] = today(),blank(),[Date])
 
It worked before. What is wrong?
1 ACCEPTED SOLUTION
Ritaf1983
Super User
Super User

Hi @Anonymous 
The problem is here :
DateFormatted = if[DATE] = today(),blank(),[Date])
blanks could not be used as a primary key.
You can have the wanted column but not to use it for creating relationship

If this post helps, then please consider Accepting it as the solution to help the other members find it more quickly

 

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

View solution in original post

2 REPLIES 2
Kedar_Pande
Super User
Super User

@Anonymous 

DateFormatted = 
IF(
[DATE] = TODAY(),
BLANK(),
IF(
NOT(ISBLANK([DATE])),
[DATE],
DATE(9999, 12, 31) // Or any placeholder date that suits your model
)
)

By using this adjusted formula, you can maintain the integrity of your model without generating blank values where they're not allowed.

 

💌 If this helped, a Kudos 👍 or Solution mark would be great! 🎉
Cheers,
Kedar
Connect on LinkedIn

Ritaf1983
Super User
Super User

Hi @Anonymous 
The problem is here :
DateFormatted = if[DATE] = today(),blank(),[Date])
blanks could not be used as a primary key.
You can have the wanted column but not to use it for creating relationship

If this post helps, then please consider Accepting it as the solution to help the other members find it more quickly

 

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! It's time to submit your entry.

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.