The CLOSE_DATA procedure sends a <CR><LF>.<CR><LF> to indicate the end of the email text.
Applicability
This topic applies only to OceanBase Database in Oracle mode.
Syntax
UTL_SMTP.CLOSE_DATA (
c IN OUT NOCOPY connection)
RETURN reply;
UTL_SMTP.CLOSE_DATA (
c IN OUT NOCOPY connection);
Parameters
| Parameter | Description |
|---|---|
| c | The SMTP connection. |
Return value
| Return value | Description |
|---|---|
| reply | The reply to the command. If multiple replies are returned, only the last one is returned. |
Considerations
You must call the OPEN_DATA, WRITE_DATA, WRITE_RAW_DATA, and CLOSE_DATA procedures in sequence. The open_data procedure sends the data command to indicate the start of the email content. After that, you can call the write_data and write_raw_data procedures multiple times to send the email body. Finally, the close_data procedure sends the terminator to end the sending.