From the course: Intermediate SQL for Data Scientists (2021)

Unlock the full course today

Join today to access over 24,700 courses taught by industry experts.

Use SOUNDEX with misspelled text

Use SOUNDEX with misspelled text

- [Instructor] Sometimes when we work with texts, we have mistakes or variations in spelling that make exact matching difficult. Now, when that's the case, we can use what's known as approximate matching. And in Postgres, there is an extension or an additional module called fuzzystrmatch, which we can use. So to use that we need to actually install the extension because it's not included by default in the Postgres installation. So to use an extension, we have to create it, so I'm going to specify, create extension. And then we specify the name of the extension. And these are documented in the Postgres documentation. And the extension we're going to install is called fuzzystrmatch. Now I'm going to execute this to show an error message that happens when the extension already exists. So it doesn't hurt anything, this doesn't change anything. It's just, if you are going to use this create extension command in a script, if…

Contents