• richard.noordam (11/28/2012)


    i do have to say, you should give yourself a bit more credit, as our private message indicated you did understand my problem, and did suggest a potential solution, which did indeed change the approach i was using for that section of the problem....

    to a 75% decrease in run time as well.

    and it's beginning to apease my need of a bit more elegant solution. 😉

    THANKS!!!

    Thanks Richard. It still uses a cursor but it is better at least. As I said in our PM the problem in helping come up with a generic solution is the language required to explain it is sql. And since we didn't have ddl to work with I couldn't write said sql. It would be really cool of you to post the solution I sent you (I didn't save a copy of it myself). That way anybody in the future who stumbles on this thread will be able to see a way to solve it. 😀

    _______________________________________________________________

    Need help? Help us help you.

    Read the article at http://www.sqlservercentral.com/articles/Best+Practices/61537/ for best practices on asking questions.

    Need to split a string? Try Jeff Modens splitter http://www.sqlservercentral.com/articles/Tally+Table/72993/.

    Cross Tabs and Pivots, Part 1 – Converting Rows to Columns - http://www.sqlservercentral.com/articles/T-SQL/63681/
    Cross Tabs and Pivots, Part 2 - Dynamic Cross Tabs - http://www.sqlservercentral.com/articles/Crosstab/65048/
    Understanding and Using APPLY (Part 1) - http://www.sqlservercentral.com/articles/APPLY/69953/
    Understanding and Using APPLY (Part 2) - http://www.sqlservercentral.com/articles/APPLY/69954/