Apache Hive : HPL/SQL - Oracle PL/SQL Compatibility

Last updated: August 12, 2026

Apache Hive : HPL/SQL - Oracle PL/SQL Compatibility

HPL/SQL compatibility with Oracle PL/SQL and SQL.

Language Elements

Oracle PL/SQL language elements supported by HPL/SQL:

FeatureDescriptionSupportedSince
TRUE and FALSEBoolean literalsYes0.3.13
– commentSingle line commentYes0.1
/* comment */Multi line commentYes0.1
NOT NULLVariable constraintParser only0.3.13
CONSTANTConstant variableYes0.3.13
:= or DEFAULTDefault clauseYes0.1
%TYPEData type attributeYes0.3.13
SUBTYPE subtype IS typeSubtypeNo

Data Types and Declarations

Oracle PL/SQL data types supported by HPL/SQL:

Data TypeDescriptionSupportedSince
BIGINT64-bit integerYes0.3.13
BINARY_DOUBLEDouble precision floating-point numberYes0.3.13
BINARY_FLOATSingle precision floating-point numberYes0.3.13
BINARY_INTEGER32-bit integerYes0.3.13
BLOBBinary long dataNo
BOOLEANTrue or falseYes0.3.13
CHAR(n)Fixed-length stringYes0.1
CHARACTER(n)Fixed-length stringYes0.1
CLOBCharacter long dataNo
DECIMAL(p,s)Fixed-point numberYes0.1
DATEDate (year, month, day and time)Yes0.1
INT32-bit integerYes0.1
INTEGER32-bit integerYes0.1
LONGLong stringNo
LONG RAWLong binary stringNo
NATURALNonnegative 32-bit integerNo
NATURALNNonnegative non-null 32-bit integerNo
NCHAR(n)Fixed-length stringYes0.1
NCLOBCharacter long dataNo
NVARCHAR(n)Variable-length stringYes0.1
NUMBER(p,s)Fixed-point numberYes0.1
PLS_INTEGER32-bit integerYes0.3.13
POSITIVEPositive 32-bit integerNo
POSITIVENPositive non-null 32-bit integerNo
RAWBinary dataNo
ROWIDRow addressNo
SIGNTYPE-1, 0 or 1No
SIMPLE_DOUBLEDouble precision floating-point numberYes0.3.13
SIMPLE_FLOATSingle precision floating-point numberYes0.3.13
SIMPLE_INTEGER32-bit integerYes0.3.13
SMALLINT16-bit integerYes0.1
SYS_REFCURSORCursor variableYes0.3.11
TIMESTAMPDate and timeYes0.3.7
VARCHAR(n)Variable-length stringYes0.1
VARCHAR2(n)Variable-length stringYes0.1
UROWIDRow addressNo
UTL_FILE.FILE_TYPEFile handleYes0.1

Operators and Expressions

Oracle PL/SQL operators and expressions supported by HPL/SQL:

OperatorDescriptionSupportedSince
|| OperatorString concatenationYes0.1

Statements

Oracle PL/SQL statements supported by HPL/SQL:

StatementDescriptionSupportedSince
:=Assignment statementYes0.1
CREATE FUNCTIONCreate a user-defined functionYes0.3.1
CREATE PACKAGECreate a packageYes0.3.13
CREATE PROCEDURECreate a stored procedureYes0.3.1
NULLNo operationYes0.3.13
SELECT INTOAssign values from queryYes0.1