input_file_name function
Applies to:  Databricks SQL 
 Databricks Runtime
warning
This function is not available on Unity Catalog.
In Databricks Runtime 13.3 LTS and above this function is deprecated. Use _metadata.file_name.
In Databricks SQL and Databricks Runtime 17.3 LTS and above this function is no longer supported.
Use _metadata.file_name instead.
Returns the name of the file being read, or empty string if not available.
Syntax
input_file_name()
Arguments
This function takes no arguments.
Returns
A STRING.
If the information is not available an empty string is returned.
The function is non-deterministic and may return inaccurate results. Use _metadata.file_name instead for reliable results.
Examples
SQL
> SELECT input_file_name();