Results 1 to 5 of 5
  1. #1
    Join Date
    Jan 2005

    Unanswered: Size of a single Database

    Hello Forum,

    this is my first posting here and I am looking forward to join your community!

    I am using IDS 9.40 on Win2003. Are ther any scripts, working with this Version on this OS, that determin the size of a single Database?
    I hope, this Question is not too simple for you and bothering you, but I am in Trouble and I need your help.

    Greeting Mark

  2. #2
    Join Date
    Jan 2005

    Lightbulb Get your database size

    Try the following SQL. Database size will be in pages. You need to multiply it with the page size you are using.

    DATABASE sysmaster;
    SELECT dbsname Database, SUM(size) TotalSizeInPage
    FROM sysextents
    GROUP BY dbsname

    Sanjit Chakraborty

  3. #3
    Join Date
    Mar 2004
    Hi Mark,

    It is quite easy to get the database size of normal datatypes. Especially large objects (blobs) and smart blobs are rather difficult to specify per database. To get the info you need just use the following sql:

    select sum(size) as nr_of_pages
    from sysmaster:sysextents
    where dbsname = '<dbname>'

    This is just one of the methods. You can also use the systabnames and sysptnhdr tables in the sysmaster database to get the info. This will even give you a more detailed look because woth this you can get all allocated pages (like in previous query), but also all used and data pages.

    Hope this helps,

    Rob Prop

  4. #4
    Join Date
    Jan 2005
    THX for your help.

    but this method ist obviously not exact enough.
    My dbspace is about 70 GB and the addition of all databases is about 72 GB.

    The difference of 2 GB ist not acceptable for my purposees.

    BTW: I am not using Blobs etc.

  5. #5
    Join Date
    Jan 2005
    It is impossible that previous SQL giving wrong information. I am sure you are not considering something in your 70 GB calculation. Verify what all you have in the database with ‘oncheck –pe’ output.


Posting Permissions

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