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 8464803
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T14:51:44+00:00 2026-06-10T14:51:44+00:00

I have the following table search_redirect sr_id | sr_keyword | sr_redirect | sr_synonyms ——————————————————

  • 0

I have the following table

search_redirect
sr_id | sr_keyword | sr_redirect | sr_synonyms
------------------------------------------------------
1     | chair      | www.url.com | recliner,seat,stool
2     | couch      | www.url.com | sofa,divan
3     | dresser    | www.url.com | chest,drawers

When someone uses the search feature on my site, I want to be able to compare what they search to the list of synonyms. My attempt at a solution was this:

SELECT sr_redirect
FROM search_redirect
WHERE '#url.q#' IN (sr_redirect)

Unfortunately, while this is a completely legal move, it doesn’t do what I thought it would do. My next attempt was to try and add single quotes to my values in the sr_synonyms, but that also did not yield successful results. Its difficult to word this issue so I was unable to find any help on this situation. Any advise I can get on this would be most appreciated. I am using ColdFusion 9 server-side scripting with SQL Server 2008.

  • 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-06-10T14:51:46+00:00Added an answer on June 10, 2026 at 2:51 pm

    To maintain a pure sql solution I would change your table into 2 tables.

    The first could have :

    search_redirect

    sr_id | sr_keyword | sr_redirect

    The second could have

    search_keyword_to_synonym

    sr_id | sr_synonym

    Then only have 1 synonym per row in the second table.
    Your solution could then be:

    SELECT sr_redirect FROM search_redirect
    INNER JOIN search_keyword_to_synonym
    ON search_redirect.sr_id=search_keyword_to_synonym.sr_id
    WHERE search_redirect.sr_keyword=whatever_input_you_have.
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have following Table with records for ActivityLog: ID, UserId, Category, Created 1 11
I have following table Id | Status | date ------------------- 1 | Onsite |2007
Imagine I have following table: NAME DATE OTHER_CONTANT 'A' '2012-06-05' 'baz' 'A' '2012-06-04' 'bar'
Let's say I have following table like this <!DOCTYPE html PUBLIC -//W3C//DTD XHTML 1.0
I have following CSS: table tbody tr:last-child td { padding-top: 7px; border-bottom: 0; }
I have the following table drop table names; create table names( name varchar(200), surname
I have the following table: Order Product Price Quantity Description Order1 Product1 12 1
I have the following table UserID | User knows -------------------- a | b a
I have the following table: ID | JobID | Data | ResultType --------------------------------- 1
I have the following table that lists all awarded cups: Name: Cups Columns: Month,

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.