Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

Databases Reporting with SQL Working with Text Concatenating Text

Jason Nutt
seal-mask
.a{fill-rule:evenodd;}techdegree seal-36
Jason Nutt
Front End Web Development Techdegree Graduate 24,760 Points

I really did not want to ask for help on this one as I think I understand the concept...here is the code I tried.

SELECT first_name || " " || last_name || " " || "<" "email" ">" AS "to_field" FROM patrons;

2 Answers

Jennifer Nordell
seal-mask
STAFF
.a{fill-rule:evenodd;}techdegree
Jennifer Nordell
Treehouse Teacher

Hi there, Jason Nutt! You're incredibly close. There is something slightly off with your concatenation around the email portion, though. First, we don't want the string "email", we want the value stored in the email field so instead of "email", I'm expecting just email. Secondly, you'll still need the concatenation operators between the angle brackets and the email field.

You have:

SELECT first_name || " " || last_name || " " || "<" "email" ">" AS "to_field" FROM patrons;

But I'm expecting:

SELECT first_name || " " || last_name || " " || "<" || email || ">" AS "to_field" FROM patrons;

Hope this helps! :sparkles:

Jason Nutt
seal-mask
.a{fill-rule:evenodd;}techdegree seal-36
Jason Nutt
Front End Web Development Techdegree Graduate 24,760 Points

It helps a ton. Thanks so much. I'm sure I will talk to you soon. Although the objective would be to avoid that by figuring out the solution myself. You are much appreciated Jennifer!