• KGJ-Dev (11/30/2015)


    Hi Jeff,

    I would be using this against real table and not temp table. just to play with test data i gave temp variable and data on my sample. Still wondering why this couldn't be achieved using udf? Any sample for my requirement please.

    thanks

    Because UDFs don't allow the EXECUTE command, which is needed for dynamic sql.

    Luis C.
    General Disclaimer:
    Are you seriously taking the advice and code from someone from the internet without testing it? Do you at least understand it? Or can it easily kill your server?

    How to post data/code on a forum to get the best help: Option 1 / Option 2