我在 sql 中有这段代码,它在 sql server 2005 上完美运行。但是当我在 isql plus 中运行这段代码时,它给出了错误,我应该进行哪些更改才能运行它。
代码是---
DECLARE @stu_Name VARCHAR(50), @stu_Address VARCHAR(50)
SELECT @stu_Name = g.stu_Name,@stu_Address= g.stu_address
FROM student as g
WHERE unique_no = 's121'
INSERT INTO
dbo.student(stu_no, stu_name, dateofbirth,stu_unique_no, stu_name,stu_address)
VALUES
(13, 'John', '1990-12-12','s121', @stu_Name, @stu_Address);