external_table()

Learn how to use the external_table() function to reference an external table by name.

References an external table by name.

To accelerate queries over external delta tables, see Query acceleration policy.

Syntax

external_table( TableName [, MappingName / MaxAgeOverride ] )

Parameters

NameTypeRequiredDescription
TableNamestring✔️The name of the external table being queried. Must reference an external table of kind blob, adl, or sql.
MappingNamestringA name of a mapping object that maps fields in the external data shards to columns output.
MaxAgeOverrideTimeSpanWhen Query Acceleration Policy is enabled, override the policy’s MaxAge property for this query. If you use this property, the external table returns accelerated data if the last index refresh time is greater than @now - MaxAgeOverride. Minimum: 1s

Authentication and authorization

The authentication method to access an external table is based on the connection string provided during its creation, and the permissions required to access the table vary depending on the authentication method. For more information, see Azure Storage external table or SQL Server external table.