SQL Table Size and last modified date
Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
imaran_669
8 - Asteroid
‎07-13-2021
08:24 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi Comunity, im doing a process to do some manteinance to my SQL server. Im currently listing all tables with this SQL comand:
SELECT * FROM information_schema.tables
Im wondering if its posible to:
1) List the size (disk space) of those tables.
2) Check the last time they were modified
Is this posible?
Regards,
Labels:
- Labels:
- Database Connection
1 REPLY 1
19 - Altair
‎07-14-2021
05:18 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi @imaran_669
Assuming the size and last modified date is returned by this query, you can put this query into an Input Data tool and the results will be there. This requires that the account that you're running with has permission to read information_schema.tables.
If the data isn't returned, then you need to do some digging into the specifics of SQL server. For instance, this page gives a query to return the table sizes.
Dan
