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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T06:18:05+00:00 2026-06-03T06:18:05+00:00

This is my current query: SELECT * FROM users WHERE blah blah… AND users.who

  • 0

This is my current query:

SELECT * FROM users
WHERE blah blah...
AND users.who = '1'

AND users.seeking = '2' 
OR users.seeking = '5' 
OR users.seeking = '8' 
OR users.seeking = '9' 
OR users.seeking = '11' 
OR users.seeking = '13' 
OR users.seeking = '14' 
OR users.seeking = '15' 

AND users.account_status = '1';

As you can see the seeking field can have multiple values. Rather than writing so many OR’s is there a prettier way to specify all the acceptable values for that field in order to be returned by my select statement?

  • 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-03T06:18:07+00:00Added an answer on June 3, 2026 at 6:18 am
    SELECT * FROM users
    WHERE blah blah...
    AND users.who = '1'
    
    AND users.seeking IN('2','5','8','9','11','13','14','15') 
    AND users.account_status = '1';
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have the following Query: SELECT a.name_f, a.uid, a.name_l, a.profile_pic, b.position FROM users a
This is my current query: SELECT DISTINCT t.* FROM filter AS f INNER JOIN
If I have a query like this: String Category = HttpContext.Current.Request.QueryString[Product].ToString(); IQueryable<ItemFile> pressReleases =
This is the current result that can be changed from day to day (int)
I've got the following query: SELECT name, GROUP_CONCAT(job SEPARATOR ','), count(*) FROM users GROUP
This is my current code: $result = mysql_query(SELECT * FROM characters WHERE namn =
I have this query: select problem_comments.user_id , problem_comment_id , problem_id , first_name , count(problem_comment_id)
I have tried all kinds of different ways to query this but just can't
What is current directory of shell script? Is this current directory from which I
I am having a bit of difficulty with this current code I have set

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.