41.2 FIND_EMAIL_ADDRESSESファンクション

このファンクションは、指定された入力文字列ですべての電子メール・アドレスを検出します。

構文

FUNCTION FIND_EMAIL_ADDRESSES (
    p_string IN VARCHAR2 )
    RETURN apex_t_varchar2;

パラメータ

表41-2 FIND_EMAIL_ADDRESSESファンクションのパラメータ

パラメータ 説明
p_string 入力文字列。

戻り値

このファンクションは、重複なしの電子メール・アドレスの配列を戻します。

declare
    l_string  varchar2(32767) := 'b@c.it hello this hello.world@example.com is text b@c.it includes the '||
                                 'michael.h@example.com email address and x.y.z@m.io';
    l_results apex_t_varchar2;
begin
    l_results := apex_string_util.find_email_addresses(l_string);
end;
/
-> apex_t_varchar2 (
       'b@c.it',
       'hello.world@example.com',
       'michael.h@example.com',
       'x.y.z@m.io' )