<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Concatenate Rows</title>
	<atom:link href="http://sqlserverplanet.com/sql/concatenate-rows/feed" rel="self" type="application/rss+xml" />
	<link>http://sqlserverplanet.com/sql/concatenate-rows</link>
	<description>Tips and Articles on SQL Server</description>
	<lastBuildDate>Mon, 06 Feb 2012 13:36:24 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
	<item>
		<title>By: Derek</title>
		<link>http://sqlserverplanet.com/sql/concatenate-rows/comment-page-1#comment-215</link>
		<dc:creator>Derek</dc:creator>
		<pubDate>Fri, 06 Aug 2010 16:42:37 +0000</pubDate>
		<guid isPermaLink="false">http://sqlserverplanet.com/uncategorized/concatenating-multiple-row-value-strings-into-one-column/#comment-215</guid>
		<description>Joey,

You can do it by joining against the table in the inline select.  Like this:


SELECT
    Table_Name,
    ColumnList = SUBSTRING(
                (SELECT
                    &#039;,&#039; + ISNULL(Column_Name,&#039;&#039;)
                FROM INFORMATION_SCHEMA.COLUMNS c
                WHERE isc.TABLE_NAME = c.TABLE_NAME
                FOR XML PATH(&#039;&#039;))
            ,2,8000)
FROM INFORMATION_SCHEMA.COLUMNS isc
GROUP BY TABLE_NAME

Good Luck, Derek</description>
		<content:encoded><![CDATA[<p>Joey,</p>
<p>You can do it by joining against the table in the inline select.  Like this:</p>
<p>SELECT<br />
    Table_Name,<br />
    ColumnList = SUBSTRING(<br />
                (SELECT<br />
                    &#8216;,&#8217; + ISNULL(Column_Name,&#8221;)<br />
                FROM INFORMATION_SCHEMA.COLUMNS c<br />
                WHERE isc.TABLE_NAME = c.TABLE_NAME<br />
                FOR XML PATH(&#8221;))<br />
            ,2,8000)<br />
FROM INFORMATION_SCHEMA.COLUMNS isc<br />
GROUP BY TABLE_NAME</p>
<p>Good Luck, Derek</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Joey</title>
		<link>http://sqlserverplanet.com/sql/concatenate-rows/comment-page-1#comment-214</link>
		<dc:creator>Joey</dc:creator>
		<pubDate>Fri, 06 Aug 2010 07:43:14 +0000</pubDate>
		<guid isPermaLink="false">http://sqlserverplanet.com/uncategorized/concatenating-multiple-row-value-strings-into-one-column/#comment-214</guid>
		<description>Hi,

Nice function, if you want to group this by a specified record, how do you handle this?
for example get all the order item id&#039;s on a row with one Order ID

Regards,
Joey</description>
		<content:encoded><![CDATA[<p>Hi,</p>
<p>Nice function, if you want to group this by a specified record, how do you handle this?<br />
for example get all the order item id&#8217;s on a row with one Order ID</p>
<p>Regards,<br />
Joey</p>
]]></content:encoded>
	</item>
</channel>
</rss>

