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 trialBrian Patterson
19,588 PointsWhy is this in the incorrect format?
SELECT first_name ||" "||last_name||" "|| email AS "To" FROM patrons
In code challenge.
2 Answers
Tobias Helmrich
31,603 PointsHey Brian,
you almost got it right but there are two problems in your SQL statement. Firstly the challenge wants you to alias the resulting text as to_field
instead of To
. The other problem is that you didn't wrap the email address inside of angle brackets.
If you fix those issues it should look like this:
SELECT first_name || " " || last_name || " <" || email || ">" AS "to_field" FROM patrons
I hope that helps! :)
Brian Patterson
19,588 PointsSELECT street || ", " || city || ", " || zip || ". " || country AS address FROM addresses Don't get why this didn't pass the second part of the challenge.
Tobias Helmrich
31,603 PointsYou almost got it right! You just forgot to also concatenate the state and a space before the zip code like so:
SELECT street || ", " || city || ", " || state || " " || zip || ". " || country AS address FROM addresses
I hope that helps! :)
Brian Patterson
19,588 PointsBrian Patterson
19,588 PointsThanks for your help Tobias.
Marc Hood
803 PointsMarc Hood
803 PointsThank you!!!