Skip to main content
Workday User Guide
Last Updated: 2023-06-23
URL_FRAGMENT

URL_FRAGMENT

Description

URL_FRAGMENT
is a row function that returns the fragment portion of a URL string.

Syntax

URL_FRAGMENT
(
URL_string
)

Return Value

Returns the fragment portion of a URL as a
TEXT
value,
NULL
if the URL or does not contain a fragment, or
NULL
if the input string is not a valid URL.
For example, in the string
http://www.workday.com/contact.html#phone
, the fragment portion is
phone
.
In the string
http://www.workday.com/contact.html
, the fragment portion is
NULL
.
In the string
http://workday.com/news.php?topic=press#Workday%20News
, the fragment portion is
Workday%20News
.

Input Parameters

URL_string
Required. A field or expression that returns a
TEXT
value in URI (uniform resource identifier) format of:
protocol
:
authority
[/
path
][?
query
][#
fragment
]
.
The optional fragment portion of the URL is separated by a hash mark (
#
) and provides direction to a secondary resource, such as a heading or anchor identifier.

Examples

Return the fragment portion of URL string values in the
request
field:
URL_FRAGMENT([request])
Return the fragment portion of a literal URL string:
URL_FRAGMENT("http://workday.com/news.php?topic=press#Workday%20News")
returns
Workday%20News
.
Return and decode the fragment portion of a literal URL string:
URLDECODE(URL_FRAGMENT("http://workday.com/news.php?topic=press#Workday%20News"))
returns
Workday News
.