Total Database Information At Your Fingertips Part - II

  • Comments posted to this topic are about the item Total Database Information At Your Fingertips Part - II

    [font="Comic Sans MS"]Rahul:-P[/font]

  • Thanks for sharing.

    Thanks

  • There is faster way how to determine total number of rows in table, then in all tables as well. If you have primary key on your table (so it doesn't works that simply for heap tables) you can just simply select rowcnt column on sysindexes where id = objectid('yourtable') and indid = 1.

    This gives you number of rows in your primary key, which is the number of rows in your table. Subsequently if all tables in your database has a PK, just simply sum all rowcnt columns in sysindexes table.

    Jan

  • Hi,

    See if this is something along your lines of DBA information/metadata also.

    You may be able to use/share the code.

    Oliver

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

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