Database Reference
In-Depth Information
creating tables' structure and assigning them data types and once
you have all the tables required by that department then you can
start implementing primary and foreign key relationships
between those tables on paper (I mean not actually implementing
using CREATE TABLE statement).
Developing Primary/Foreign Key relationship helps in reducing
redundancy of information or Data. Once we reach a level where
we can say that no further relationship is required and
redundancy of information has came to its minimum then we can
estimate the size of each table. Let's see how? I want to take
your mind to the CREATE TABLE statement, when you
described data types for each column. Let's suppose we have a
table named “address_book” where we are maintaining just the
name and addresses of people. It has a “name” column and
“address” column as shown below.
Table: addres_book
name VARCHAR2(20)
address VARCHAR2(200)
Keeping in mind that it takes one byte to store one character,
usually. We can easily estimate the size of one record in this
address_book table in terms of bytes. So the formula of finding
out the estimated size of table is given below.
Estimated Size Of Table (Bytes) = Size Of A Record (Bytes) X
Total Number Of Records
So in our scenario the size of record would be (200 + 20) 220
bytes and if initially we have to place 100 people information in
it then the “initial” estimated size of table would be (220 X 100)
22,000 bytes or 22 KB. Following on the same lines we can find
out the “initial” estimated size of all the tables for that particular
department.
It's recommended to have at least one tablespace created for
each department. So the sum of the initial estimated sizes of all
the tables within that department will give us the initial estimated
Search WWH ::




Custom Search