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
k-squared
Frequent Visitor

Maximum length of column name while using DirectQuery

I have a large SQL table in Snowflake where the column names are automatically generated and am having trouble using some, but not all of the volumns, in Power BI Desktop visuals, meaning I cannot, for instance, pull one of the columns into a Matrix to see the values.

One requirement is that I must use DirectQuery given the large size of the table. I also have Tableau and have noticed it is able to pull the same column data in without a problem so do not think there's an issue with the underlying SQL table. 

Whenever I try to pull the problem fields in, I get the following error: 

"Couldn't load the data for this visual"

Error message says "OLE DB or ODBC error: The command '[embedded SQL statement here]' isn't supported.."

I have found this appears to happen when column names exceed 128 characters. Is there a hard limit on the number of characters a column name can have? If so, is there a reason why this limit is so low? 

1 ACCEPTED SOLUTION
k-squared
Frequent Visitor

Yes, that's what I ended up doing for now (though I did it on the SQL end to preserve consistency across files/applications) but not an ideal solution.

View solution in original post

2 REPLIES 2
k-squared
Frequent Visitor

Yes, that's what I ended up doing for now (though I did it on the SQL end to preserve consistency across files/applications) but not an ideal solution.

amitchandak
Super User
Super User

@k-squared , You can rename the column in power bi. the source name will remain the same.

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
April Power BI Update Carousel

Power BI Monthly Update - April 2026

Check out the April 2026 Power BI update to learn about new features.

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.