Databases Reporting with SQL Working with Text Concatenating Text

Taylor Han
Taylor Han
2,405 Points

Concatenation with an alias

SELECT street || ", " || city || ", "|| state || " " || zip || ". " || country || AS addresses FROM addresses;

Wanting to combine each of these aliased as "addresses" but keep messing something up. I've tried to account for the commas and spaces

Any ideas?

Thanks!

1 Answer

Steven Parker
Steven Parker
203,995 Points

There are two issues:

  • there's a stray extra concatenation operator between the last field and the AS
  • the instructions say "Alias the concatenated string as address" (singular)
Taylor Han
Taylor Han
2,405 Points

That did the trick, thank you! Been driving me nuts