hemtros
9/8/2016 - 8:17 PM

Calling Stored Procedure in a Procedure

Calling Stored Procedure in a Procedure

ALTER PROCEDURE [cqf].[ContentValueGetByExtRef] 
	@ExtRef NVARCHAR(20),
	@ObjectId INT,
	@LanguageCode VARCHAR(6),
	@Value NVARCHAR(max) OUTPUT
AS
SET NOCOUNT ON;
SET TRANSACTION ISOLATION LEVEL READ UNCOMMITTED;
BEGIN
	DECLARE @l_ParameterName VARCHAR(50)

	SELECT @l_ParameterName = CT.ParameterName
	FROM qf.ContentTemplate CT
	WHERE CT.ExtRef = @ExtRef

	EXEC qf.ContentValueGetByParameterName @l_ParameterName,@ObjectId,@LanguageCode,@Value OUTPUT,NULL,NULL
END