cancel
Showing results for 
Search instead for 
Did you mean: 
Community Articles
Dive into a collaborative space where members like YOU can exchange knowledge, tips, and best practices. Join the conversation today and unlock a wealth of collective wisdom to enhance your experience and drive success.
cancel
Showing results for 
Search instead for 
Did you mean: 

One of the solution of [FAILED_READ_FILE.NO_HINT] Error while reading file, when display() or SELECT

Yuki
Contributor

One of the solution of [FAILED_READ_FILE.NO_HINT] Error while reading file, when display() or SELECT

I got stuck with the above error when using `spark.read.table().display()` or directly query the table using %sql.

While the display method is just one example, it's likely that this error can occur in other situations as well.

So, the workaround I’m about to share is just one possible solution.

Avoid void type

If a void type exists in a database, it may prevent the data from being displayed, such as when using SQL.

This often happens when using spark.createDataFrame to create a Spark DataFrame from a Pandas DataFrame.

For example, columns that contain only null values may be automatically inferred as void types by Spark. When this happens, the data cannot be displayed.

An even trickier case is when an object-type column contains dictionaries, and the value inside those dictionaries is inferred as a void type. In this case, the same error can occur.

0 REPLIES 0

Join Us as a Local Community Builder!

Passionate about hosting events and connecting people? Help us grow a vibrant local community—sign up today to get started!

Sign Up Now