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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T02:46:33+00:00 2026-06-08T02:46:33+00:00

I have a VERY basic database that i need to return certain results for.

  • 0

I have a VERY basic database that i need to return certain results for.

The table i’m searching is called Judge and it contains the columns:

Judge_id, Name, Suburb

In my select statement I need to return the results of everyone who lives in Adelaide and Sydney.

So I use:

SELECT *
FROM judge
WHERE Suburb LIKE ('Adelaide' 'Sydney');

but this returns no results. Also tried:

SELECT *
FROM judge
WHERE Suburb = 'Adelaide' 'Sydney'

Still no results.

If I only search for just Adelaide however:

SELECT *
FROM judge
WHERE Suburb = 'Adelaide'

I get ONE result. However there are multiple matches, and the result that is returned in the last one on the table (if that has anything to do with it).

If I do:

SELECT *
FROM judge
WHERE Suburb LIKE '%Adelaide%'

I get both matches. But if i leave the % signs out, I only get the one match again.

If i do a search for any of the “Name”s of the people in the table, i can get matches back for any of them fine. So why am i having trouble getting a match for Suburb?
Thanks for any help

EDIT:

Table looks like:

CREATE TABLE JUDGE (
   Judge_id    INT     NOT NULL,
   Name        VARCHAR(25),
   Address     VARCHAR(25),
   PRIMARY KEY (Judge_id)
);

and data:

1  Smith      Melbourne
2  Green      Cootamundra
3  Gates      Dunkeld
4  Smith      Sydney
5  Russell    Adlaide
6  Schofield  Adelaide
  • 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-08T02:46:34+00:00Added an answer on June 8, 2026 at 2:46 am

    I agree with Ravi’s suggestion – but if you really do want to use “LIKE” then use:

    SELECT * FROM judge WHERE Suburb LIKE 'Adelade%' or Suburb LIKE 'Sydney%';
    

    Only of any use if there are suffixes to that field data though.

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

Sidebar

Related Questions

I have a very basic mysql table called memberships, that tracks which people belong
I have a very basic need to get some data from the database and
I have a very basic web crawler. The database table which stores the links
I have some very basic semaphore code that works great on Linux, but cannot
I have a very basic doubt regarding the method that gets executed when app
I have a very basic data class that is subclassed from NSObject. I declare
I have a very simple database structure (basically only a user table) with two
I have created a very basic service operation that needs to write content to
I have a very basic API in my app which also has an index
I have a very basic windows forms app, working in C#, and I was

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.