SQL syntax question

  • Thread starter Thread starter VB Programmer
  • Start date Start date
V

VB Programmer

In SQL how do you combine several fields AS 'xxxxx'.

This type of syntax doesn't work
SELECT MyPhone & "-" & MyCity AS 'MyInfo' FROM XXXXX WHERE....
 
+ should work, FirstField + SecondField but depending on the type, you may
need to cast it to a Varchar or respective type.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top