• That doesn't fail because of something called deferred compile. If a table isn't found at parse/compile time, the statement that refers to that table is not parsed or compiled (past basic syntax checking), instead the parse, bind and compile is deferred until the statement actually executes.

    Deferred compile is only for missing objects (tables, views). If the object exists then the statement is parsed, bound and optimised regardless of whether it can ever run (the parser does not execute conditional code, the optimiser does not execute conditional code) and if there's a missing column the bind phase will fail.

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass