Databases Reporting with SQL Working with Text Concatenating Text

Jeremy Jones
Jeremy Jones
885 Points

Unclear what I am getting wrong...

Challenge Task 1 of 2 for the Contenation exercise, inputting code as:

SELECT first_name || " " || last_name || " " || email || AS "to_field" FROM patrons

And it only tells me "Something's wrong."

I wish it would show you the correct answer so you could learn instead of just telling you it's wrong...

2 Answers

KRIS NIKOLAISEN
PRO
KRIS NIKOLAISEN
Pro Student 44,108 Points

You are missing angle brackets <> that enclose the email.

Jeremy Jones
Jeremy Jones
885 Points

Right, but I am unclear on how it wants me to get that part in; I tried several ways and it keeps telling me I'm still wrong.

Jeremy Jones
Jeremy Jones
885 Points

(thank you for responding)

KRIS NIKOLAISEN
PRO
KRIS NIKOLAISEN
Pro Student 44,108 Points

I'm assuming you got it by now - but just in case

SELECT first_name || " " || last_name || " <" || email || ">" AS "to_field" FROM patrons
Jeremy Jones
Jeremy Jones
885 Points

Thanks Kris; I feel like it's troubling because there wasn't anything in the lesson I recall about being able to leave a "dangling concatenation" (for lack of a better term of what to call it when I don't close it on both side with the pipes)...