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 trialDiego Herrera
3,273 PointsNeed help with SQL basics
We're back in our e-commerce database. There's a products table with the columns id, name, description and price. Can you retrieve both the name and description aliased as "Product Name" and "Product Description".
i answered: SELECT name AS "Product name", description AS 'Product Description'FROM products;
Why is it wrong?
2 Answers
joelearner
54,915 PointsHi Diego,
You have everything right but remember that for the challenges the requirements are very specific.
Here, make your query more consistent by having just double quotes(") or just single quotes('), like this:
SELECT name AS "Product Name", description AS "Product Description" FROM products;
Cheers!
Nicholas Grenwalt
46,626 PointsTry capitalizing "Name" in "Product Name" and make sure you are using double quotes around Product Description and also add a space after it before FROM and that should do the trick. So:
SELECT name AS "Product Name", description AS "Product Description" FROM products;
Diego Herrera
3,273 PointsThank you so much!
Diego Herrera
3,273 PointsDiego Herrera
3,273 PointsThank you!!!