w3resource

Oracle NLS_UPPER function

Description

The NLS_UPPER function is used to return all letters of a given string in uppercase, taking into account linguistic conventions based on the National Language Support (NLS) parameters.

Note : National Language Support (NLS) is a technology enabling Oracle applications to interact with users in their native language, using their conventions for displaying data.

Uses of Oracle NLS_UPPER Function
  • Converting Text to Uppercase: Transforms all characters in a string to uppercase.

  • Supporting Multiple Languages: Handles uppercase conversions according to linguistic rules for various languages.

  • Data Cleaning and Normalization: Normalizes text data to uppercase for consistent storage and processing.

  • Preparing Data for Comparison: Ensures case-insensitive comparisons by converting text to uppercase.

  • Formatting User Inputs: Standardizes user inputs to uppercase.

  • Enhancing Data Presentation: Formats text data for consistent presentation in reports, GUIs, and other interfaces.

Syntax:

NLS_UPPER(string1 [, 'nlsparam' ])

Parameters:

Name Description Data Types
string1 A string whose characters will be converted to uppercase. CHAR, VARCHAR2, NCHAR, NVARCHAR2, CLOB, or NCLOB
nlsparam The value of 'nlsparam' can have this form :
'NLS_SORT = sort'
where sort is either a linguistic sort sequence or BINARY. The linguistic sort sequence handles special linguistic requirements for case conversions. These requirements can result in a return value of a different length than the char. If you omit 'nlsparam', then this function uses the default sort sequence for your session.
 

Return Value Type

VARCHAR2

Examples: Oracle NLS_UPPER function

The following example returns a string with all the letters converted to uppercase:

SELECT NLS_UPPER('w3resource') "Uppercase"
FROM DUAL;

Sample Output:

Uppercase
----------
W3RESOURCE

Previous: NLS_LOWER
Next: NLSSORT



Become a Patron!

Follow us on Facebook and Twitter for latest update.

It will be nice if you may share this link in any developer community or anywhere else, from where other developers may find this content. Thanks.

https://www.w3resource.com/oracle/character-functions/oracle-nls_upper-function.php