Answer the question
In order to leave comments, you need to log in
Where is the error in variable assignment in sql stored procedure?
CREATE PROCEDURE mysp1
@m int,
@w int
AS
DECLARE @par1 int, @par2 int;
SET @par1 = select [поле] from [таблица1] WHERE .... ;
SET @par2 = select [поле] from [таблица2] WHERE .... ;
BEGIN
INSERT INTO
таблица (поле1, поле2)
values ( @par1, @par2) -- в эту таблицу и эти поля вставка
END
GO
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question