From a book:
This code demonstrates that table variables are not visible even across batches in the same level. The SELECT query against the table variable fails with the following error.
Msg 1087, Level 15, State 2, Line 2
Must declare the table variable "@T1"
DECLARE @T1 AS TABLE
col1 INT NOT NULL
INSERT INTO @T1(col1) VALUES(10);
Question: Why I am not getting any errors executing this sample code? The book says otherwise.