May 20, 2010 at 5:38 pm
Not sure if you got notification of an additional post so trying one more time. Did the code I post solve your problem? If not, let me know and I'll help you tweak it.
--Jeff Moden
Change is inevitable... Change for the better is not.
May 20, 2010 at 8:39 pm
Hello Jeff,
Thank you for that code, I really appreciate it. Sorry, for the delay in getting back to you. One word, deadlines. :pinch: I was able to find a solution that is a little rough not at the database level, but in code. I tried the first solution, but I think I didn't understand it, and with the time crunch I just whipped up a workable solution in code. I think it is a little slow, but I can't spend anymore time on it right now. I want to revisit this part of the project after I meet our initial deadline, so I might be asking some more questions. I will study your solution in my spare time so I understand it better when I get back to that part of the project.
Thanks again for your help. Sorry we got off on the wrong foot.
Ben
May 20, 2010 at 10:54 pm
Not to worry... and thanks for the feedback. 🙂
If you want to learn more about the dynamic SQL Cross Tab I used, please see the following articles. Of course, questions are welcome.
http://www.sqlservercentral.com/articles/T-SQL/63681/
http://www.sqlservercentral.com/articles/Crosstab/65048/
The first article explains what a Cross Tab is, how it can be used, and why it's better (IMHO) than PIVOT.
The second article explains how to easily create dynamic Cross Tabs like the one in my code (although I did add a little 2k5 magic to this one).
--Jeff Moden
Change is inevitable... Change for the better is not.
Viewing 3 posts - 16 through 17 (of 17 total)
You must be logged in to reply to this topic. Login to reply