DF214: The schema name for a table or view is not specified.
Last modified: December 25, 2024
The topic describes the DF214 T-SQL code analysis rule.
Category
BEST PRACTICE
Message
The schema name for a table or view is not specified.
Description
It is recommended to explicitly specify the schema when referencing a stored table or view.
Additional information
Explicitly specifying the schema when referencing a table or view helps improve query performance, avoids ambiguity, and ensures that the correct object is accessed, especially in databases with multiple schemas. It also improves code clarity and maintainability.
Noncompliant code example
SELECT
id
FROM DemoTable
GO
Compliant solution
SELECT
id
FROM dbo.DemoTable
GO
Was this page helpful?