Jump to content

Mysql Search


Network_ninja

Recommended Posts

Hi everyone.. pls. help.

 

I don't have yet a working code since i don't have an idea on how to do it. I just want to have a simple search query.

Lets say that if I am going to search for the word 'smith' all firstname that is similar to that will be displayed:

 

eg.

Smithe

Smit

Smiht

 

This is not possible using LIKE since the output would only be Smithe.

 

Tnx in advance.

Link to comment
Share on other sites

tnx for that info... But thats not what I'm looking for:

 

Say I have this value on my table

 

firstname

Smithe

Smith

Smoothe

Smooth

Smithe

 

if i am going to use this query

SELECT * FROM tablename WHERE MATCH
(firstname) AGAINST ('Smith')

 

It would only output :

Smith

 

The desirable output would be

Smithe

Smithe

Smith

 

I am looking for the MYSQL REGULAR EXPRESSION to do the thing but don't have yet come up with a correct one....

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.