You might want to have a look at the following link:
http://www.sqlservercentral.com/articles/T-SQL/68467/
I think it has all the information to resolve the task you ask for.
If you don't feel confident using the "quirky update" method you might want to take the time following the discussion related to that article. There is a (slightly slower) alternative "somewhere in between".
If you need any further assitance please read the first link in my signature on how to post data.
Lutz
A pessimist is an optimist with experience. How to get fast answers to your question[/url]
How to post performance related questions[/url]
Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]