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 trialsailor winkelman
2,603 Pointshow to add characters while concatenating text?
I am looking at challenge task 1 in Reporting with SQL > Concatenating Text Challenge.
SELECT first_name ||" "|| last_name ||" "|| email AS to_field FROM patrons;
I need to get angle brackets around the email addresses when I concatenate the first name, last name and email address. I realize it should just be like adding the space between text in quotation marks, but struggling on where to place the angle brackets and their " ".
thanks :)
2 Answers
Steven Parker
231,261 PointsYou're already adding characters ... spaces
You could put the first angle in with your space between name and email:
" " " <"
Then you just need to add the closing angle on the other side of the email:
|| ">"
Derek Gannon
Courses Plus Student 1,140 PointsCan you give an example of placement of the above in a query? I am not understanding.