例えば:
DECLARE
@t TABLE(id int),
@i int;
Msg 102, Level 15, State 1, Line 2
Incorrect syntax near ','.
ただし、個別の DECLARE ステートメントを使用すると問題なく動作します
DECLARE @t TABLE(id int);
DECLARE
@i int,
@str varchar(10);
Command(s) completed successfully.
なぜこれが起こるのですか?テーブル宣言と「通常の」変数の宣言の違いは何ですか?