cancel
Showing results forย 
Search instead forย 
Did you mean:ย 
Community Discussions
Connect with fellow community members to discuss general topics related to the Databricks platform, industry trends, and best practices. Share experiences, ask questions, and foster collaboration within the community.
cancel
Showing results forย 
Search instead forย 
Did you mean:ย 

Error ingesting files with databricks jobs

Anonym
New Contributor II

The source path that i want to ingest files with is:
"gs://bucket-name/folder1/folder2/*/*.json"

I have a file in this path that ends with ".json.gz" and the databricks job ingests this file even though it doesn't suppose to.

How can i fix it?
Thanks.

2 REPLIES 2

Kaniz_Fatma
Community Manager
Community Manager

Hi @Anonym, To exclude files with a .json.gz extension from being ingested by a Databricks job, you can use a glob pattern that specifies the inclusion of .json files but the exclusion of .json.gz files.

Here's an example of the pattern:

 

gs://bucket-name/folder1/folder2/*/*[^.gz].json

This pattern will match all .json files in the folder2 directory and its subdirectories, excluding those with a .json.gz extension.

By using this pattern, you can ensure that the Databricks job only ingests .json files while excluding files with the .json.gz extension in the specified path.

Anonym
New Contributor II

Thanks Kaniz ๐Ÿ™‚

Join 100K+ Data Experts: Register Now & Grow with Us!

Excited to expand your horizons with us? Click here to Register and begin your journey to success!

Already a member? Login and join your local regional user group! If there isn’t one near you, fill out this form and we’ll create one for you to join!