请教临时表的问题
SELECT * ,user_id ,CAST(NULL AS nvarchar(100)) AS user_name ,CAST(NULL AS nvarchar(100)) AS login_name ,CAST(NULL AS nvarchar(100)) AS password ,CAST(NULL AS nvarchar(100)) AS department INTO #TempTB FROM T --更新用户信息 UPDATE #TempTB SET user_name = T_USER_User.user_name, login_name = T_USER_User.login_name, password = T_USER_User.password, department = T_USER_User.department FROM T_USER_User WHERE #TempTB.user_id = T_USER_User.auto_id
SELECT * ,user_id ,CAST(NULL AS nvarchar(100)) AS user_name ,CAST(NULL AS nvarchar(100)) AS login_name ,CAST(NULL AS nvarchar(100)) AS password ,CAST(NULL AS nvarchar(100)) AS department INTO ##TempTB ---------- FROM T