CREATE function func_create_log_appointment_group() returns trigger
    LANGUAGE plpgsql AS
$$
BEGIN
    INSERT INTO log_appointment_group
    VALUES (OLD.fecha_creacion, OLD.user_group,OLD.id_room_appointment_study_receipt, OLD.id_appointment_group, OLD.id_data_group, OLD.appointment_code);
    RETURN NEW;
END
$$;

ALTER function func_create_log_appointment_group() owner TO u5u4r10r15;
