Capture procedure(s) results in table(s) dynamically

  • I have been tasked with creating a process by which we can define a set of procedures to run and capture their respective outputs to tables (yet to be designed) for later comparison.

    I am aware that code could be written specifically for each proc, but what I am hoping, is that this could be achieved via code or that someone here knows of a product on the market that accomplishes this.

    The end game here is to be able to easily add and remove procedures to and from this test group. and to account for all of the possible outcomes (multiple result set procs, diff. data types etc...

    Thanks in advance.:-P

    ______________________________________________________________________

    Personal Motto: Why push the envelope when you can just open it?

    If you follow the direction given HERE[/url] you'll likely increase the number and quality of responses you get to your question.

    Jason L. Selburg
  • What about a CLR Assembly?

    -- Gianluca Sartori

  • Have you tried INSERT/EXEC?

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a ROW... think, instead, of what you want to do to a COLUMN.

    Change is inevitable... Change for the better is not.


    Helpful Links:
    How to post code problems
    How to Post Performance Problems
    Create a Tally Function (fnTally)

  • You can use "select * into table from OpenRowset / OpenQuery (executing your stored procedure)".

    Wayne
    Microsoft Certified Master: SQL Server 2008
    Author - SQL Server T-SQL Recipes


    If you can't explain to another person how the code that you're copying from the internet works, then DON'T USE IT on a production system! After all, you will be the one supporting it!
    Links:
    For better assistance in answering your questions
    Performance Problems
    Common date/time routines
    Understanding and Using APPLY Part 1 & Part 2

  • Jeff Moden (3/25/2011)


    Have you tried INSERT/EXEC?

    That's what I've ended up doing. Although to be dynamic is taking some more work.

    ______________________________________________________________________

    Personal Motto: Why push the envelope when you can just open it?

    If you follow the direction given HERE[/url] you'll likely increase the number and quality of responses you get to your question.

    Jason L. Selburg

Viewing 5 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic. Login to reply