SQL Server Articles

Submit Article
Home » Articles » SQL Server » String FunctionsRSS Feeds

SOUNDEX Function

Posted By: Sarita Patel     Category: SQL Server     Views: 2956

This article explains SOUNDEX function of sql server with examples.

SOUNDEX is used to compare two strings. It returns 4 character code. It converts an alpha string to a four-character code to find similar-sounding words. The first character of the code is the first character of character_expression and the second through fourth characters of the code are numbers. Vowels in character_expression are ignored unless they are the first letter of the string. 

Syntax of SOUNDEX Function :


character_expression is a string of type character. It can be a constant, variable, or column. 

It returns char data type.

Examples of SOUNDEX Function :

Example 1 : Use of SOUNDEX function in select clause

SELECT SOUNDEX('Syntax-Example')


Above example returns 4 character code for specified string.


Didn't find what you were looking for? Find more on SOUNDEX Function Or get search suggestion and latest updates.

Sarita Patel
Sarita Patel author of SOUNDEX Function is from United States.
View All Articles

Related Articles and Code:

Please enter your Comment

  • Comment should be atleast 30 Characters.
  • Please put code inside [Code] your code [/Code].

No Comment Found, Be the First to post comment!