Hi
If you know when 1 is passed it needs to insert to cAlerts and when 2 is passed to insert to cAnalysisCode etc. You can use separate INSERT statements in your SP :-
IF @Table = 1
BEGIN
INSERT INTO dbo.cAlerts
(type, IdAlpha, [Description])
VALUES (@Type, @Alpha, @Description)
END
IF @Table = 2
BEGIN
INSERT INTO dbo.cAnalysisCode
(type, IdAlpha, [Description])
VALUES (@Type, @Alpha, @Description)
END
Nickie
|