Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Databases

Searching within a set of values 1 of 2

I'm getting the error message " Bummer! You're missing a WHERE clause!" when I try and run this query: SELECT * from products where price in ("7.99", "9.99", "11.99"); I get a different error message "Bummer! You didn't select all columns" when I try this query: SELECT id, name, description, price from products where price in ("7.99", "9.99","11.99"); Thanks

Nathan Tallack
Nathan Tallack
22,160 Points

Could you link to the video or challenge you are working from so that we can have context?

Pablo Caro
Pablo Caro
4,191 Points

I am also having the same issue. I too tried no quotes and with quotes. Everything I have tried is not working. select * from products WHERE price IN (7.99,9.99,11.99);

**** Leo Thanks for the help. I am currently using firefox and will change over to Chrome to see if that helps.

Hi Pablo, I usually format the IN statement with spaces IN (7.99, 9.99, 11.99). But, I just ran your query "select * from products WHERE price IN (7.99,9.99,11.99);" with no problems. I think I might have changed browsers for this problem. I was on Firefox initial but now I'm using Chrome. Good Luck.

2 Answers

Bonnie Martin
Bonnie Martin
13,671 Points

Prices are numbers, so they don't need quotes around them.

It is working now. I used the query: SELECT * from products where price in ("7.99", "9.99", "11.99");

Thanks for the help.

Steven Parker
Steven Parker
231,261 Points

But isn't that what you tried the first time?