Skip to main content

Read Files Options

Customize read_files options for the file operation. The default includes mergeSchema => 'true'.

When landing files are read through a temporary view (the default load pattern, used when Use Copy Into is disabled) the view selects from read_files(<path>, <options>). When this setting is blank, the options are derived from the file definition: format => '<file type>' and mergeSchema => 'true', plus the delimiter, header, quote, escape, encoding, null value, row delimiter and skip-rows values for delimited files. A value in this setting replaces the generated options verbatim.

When to Change This Setting

Leave it blank so the options follow the file metadata. Set it when reading the files needs read_files options the metadata does not express.

SettingInteraction
Use Copy IntoSwitches file ingestion to COPY INTO, where these options do not apply
Copy Format OptionsThe equivalent override for the COPY INTO load pattern

Notes

  • This setting is part of the Databricks settings category.
  • This setting is blank by default; the generated options are then derived from the file metadata.