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: 

Importing JSON files when format is subject to evolution

etum
New Contributor II

Hi there,

I'm reaching out for some assistance with importing JSON files into Databricks. Still a beginner even if I've gained experience working with various data import batches (CSV/JSON) for application monitoring:  I'm currently facing a challenge with a specific JSON data set.

The structure of this JSON file has evolved over the past year, with new fields being added. As a result, our current Python code using inferSchema to automatically detect the format is encountering errors during import.

I've explored several approaches to handle schema evolution, including concepts like schema merging, but haven't yet found a solution that works consistently. I believe I'm close to a solution, but I'm running into some roadblocks.

Any insights or suggestions you might have on handling evolving JSON schemas during import would be greatly appreciated.

Thanks in advance for your help!

1 REPLY 1

Kaniz_Fatma
Community Manager
Community Manager

Hi @etum

To ensure we provide you with the best support, could you please take a moment to review the response and choose the one that best answers your question? Your feedback not only helps us assist you better but also benefits other community members who may have similar questions in the future.

If you found the answer helpful, consider giving it a kudo. If the response fully addresses your question, please mark it as the accepted solution. This will help us close the thread and ensure your question is resolved.

We appreciate your participation and are here to assist you further if you need it!

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