UPPER function in SQL Server

The article will explore and show you how to use UPPER function in SQL Server to convert letters in a specified string to uppercase.

The article will explore and show you how to use UPPER function in SQL Server to convert letters in a specified string to uppercase.

Describe

UPPER function in SQL Server converts all the letters in the string specified to uppercase. If there are characters in a string other than letters, it is not affected by this function.

Syntax

To use UPPER function in SQL Server, we use the following syntax:

 UPPER(chuoi) 

Parameters :

  1. string : the string you want to convert, can be a string of characters with text, variables, string expressions or table columns.

Note :

  1. See more LOWER functions for reverse conversion.
  2. The UPPER function can be used in later versions of SQL Server: SQL Server 2017, SQL Server 2016, SQL Server 2014, SQL Server 2012, SQL Server 2008 R2, SQL Server 2008, and SQL Server 2005.

For example

Take a look and explore some examples of UPPER functions in SQL Server.

 SELECT UPPER('quantrimang.com'); 
Result: 'QUANTRIMANG.COM'

SELECT UPPER('QuanTriMang.com');
Result: 'QUANTRIMANG.COM'

SELECT UPPER('Quan Tri Mang');
Result: 'QUAN TRI MANG'

Previous article: SUBSTRING function in SQL Server

Next lesson: ABS function in SQL Server

Update 25 May 2019
Category

System

Mac OS X

Hardware

Game

Tech info

Technology

Science

Life

Application

Electric

Program

Mobile