SET QUOTED_IDENTIFIER OFF 
GO
SET ANSI_NULLS ON 
GO
IF EXISTS (SELECT name FROM sysobjects 
         WHERE name = 'CIZLBLAL' AND type = 'P')
   DROP PROCEDURE RPTUSER.CIZLBLAL
GO


CREATE PROCEDURE RPTUSER.CIZLBLAL
@P_REPORT_CD  CHAR(12),
@P_USER_ID    CHAR(8)

AS

/******************************************************************************
   NAME:       CIZLBLAL
   PURPOSE:    Standard Extract Labels for Crystal Report for all languages

******************************************************************************/
BEGIN

    SELECT
        RL.SEQ_NUM, 
        RL.FLD_NAME, 
        LTRIM (RTRIM (FL.LABEL_LONG)) LABEL_LONG, 
        RL.REPORT_CD, 
        FL.LANGUAGE_CD
    FROM
        CI_MD_RPT_LBL RL,
        CI_MD_FLD_L FL
    WHERE    
        RL.FLD_NAME = FL.FLD_NAME
        AND RL.REPORT_CD = @P_REPORT_CD
    ORDER BY 
       RL.SEQ_NUM, FL.LANGUAGE_CD
			 
RETURN

END



GO
SET QUOTED_IDENTIFIER OFF 
GO
SET ANSI_NULLS ON 
GO

