DROP PROCEDURE IF EXISTS uspGetCsengetesiRendAndOraszam
GO
  CREATE PROCEDURE uspGetCsengetesiRendAndOraszam
     @pCsengetesirendId INT
    ,@pIntezmenyId INT
		,@pTanevId INT
  AS
  BEGIN
    SET NOCOUNT ON;

    SELECT r.C_CSENGETESIRENDID AS CsengetesiRendId
      ,r.C_ORASZAM AS OraSzam
    FROM T_CSENGETESIRENDORA_OSSZES r
    WHERE r.TOROLT = 'F'
      AND r.ID = @pCsengetesirendId
      AND r.C_TANEVID = @pTanevId
      AND r.C_INTEZMENYID = @pIntezmenyId
  END
GO

