Oracle UTL_URL
Version 12.1.0.2

General Information
Library Note Morgan's Library Page Footer
The Library is currently in the process of being upgraded from Oracle Database Version 11.2.0.3 to 12.1.0.1. Demos are being upgraded to reflect the new Container paradigm as well as EBR (Edition Based Redefinition) and may contain references to CDBs, PDBs, and other objects you may not be familiar with such as CDB_OBJECTS_AE: Welcome to 12c.
Purpose Escape/Unescape URLs
AUTHID DEFINER
Dependencies
DBMS_ISCHED UTL_HTTP WWV_FLOW_UTILITIES
URIFACTORY UTL_URL_LIB WWV_HTF
Documented Yes
Exceptions
Error Code Reason
ORA-29262 BAD_URL: The URL contains badly formed escape code sequences
ORA-29274 BAD_FIXED_WIDTH_CHARSET: Fixed-width multibyte character set not allowed as a URL character set
First Available 9.0.1
Security Model Owned by SYS with EXECUTE granted to PUBLIC and APEX_040200
Source {ORACLE_HOME}/rdbms/admin/utlurl.sql
Subprograms
 
ESCAPE
Returns a URL with illegal characters (and optionally reserved characters) escaped using the %2-digit-hex-code format utl_url.escape(
url                   IN VARCHAR2 CHARACTER SET ANY_CS,
escape_reserved_chars IN BOOLEAN DEFAULT FALSE,
url_charset           IN VARCHAR2 DEFAULT utl_http.get_body_charset)
RETURN VARCHAR2 CHARACTER SET url%CHARSET;
SELECT utl_url.escape('http://www.acme.com/a url with space.html')
FROM dual;
 
UNESCAPE
This function unescapes the escape character sequences to its original form in a URL, to convert the %XX escape character sequences to the original characters. utl_url.escape(
url         IN VARCHAR2 CHARACTER SET ANY_CS,
url_charset IN VARCHAR2 utl_http.get_body_charset)
RETURN VARCHAR2 CHARACTER SET url%CHARSET;
SELECT utl_url.unescape('http://www.acme.com/a%20url%20with%20space.html')
FROM dual;

Related Topics
Packages
UTL_HTTP
UTL_INADDR

Morgan's Library Page Footer
This site is maintained by Dan Morgan. Last Updated: This site is protected by copyright and trademark laws under U.S. and International law. © 1998-2014 Daniel A. Morgan All Rights Reserved