| General Information |
| Purpose |
Provides subprograms to manage the configuration of Oracle Streams Advanced Queuing (AQ) asynchronous notification by e-mail and HTTP |
| Source |
{ORACLE_HOME}/rdbms/admin/dbmsaqem.plb |
| First Available |
9.0.1 |
| Dependencies |
| DBMS_AQELM_LIB |
UTL_HTTP |
UTL_SMTP |
UTL_TCP |
|
| Security Model |
Owned by SYS with no privileges granted |
| Subprograms |
|
| |
| GET_MAILHOST |
| Returns the host name for the SMTP server that the database will uses send out e-mail notifications |
dbms_aqelm.get_mailhost(mailhost OUT VARCHAR2); |
| See AQELM Demo |
| |
| GET_MAILPORT |
| Returns the port number for the SMTP server |
dbms_aqelm.get_mailport(mailport OUT NUMBER); |
| See AQELM Demo |
| |
| GET_PROXY |
| Returns the name of the proxy server |
dbms_aqelm.get_proxy(proxy OUT VARCHAR2, no_proxy_domains OUT VARCHAR2); |
| See AQELM Demo |
| |
| GET_SENDFROM |
| Returns the sent-from e-mail address |
dbms_aqelm.get_sendfrom(sendfrom OUT VARCHAR2); |
| See AQELM Demo |
| |
| HTTP_SEND |
Undocumented
Appears to send a specified line "WHAT" at a specified line number "WHATL" for a named URL
Returns 404 if the URL does not exist. |
dbms_aqelm.http_send(
url IN VARCHAR2,
what IN VARCHAR2,
whatl IN NUMBER,
status_code OUT VARCHAR2); |
set serveroutput on
DECLARE
sc VARCHAR2(30);
ls VARCHAR2(100) := 'TEST';
BEGIN
dbms_aqelm.http_send('www.morganslibrary.org/index.html', ls, 2, sc);
dbms_output.put_line(sc);
END;
/
DECLARE
sc VARCHAR2(30);
ls VARCHAR2(100) := 'TEST';
BEGIN
dbms_aqelm.http_send('www.morganslibrary.org/test.html', ls, 30, sc);
dbms_output.put_line(sc);
END;
/ |
| |
| SEND_EMAIL |
| Undocumented |
dbms_aqelm.send_email(sendto IN VARCHAR2, text IN VARCHAR2); |
| TBD |
| |
| SET_MAILHOST |
| Sets the host name for the SMTP server that the database will uses send out e-mail notifications |
dbms_aqelm.set_mailhost(mailhost IN VARCHAR2); |
| See AQELM Demo |
| |
| SET_MAILPORT |
| Sets the port number for the SMTP server |
dbms_aqelm.set_mailport(mailport IN NUMBER); |
| See AQELM Demo |
| |
| SET_PROXY |
| Sets the name of the proxy server |
dbms_aqelm.set_proxy(mailhost IN VARCHAR2, no_proxy_domains IN VARCHAR2); |
| See AQELM Demo |
| |
| SET_SENDFROM |
| Sets the sent-from e-mail address |
dbms_aqelm.set_sendfrom(sendfrom IN VARCHAR2); |
| See AQELM Demo |
| |
| DBMS_AQELM Demo |
| Demo Code |
set serveroutput on
DECLARE
mh VARCHAR2(100);
mp NUMBER;
sf VARCHAR2(50);
np VARCHAR2(50);
px VARCHAR2(50);
BEGIN
dbms_aqelm.set_mailhost('morganslibrary.org');
dbms_aqelm.set_mailport(25);
dbms_aqelm.set_sendfrom('mailsys@morganslibrary.org');
dbms_aqelm.set_proxy('proxyserver@morganslibrary.org');
COMMIT;
dbms_aqelm.get_mailhost(mh);
dbms_output.put_line('Mail Host: ' || mh);
dbms_aqelm.get_mailport(mp);
dbms_output.put_line('Mail Port: ' || mp);
dbms_aqelm.get_sendfrom(sf);
dbms_output.put_line('Send From: ' || sf);
dbms_aqelm.get_proxy(np, px);
dbms_output.put_line('No Proxy: ' || np);
dbms_output.put_line('Proxy: ' || px);
END;
/ |