Resultset Size

  • I have t-sql query, in which I do some transactions and return a result set. After I execute the query, I need the size of resultset. The resultset may vary from execution to execution.

    How to calculate the size of resultset?

    Thanks in advance.

  • Do you mean the number of rows returned?

    Gethyn Elliswww.gethynellis.com

  • I don't need number of rows, but I need the size of data in all rows in KB / MB.

  • don't know if there is an easy way of doing that other than summing the size of the data types of all rows returned and then multiplying that by the no of rows returned.

    Gethyn Elliswww.gethynellis.com

  • I need to check the number of rows in a result set returned by a query in execute SQL task and execute different tasks based on the number of rows. Please let me know the steps for doing this.

    Thanks

  • bnarav (7/16/2008)


    I need to check the number of rows in a result set returned by a query in execute SQL task and execute different tasks based on the number of rows. Please let me know the steps for doing this.

    Thanks

    check out @@rowcount in the BOL.

    ---------------------------------------------------------
    How best to post your question[/url]
    How to post performance problems[/url]
    Tally Table:What it is and how it replaces a loop[/url]

    "stewsterl 80804 (10/16/2009)I guess when you stop and try to understand the solution provided you not only learn, but save yourself some headaches when you need to make any slight changes."

  • Is there a way to do this, calculate the size of the resultset in kb/mb

Viewing 7 posts - 1 through 6 (of 6 total)

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