How will you measure the Database Size?
I was asked in one of the interview which I have attended. I have little confusion. Is the db size means, all the db file size or only system tablespace size?
Can someone give explanation for this?
- Bala.
Printable View
How will you measure the Database Size?
I was asked in one of the interview which I have attended. I have little confusion. Is the db size means, all the db file size or only system tablespace size?
Can someone give explanation for this?
- Bala.
What a dumb question. "Database size" can mean raw data size, size of used blocks in tables, size of tables to high-water mark, total size of tables, tables + indexes, total size of data files, size of data files - (system+undo+temp),any of those things. Depends of the reason why you are asking.
Actually, maybe that's the right answer.
Generally It means the sum of all datafiles including your system datafiles.
select sum(bytes)/1024/1024 filesize_in_MB from dba_data_files;
What abt the tempfiles in the case of locally managed temporary tablespaces???? Right query should be..Quote:
Originally posted by k.chithra
Generally It means the sum of all datafiles including your system datafiles.
select sum(bytes)/1024/1024 filesize_in_MB from dba_data_files;
select a.bytes+b.bytes from
(select sum(bytes)/1024/1024 bytes from dba_data_files) a,
(select sum(bytes)/1024/1024 bytes from dba_temp_files) b
/
Hi chithra
Database Size= datafiles+control files+Redo log Files
Cheers
Murali
So if I have a database with one table that contains 20 rows and I have 100 2G datafiles, my db size is 200G?Quote:
Originally posted by dasari98
Hi chithra
Database Size= datafiles+control files+Redo log Files
Cheers
Murali
A good reply to any management request is "What decision will you base upon this?". It's a very intelligent thing to say and, best of all, it pisses them off no end!Quote:
Originally posted by slimdave
Depends of the reason why you are asking.
Actually, maybe that's the right answer.
But I will calculate in a different way (for the actual database size)
select sum(bytes)/1024/1024 "DB Size(MB)" from dba_segments;
Thomas
I have noticed that for many people it is as above, i.e., the sum of the sizes of the files. For me it is the used blocks: for example all that RMAN will backup within a full DB backup.Quote:
Originally posted by marist89
So if I have a database with one table that contains 20 rows and I have 100 2G datafiles, my db size is 200G?