I need to know the exact space taken by a table in a Oracle database on windows;
Just the table data and not the indexes;
Is there a query that can do this or better ?
thanks for that slightvw - what it really is is that we tested db2, oracle and sql server for a particular table which is rather large and has a lot of nullable columns with null values. We found that db2 and sql server used around 10GB to store the table whereas Oracle only used 1.2GB for tha same table. The only thing we could put this down to was that the table had a huge amount of nulls values. We cannot change the table as its an out of the box application table owned by a third party - could nulls really cause that much space difference ??
thanks
H
hraja77
ASKER
by the way slightw i appreciate and understand you point about allocated and used space but this is not an issue for us - thanks
slightwv (䄆 Netminder)
The bytes column provided by mrjoltcola is probably your best bet then.
I can only speak to Oracle and not at a very granular level on how Oracle does what it does internally.
Oracle treats a null as a true 'unknown'. It takes no space. You should only have an EOF character as a place holder but how Oracle actually 'stores' or handles it is over my head.
There are a LOT of discussion out there on the internals and what is actually happening 'under the sheets' but take it all with a grain of salt.
Do you think Oracle will tell SQL Server how it does what it does or visa versa?
If you can provide a little more information on the real reason you are asking these questions we can probably provide more information.
I agree with mrjoltcola from your previous question, you don't pick a RDBMS because of how it handles data storage. In the grand scheme of things, disk space is cheap.
If you are counting every byte, you might need to rethink the project. For example, Google doesn't use any of your reference databases...
thanks
H