Hi,
I'm using sql server and I have to procedures as follows:
CREATE PROCEDURE
InsertLog(
@menuName nvarchar(500),
@buttonName nvarchar(500),
@buttonText nvarchar(500),
@buttonPath nvarchar(500),
@buttonCaptionPath nvarchar(500),
@clickDateTime DateTime,
@UserID nvarchar(500)
)
AS
BEGIN
DECLARE @linage nvarchar(500)
SET @linage =
EXEC GetLinage @menuName,@linage
INSERT INTO
LogTable(
GUID,
FormName,
Linage,
ButtonPath,
ButtonCaptionPath,
ButtonName,
ButtonText,
ClickDateTime,
UserID
)
VALUES(
newid(),
@menuName,
@linage,
@buttonPath,
@buttonCaptionPath,
@buttonName,
@buttonText,
@clickDateTime,
@UserID
)
END
GO
CREATE PROCEDURE GetLinage (
@formidentity nvarchar(200),
@linage nvarchar(200) OUTPUT
)
AS
SELECT @linage = Linage
FROM formslist
WHERE (formslist.formID = @formidentity)
GO
The value which the GetLinage SP must return (or returns) does not get assigned to the variable in the InsertLog.
I cannot find out why it doesn't work, though I'm searching and trying different ways to make it work.
What I have tried:
I'm working on it but yet I haven't found a good solution.