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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T11:29:36+00:00 2026-05-25T11:29:36+00:00

In my webservice I need to be able to pull from 3 different tables

  • 0

In my webservice I need to be able to pull from 3 different tables to get my search to work. I have an autocompleteextender control on one page that searches by a description, but instead of displaying the description, it should display all of the products that have the word or phrase entered.

Ex: I enter the word “here” and the autocompleteextender will show products that have the word “here” in their description.

The description of the product is in one table that gets linked to the product table by a table that holds ids for both the product and the description. Therefore, I need 3 tables to be linked. I’ve always had troubles when it came to joining multiple tables together, I was hoping someone could help?

Here is my statement:

"SELECT DISTINCT p.ProductID,
                p.ProductName
FROM   Product p
       INNER JOIN Marketing m
         ON p.ProductID = m.ProductID
       JOIN Feature f
         ON f.FeatureID = m.MarketingData
WHERE  f.FeatureTitle LIKE '%" & prefixText & "%'
ORDER  BY p.ProductName ASC"  

It pulls a null value when I type it into SQL Server so obviously something is wrong here. Database Structure

  • 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-25T11:29:37+00:00Added an answer on May 25, 2026 at 11:29 am

    If you want only the rows on products that have the given text on his matching featuretitle of the feature table you need to use INNER JOIN in order to supress all non necessary rows.

    SELECT DISTINCT 
        p.productid,
        p.productname
    FROM product p
    INNER JOIN marketing m ON p.productid = m.productid
    INNER JOIN feature f ON f.featureid = m.marketingdata
    WHERE  f.featuretitle LIKE '%@TextYouSearchFor%'
    ORDER  BY p.productname ASC  
    

    With this sentence you will only get the rows in products that have a matching description on feature table.

    Added for clarification purposes:

    If possible use a parametrized query passing the searched text as a parameter. This will avoid some possible errors with texts containing reserved SQL characters like ‘ or ,

    Specify allways the kind of join you want, like INNER JOIN, etc…

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

Sidebar

Related Questions

I need to be able to cancel async calls made to my webservice. One
I have a REST webservice that I need to consume in C#. I need
I need to return server time from a webservice. I've got the following code:
In one of our applications we need to call the Yahoo Soap Webservice to
I have created a webservice in .net 2.0, C#. I need to log some
I need to build a simple webservice to get data in and out of
I have 50+ kiosk style computers that I want to be able to get
I need to be able to send an email from a silverlight client-side application.
I will need to be able to receive this xml data from a Java
I have a stream of xml being returned from a webservice which is coming

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.