changing the output format in select statement

  • i get values in a coulmn NAME (- column name) as rows

    i need to get the output in a single line

    Example

    select Name from customers where id in(@id1,@id3)

    i get the output as

    Name - column name

    John

    Smith

    I need the output as

    Name - column name

    John And Smith

  • Take a look at this excellent article on how to concatenate row values:

    Concatenating Row Values in Transact-SQL[/url]

    Need an answer? No, you need a question
    My blog at https://sqlkover.com.
    MCSE Business Intelligence - Microsoft Data Platform MVP

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply