Msg 195, Level 15, State 10, Line 2 'CONCAT' is not a recognized built-in function name : SELECT
            CONCAT(CCYYMM,RIGHT(C.AMT001,2)) ACCDAT
            ,CSTCOD
            ,PRPCOD
            ,C.RevenueAmount
            ,D.RevenueAllowance
            ,OUTLET
            ,AMTYTD
            ,ALWYTD
            ,MODCOD
            ,RECTYP
            ,RECCOD
            ,GRPCOD
            ,DEPCOD
            ,[CSTCTR]
            ,[GLCODE]    
        FROM PMS.FMNASTBL
            CROSS APPLY
            (
              VALUES
                ('AMT001',AMT001 )
            ) c (AMT001,RevenueAmount)
            CROSS APPLY
            (
              VALUES
                ('ALW001',ALW001 )
            ) D (ALW001,RevenueAllowance)