Reply to Re: splitting a comma seperated column into multiple rows

Your name:

Reply:


Posted by Razvan Socol on 12/05/33 11:37

Hi, Hennie

If you need the columns that are part of an index for a specified
table, you can use something like this:

SELECT i.name as IndexName, c.name as ColumnName
FROM sysindexes i
INNER JOIN sysindexkeys k ON i.id=k.id AND i.indid=k.indid
INNER JOIN syscolumns c ON c.id=k.id and c.colid=k.colid
WHERE i.id=OBJECT_ID('Order Details')

If you really want to split some other comma-delimited value (that
cannot be obtained in any other way), see this article by Erland
Sommarskog, SQL Server MVP:
http://www.sommarskog.se/arrays-in-sql.html

Razvan

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация