Results 1 to 6 of 6
  1. #1
    Join Date
    Sep 2007
    Posts
    10

    Unanswered: Query Result Output Size - Snapshot

    Hello Everyone,

    I need some help in determining the size (in mb,kb/gb) of the resultant output of a query in DB2.The Snapshot returns the number of rows read and written, is there a similar way I can get the size of the returned result in bytes.

    Thanks in Advance,

  2. #2
    Join Date
    Jan 2003
    Posts
    4,292
    Provided Answers: 5
    I do not think so.

    Andy

  3. #3
    Join Date
    Jan 2007
    Location
    Jena, Germany
    Posts
    2,721
    I am wondering: What would you want to do with such a number?

    It would be wrong anyway. The number of bytes read from disk is different due to the overhead of page headers and other data on pages. The number of bytes send over the network may be different too if you have some sort of compression or encryption in between.
    Knut Stolze
    IBM DB2 Analytics Accelerator
    IBM Germany Research & Development

  4. #4
    Join Date
    Sep 2007
    Posts
    10
    Thanks Stolze,

    I had received a request where they wanted all the queries which returned results of different sizes.
    I had thought of the option where we could multiply the record counts to the average size of the row we get from a snapshot. But this would not be easy with a query touching many tables and in a very short duration of time.

    Thanks,

  5. #5
    Join Date
    Jan 2007
    Location
    Jena, Germany
    Posts
    2,721
    Typically, such requests mean that the queries should have different selectivity and return a differing number of rows.
    Knut Stolze
    IBM DB2 Analytics Accelerator
    IBM Germany Research & Development

  6. #6
    Join Date
    Sep 2007
    Posts
    10
    Quote Originally Posted by stolze
    Typically, such requests mean that the queries should have different selectivity and return a differing number of rows.
    Stolze,

    Do we have a way which will return this information.I agree the number of rows differ and I was looking for a similar output as a snapshot provides rows written.

    Is there a limit on the data a snapshot returns and what is the value it depends on.Will it be able to return queries executed for a period of n days where the number of queries executed are in thousands and the size of queries is large.Currently I am running a snapshot every 30 mins so that I do not miss any query.

    Thanks in Advance,

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •