SQL question

  • Thread starter Thread starter John Bailo
  • Start date Start date
J

John Bailo

Is there a way to select a whole row of fields as a single string?

Such as:

SELECT * AS [WHOLESTRING] From mydb.dbo.mytable

?
 
Is there a way to select a whole row of fields as a single string?

Such as:

SELECT * AS [WHOLESTRING] From mydb.dbo.mytable

?

You can concatenate fields together in SQL:

SELECT colA + ';' + colB FROM myTable

Of course you will have to cast everything to a character type for
this to work. But why would you want to do this?
 

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