cancel
Showing results for 
Search instead for 
Did you mean: 
Data Engineering
Join discussions on data engineering best practices, architectures, and optimization strategies within the Databricks Community. Exchange insights and solutions with fellow data engineers.
cancel
Showing results for 
Search instead for 
Did you mean: 

Liquid clustering with boolean columns

Karin
New Contributor II

Hi community 👋

Is it possible to use boolean columns as cluster keys for liquid clustering on Delta Tables? 

I've been trying to set a boolean column as cluster key since it's one of my most common queries when reading from the table. I'm getting the error "DeltaAnalysisException: Liquid clustering requires clustering columns to have stats. Couldn't find clustering column *boolean_column_name* in stats schema" - which doesn't make sense since I've made sure to collect statistics on all columns (delta.dataSkippingNumIndexedCols = -1) and can see stats on the boolean columns as well. 

I came across this post by Miles Cole, saying that it's not possible to have boolean data types as clustering keys but it's not stated anywhere in the official documentation. 

Any input is appreciated! 

1 ACCEPTED SOLUTION

Accepted Solutions

jeroenvs
New Contributor III

Can confirm that boolean columns are note allowed for liquid clustering. This seems to be undocumented and the error message is not helpful: "couldn't find clustering column in stats schema"

View solution in original post

1 REPLY 1

jeroenvs
New Contributor III

Can confirm that boolean columns are note allowed for liquid clustering. This seems to be undocumented and the error message is not helpful: "couldn't find clustering column in stats schema"

Connect with Databricks Users in Your Area

Join a Regional User Group to connect with local Databricks users. Events will be happening in your city, and you won’t want to miss the chance to attend and share knowledge.

If there isn’t a group near you, start one and help create a community that brings people together.

Request a New Group