UFN_CONSTITUENT_ISBANK

This function validates whether the constituent record is a bank.

Return

Return Type
bit

Parameters

Parameter Parameter Type Mode Description
@CONSTITUENTID uniqueidentifier IN

Definition

Copy


            CREATE function dbo.UFN_CONSTITUENT_ISBANK(@CONSTITUENTID uniqueidentifier)
      returns bit
            with execute as caller
            as begin

            if exists(
                select
                    ID
                from
                    dbo.BANK
                where
                    BANK.ID = @CONSTITUENTID
            ) return 1;

            return 0;
        end