Annotation: office.get_office_id_by_office_code

CREATE OR REPLACE FUNCTION office.get_office_id_by_office_code(office_code text)
RETURNS integer

Information: office.get_office_id_by_office_code

Schema office
Function Name get_office_id_by_office_code
Arguments office_code text
Owner postgres
Result Type integer
Description

Implementation: office.get_office_id_by_office_code

CREATE OR REPLACE FUNCTION office.get_office_id_by_office_code(office_code text)
 RETURNS integer
 LANGUAGE plpgsql
AS $function$
BEGIN
    RETURN
    (
        SELECT office.offices.office_id FROM office.offices
        WHERE office.offices.office_code=$1
    );
END
$function$