pg_utl_smtp
Oracle UTL_SMTP compatibility extension for PostgreSQL
Repository
hexacluster/pg_utl_smtp
https://github.com/hexacluster/pg_utl_smtp
Source
pg_utl_smtp-1.0.tar.gz
pg_utl_smtp-1.0.tar.gz
Overview
| Package | Version | Category | License | Language |
|---|---|---|---|---|
pg_utl_smtp | 1.0.0 | SIM | PostgreSQL | SQL |
| ID | Extension | Bin | Lib | Load | Create | Trust | Reloc | Schema |
|---|---|---|---|---|---|---|---|---|
| 9290 | pg_utl_smtp | No | No | No | Yes | No | No | utl_smtp |
| Related | plperlu pg_smtp_client omni_email orafce pg_html5_email_address emailaddr pg_dbms_metadata pg_dbms_lock pg_dbms_job pg_dbms_errlog db2fce |
|---|
runtime requires plperlu and Perl Net::SMTP
Version
| Type | Repo | Version | PG Ver | Package | Deps |
|---|---|---|---|---|---|
| EXT | PGDG | 1.0.0 | 1817161514 | pg_utl_smtp | plperlu |
| RPM | PGDG | 1.0 | 1817161514 | pg_utl_smtp_$v | - |
| DEB | PIGSTY | 1.0.0 | 1817161514 | postgresql-$v-utl-smtp | - |
Build
You can build the DEB packages for pg_utl_smtp using pig build:
Install
You can install pg_utl_smtp directly. First, make sure the PGDG repository is added and enabled:
Install the extension using pig or apt/yum/dnf:
Install
pig
dnf
apt
Create Extension:
Usage
pg_utl_smtp: Oracle UTL_SMTP compatibility extension for PostgreSQL
Enabling
Sending an Email
Procedures
- OPEN_CONNECTION(host, port, tx_timeout, …) - Opens a connection to an SMTP server. Returns a
utl_smtp.connectiontype. Supports SSL/TLS viasecure_connection_before_smtp. - EHLO(c, domain) / HELO(c, domain) - Performs initial SMTP handshake.
- MAIL(c, sender) - Initiates a mail transaction.
- RCPT(c, recipient) - Specifies e-mail recipient. Call multiple times for multiple recipients.
- OPEN_DATA(c) - Sends the DATA command to begin message body.
- WRITE_DATA(c, data) - Writes a portion of the message body.
- WRITE_RAW_DATA(c, data) - Writes raw data to the message body.
- CLOSE_DATA(c) - Closes the data session.
- QUIT(c) - Terminates the SMTP session and disconnects.
Connection Type
Notes
- Requires the Perl
Net::SMTPmodule installed on the system - Use
E'\r\n'for line breaks instead ofutl_tcp.crlf - The
wallet_pathandwallet_passwordparameters are not used
Was this page helpful?
Thanks—your feedback helps us improve this page.
What got in the way? (optional)