Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7170951
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T15:18:53+00:00 2026-05-28T15:18:53+00:00

I need a special operator that’s maybe a bit better than LIKE to query

  • 0

I need a special operator that’s maybe a bit better than LIKE to query for “similar” values.

THE SCENARIO:
I have a table of students, and I have a table of lessons. The table of lessons was imported from other software, so the StudentID column is null on the imported rows. So we need the user to manually select the appropriate student row for each lesson, and then the StudentID column can be populated so they’re properly synced. Both tables contain first and last names, but a lot of them are very likely to be misspelled.

After importing the rows, I would like to present the user with the names from the student rows where the names are “top five most similar” to the values stored in each lesson row. In fact I’d like to present them in descending order from most-to-least similar.

A query containing the LIKE operator doesn’t quite cut it because it requires specific text must exist within the column, and it doesn’t return a “similarity score”.

It is my understanding (from non-technical articles) that the US Post Office has this issue very well handled… People misspell names and street names all the time, but their algorithm for “find similar” is very effective.

I know the algorithm could vary from one solution to the next. For example I read from the article that some algorithms consider phonetics, others consider the count of vowels and consonants, while others consider that “T” sounds like “P” when spoken over the phone.

I COULD load every record into my app code and write my own algorithm in c#, VB.NET or whatever, but there are lots of problems with that including performance. I’d rather accomplish this within the query so I’m looking for alternatives.

I’m using SQL Server Express but I’m sure the solution applies to other database platforms.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T15:18:54+00:00Added an answer on May 28, 2026 at 3:18 pm

    SQL Server supports the SOUNDEX() function, but this works only for similar sounding names and that not to well, at least if you handle non english texts. You could write you own function in c# or vb.net, facilitating any algorithm that might apply to your needs, and import it as a scalar function into sql server.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a special need for a kind of reverse Maybe monad that when
I have a java class that uses complex static fields which need special operations
Say I need some very special multiplication operator. It may be implemented in following
I have a e-mail address validator but I need to add special characters as
I have a situation, where I need to create a new JavaScript object that
I have a special type of ostringstream that I am trying to output text
For some complicated reason, I need to mark some Javascript as special, like this:
Need to write a SQL query to search special character in a column. Text
Large datasets, millions of records, need special programming to maintain speed in DBGrids. I
We need a special user control for our web application. It should ideally look

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.