Oracle / PLSQL: HEXTORAW Function

This article is written about how to use the Oracle/PLSQL HEXTORAW function with syntax and examples.

Description

The Oracle/PLSQL HEXTORAW function converts a hexadecimal value into a raw value.

Syntax

The syntax for the HEXTORAW function in Oracle/PLSQL is:

HEXTORAW( char )

Parameters or Arguments

char

The hexademical value to convert to a raw value.

Returns

The HEXTORAW function returns a raw value.

Applies To

The HEXTORAW function can be used in the following versions of Oracle/PLSQL:

Oracle 12c, Oracle 11g, Oracle 10g, Oracle 9i, Oracle 8i

Example

Let’s look at some Oracle HEXTORAW function examples and explore how to use the HEXTORAW function in Oracle/PLSQL.

For example:

HEXTORAW('45D')
Result: '045D'  (as a raw value)

HEXTORAW('7E')
Result: '7E'    (as a raw value)