SET ANSI_NULLS ON
GO

SET QUOTED_IDENTIFIER ON
GO

IF OBJECT_ID('[sp_GetEPenztarcaParameterekId]') IS NOT NULL 
BEGIN
  DROP PROCEDURE [sp_GetEPenztarcaParameterekId]
END  
GO

CREATE PROCEDURE [sp_GetEPenztarcaParameterekId]
  @intezmenyId INT,
  @tanevId INT
AS
BEGIN
	SET NOCOUNT ON

	SElECT EPenztarcaParameterek.ID
	FROM T_EPENZTARCAPARAMETEREK EPenztarcaParameterek
	WHERE
		EPenztarcaParameterek.C_INTEZMENYID = @intezmenyId
		AND EPenztarcaParameterek.C_TANEVID = @tanevId
		AND EPenztarcaParameterek.TOROLT = 'F'

END