How big would such a database be?

I am trying to figure out how big a particular database will be (it has not yet been created). I know how many rows and which tables will be. Is there a feature in Oracle that will tell me the size of such a theoretical database? Is there a known mathematical formula that I can use? I know that there is a function for determining the size of an existing database, but I want to know how big it will be before I create it.

+4
source share
5 answers

You can specify the data size for the columns in the table. Then you can get a rough estimate of the row size in this table. then for 1 to n tables, then for 1 row in 1 table for x rows in x tables = database estimate for a given row.

The long arm that I know, but that’s how I usually do it.

+5
source

You can try to prototype your design - create the initial version of the database and write several scripts (or use the tool) to populate tables with a reasonable amount of data. Then you will know exactly how much space X lines occupy. If this is too much, you can return to the drawing board with your design. I know that you need a figure before creating a database, but you can never take into account everything that happens with physical data files under the hood.

+7
source

To be precise, it can become really complicated. For example, this is how you do it on MS SQL Server:

http://msdn.microsoft.com/en-us/library/aa933068(SQL.80).aspx

+1
source

You also need to include indexes in your ratings. I saw systems where indexes were as large as data. The only way I could trust is to do prototyping, as Eric Z Beard suggests. Different database systems have different overheads, but they all have.

+1
source

Having the exact size was not too important, so I went with the littlegeek method. I figured out what my tables and columns would be, and looked for the sizes of data types , then did some good ole multiplication.

0
source

Source: https://habr.com/ru/post/1276335/


All Articles