Вопрос

Given the following stored procedure definition

create procedure myproc
as

select * 
from sometablethatdoesnotexist

select somecolumnthatdoesnotexist 
from sometablethatdoesexist

Is it possible to configure sql-server (or localdb) to fail the creation of the stored procedure if at the time the stored procedure is created these objects do not exist? (either column or table)

Это было полезно?

Решение

No.

This is SQL Server's deferred name resolution.

There is no way of turning it off. It will fail if you reference a non existent column on an existing table though.

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top