[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

SQL Where Statment with Multiple Values

Posted on 2009-12-31
2
Medium Priority
?
284 Views
Last Modified: 2013-12-07
I need to do a select statement for mutliple values within the same column.

select * from car
where car_name= 'value'

I need several data values for value.  That is value is  pontiac, acura, and volvo.

How do you do that in SQL?  Hope I was able to explain this okay -- it's hard to explain.
0
Comment
Question by:lcor
2 Comments
 
LVL 75

Accepted Solution

by:
Aneesh Retnakaran earned 2000 total points
ID: 26155557
select * from car
where car_name  in (  'pontiac', 'acura', 'volvo' )
0
 

Expert Comment

by:Stoical85
ID: 26156691
you can also use AND

Where Car_Name is 'Pontiac' and 'Acura' And 'Volvo' if you want to select all the car's
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This month, Experts Exchange sat down with resident SQL expert, Jim Horn, for an in-depth look into the makings of a successful career in SQL.
MSSQL DB-maintenance also needs implementation of multiple activities. However, unprecedented errors can hamper the database management. In that case, deploying Stellar SQL Database Toolkit ensures fast and accurate database and backup repair as wel…
This video shows syntax for various backup options while discussing how the different basic backup types work.  It explains how to take full backups, incremental level 0 backups, incremental level 1 backups in both differential and cumulative mode a…
This video shows how to Export data from an Oracle database using the Original Export Utility.  The corresponding Import utility, which works the same way is referenced, but not demonstrated.
Suggested Courses

834 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question