Sie sind auf Seite 1von 95

c 

    

Course Developed by - KKN


      


J   

  
  
 
Course Developed by - KKN
      

xefore Computerization the data/information was
available only in the paper/documents.
The need to store massive data and retrieve it faster
necessitated Computerization.
Thus lot of efforts were put in to automate the manual
working into automation.

Course Developed by - KKN


      

Why Computerized Database ?
`anual System is:
- Tedious
- Time Consuming
- Error Prone
- Illegible

Course Developed by - KKN


      

ëdvantages of Computerization
-`inimizations of Errors
- Saving of Time in processing/working
- ëvailability of data at one place
- Legible -Reports are presentable

Course Developed by - KKN


      

Definition:
ë   
     
 
               
   
 
ë           

  
 
           
   
  ë   

           
 


          

Course Developed by - KKN


      

Rome More Definitions:
ë          

           
    

ë        
     
    
  
        
   

Course Developed by - KKN


      

Rome More Definitions:
ë   
        
     
 !
   

               
       
  

ë   
         
              

Course Developed by - KKN


      

xefore the era of the RDx`S there were a variety of
different species of data file structures. Each were
specific to the application program code which
implicitly defined it.
The organization's intelligence/ logic of the Output
used to reside in the program code used to manipulate
the data files/structures.

Course Developed by - KKN


      

The Hardware requirements were for a machine and
its peripherals sufficient for the needs of the
organization.
Vhe requirements were: One Hardware
vendor. ëdditionally, separate requirements always
existed for some form of database application software
code specific to that organization.

Course Developed by - KKN


      

ës the ëpplications did not exist in the
beginning, they had to be written.
§equirement: One or more Roftware developer.
This could involve literally one or more programmers,
or Consultants depending on scale.

Course Developed by - KKN


      

With the passage of time:
- Systems and their environments evolved,
- Complexity increased,
- Data requirements grew year by year.
The IT Problem was dealt with on day-to-day basis.
Database storage technology was under pressure and it
needed to evolve. The task of managing constantly growing
Data and its structures was becoming an occupational hazard
for IT `anagement and operational staff.

Course Developed by - KKN


      

Thus in the mid / late 1960's the Database
`anagement System (Dx`S) came into
existence.
The Dx`S became necessary because the data was far more
volatile than had earlier been planned, and because there were
still major limiting factors in the costs associated with data
storage media. Data grew as a collection, and it also needed to
be managed at a detailed transaction by transaction level.

Course Developed by - KKN


      

The first Dx`S species were thus very much
vendor specific. Ix` as usual led the field, but
there were a growing number of competitors
and clones whose database solutions offered
varying entry points into the bandwagon of
computerized record keeping systems.

Course Developed by - KKN


      

      ë  "      
 

             


        
  # 
      $  
 
 ë   
     %  
   
       & '  

        
&               
       

       


               
      
         
   (   )    
  
(   ) *'"

Course Developed by - KKN


      


J  

 

Course Developed by - KKN


      

cf there is no Database :
1. Data will be scattered
2. Data is not cohesive ± may be having different formats
3. Data is duplicated
4. Data Integrity is not possible
5. Data has big risk

Course Developed by - KKN


      

To put them together a Database is needed
which will have:
- Database
- Tables
-Records
- Fields

Course Developed by - KKN


      

Data Vypes commonly used:
- Numeric
- ëlphanumeric
- Date
- Logical
- `emo

Course Developed by - KKN


      

Numeric ± This data type specifies that the field can contain
only numbers.The numbers could be:
- Whole Number e.g. 2,55,999 etc.
- Real number e.g. 23.75,49.55 etc.
ëlphanumeric- ë combination of alphabets, numbers and
special characters like hyphen etc. may be stored in
this field. The data could be of following types:
- Numbers - 0 to 9
- ëlphabets ± ë to Z, a to z
- Special Characters - !@#$%* etc.

Course Developed by - KKN


      

Date ± In this field only date can be stored. The date may
have different formats. Some databases
provide Time also along with the date format.ë
data type that can handle date and time may have
following :
Date ± Day
- `onth
- Year
Time ± Hour
- `inute
- Second

Course Developed by - KKN


      

Logical ± This field can contain only True/false or Yes/No i.e.
The field can contain only logical value.This data type
is also known as xoolean.

`emo ± This field can contain large amount of data e.g. 100/
200/500 words. It can have alphanumeric data, but this
can be used only for comment purposes.No manipulation
on this field is possible.

Course Developed by - KKN


      

Rpecifying the Field Rize:
ëlong with the Data type for a field, we also
need to specify the field size.Specifying the
size means that the maximum data of a
particular data type that can be stored in the
field.

Course Developed by - KKN


      

Rize Description Actual Rize
cndicator (in Bytes)

xyte Can Store only positive numbers in the 1


range of 0 to 255

Integer Can handle whole numbers in the range of 2


-32,768 to 32,767
Can handle whole numbers in the wide range of
Long -2,147,483,648 to 2,147,483,647. This data
4
type cannot handle real numbers.
Can handle real numbers in the range of:
Double -1.79769313486232E308 to 1.79769312486232E308

Course Developed by - KKN


      

Similarly ,some common alphanumeric data types are:

Data Vype Description Actual Rize(in Bytes)

Char Can store a single 1 xyte


character
String Can be used to store There is no pre-determined
ëlphanumeric data of size.The size is determined
varying length by the number of characters
stored.Generally it is from
1023 bytes to 2 million
bytes.

Course Developed by - KKN


      

What is a Vable?
ë table consists of :
-Rows
- Columns
- Data Elements

Course Developed by - KKN


      

Tables are used for Data `anipulation such as :

-ëdding records
- Querying
- `odifying Records
- Deleting Records

Course Developed by - KKN


      

Data Manipulation:
Creating a table involves the following:
- Specifying field names for different fields
- Specifying data types for the different fields
- Specifying field sizes for the different fields

S_No Item-Code Ord_no Ord_Date Qty

Course Developed by - KKN


      

ëdding Records to a table:
When the table is created, it does not contain any data.
On adding data, the table will look like:

S_No Item-Code Ord_no Ord_Date Qty

111 RKSK-T 001/05 08/08/05 100

Course Developed by - KKN


      

ë        
    
- ëdded
- `odified
- Deleted

Course Developed by - KKN


      


      


 ë      
       

o   
o"
o"%
o+
 

Course Developed by - KKN


      

ëll these will be independent data files/tables having
details like:
   ,
- Staff No.
- Name
- ëddress
- Qualifications
- Salary
",
-Roll No.
- Name
- ëddress
- ëttendance
- Year

Course Developed by - KKN


      

Subject:
- Subject No.
- Subject Name
- Year at Which the Subject is taught
- Teacher who teaches the subject
Examination:
- Exam No.
- Subject for Which the Exam was conducted
- Teacher responsible for the exam
- Student (appearing for exam)
- marks Obtained

Course Developed by - KKN


      

Thus we can see there is no relation between the tables;
Therefore if we want to refer to another table we cannot
as we do not find any link between the tables.

If we want to refer another table, which is often required,


ë relation need to be developed so that tables can be referred
and data can be picked up.
Thus we need to have database where we can have relations
xetween the tables. Such databases are known as RDx`S
(Relational Database `anagement System)

Course Developed by - KKN


      

Thus following need to be kept in mind:
1. The data to be stored in a single database since it
pertains to a single subject.
2. The distinction between the various groups should be
maintained since different types of details are stored
for each group.
3. We must have atleast one common field through
which relation between tables can be established.

Course Developed by - KKN


      

Thus in the College Database discussed earlier, we can
Establish following relationship:
-Relationship between Roll No. from the Student table
and Roll No. from the Exam table
- Relationship between Staff No. from the Teacher table
and Staff No.from the Exam table
- Relationship between Subject No. from the Student
table and Subject no.from the Exam table
- Relationship between Staff No. from the Teacher table
and Staff no. from the Subject table

Course Developed by - KKN


      


Thus you can establish relations using fields in each table.

Course Developed by - KKN


      

COMPONENVR OF DBMR:
iDAVA DEFcNcVcON LANGUAGE:
oDefines Data Elements in Database
i DAVA MANcPULAVcON LANGUAGE:
o`anipulates Data for ëpplications
oSQL
i DAVA DcCVcONA§ :
oFormal Definitions of all Variables in Database;
Controls Variety of Database Contents

Course Developed by - KKN


      

ADVANVAGER OF §DBMR:
† §educes Complexity
† Reduces Data Redundancy
† Central Control of Data
† Reduces Program/ Data Dependence
† Reduces Development/maintenance Costs
† Enhances System Flexibility
† Increases ëccess/ëvailability of Information

Course Developed by - KKN


      

Emergence of the §DBMR
The Relational Database concept was thought about by folks
who on a day-to-day basis had to manage large production
data structures in the 1960's and 1970's and 1980's and 1990's
and today. xut it was probably Codd (Dr. E.F.) who first
published (in an Ix` Research Report of ëugust 1969) some
form of specification (set) of rules by which such a species of
database would be known ...

Course Developed by - KKN


      

CODD's VWELVE §ULER
§ule 1: Vhe cnformation §ule: ëll information in a
relational database is represented explicitly at the logical level in
exactly one way by values in tables.

§ule 2: Guaranteed Access §ule: Each and every datum


(atomic value) in a relational database is guaranteed to be logically
accessible by resorting to a table name, primary key value, and
column name.

Course Developed by - KKN


      

CODD's VWELVE §ULER
§ule 3: Rystematic Vreatment of Null Values: Null values
(distinct from empty character string or a string of blank characters
and distinct from zero or any other number) are supported in the fully
relational Dx`S for representing missing information in a systematic
way, independent of data type.

§ule 4: Dynamic On-line Catalog Based on the


§elational Model: The database description is represented at the
logical level in the same way as ordinary data, so authorized users can
apply the same relational language to its interrogation as they apply to
regular data.

Course Developed by - KKN


      

CODD's VWELVE §ULER
§ule 5: Comprehensive Data Rublanguage §ule: ë
relational system may support several languages and various modes
of terminal use (for example, the fill-in-blanks mode). However, there
must be at least one language whose statements are expressible, as per
some well-defined syntax, as character strings and whose ability to
support all of the following is comprehensible: data definition, view
definition, data manipulation (interactive and by program), integrity
constraints, and transaction boundaries (begin, commit, and rollback).

§ule 6: View Updating §ule: ëll views that are theoretically


updateable are also updateable by the system.

Course Developed by - KKN


      

CODD's VWELVE §ULER

§ule 7: High-level cnsert, Update, and Delete: The


capability of handling a base relation or a derived relation as a
single operand applies not only to the retrieval of data but also to
the insertion, update, and deletion of data.

§ule 8: Physical Data cndependence: ëpplication


programs and terminal activities remain logically unimpaired
whenever any changes are made in either storage representation or
access methods.

Course Developed by - KKN


      

CODD's VWELVE §ULER
§ule 9: Logical Data cndependence: ëpplication programs
and terminal activities remain logically unimpaired when information
preserving changes of any kind that theoretically permit unimpairment
are made to the base tables.

§ule 10: cntegrity cndependence: Integrity constraints specific


to a particular relational database must be definable in the relational data
sublanguage and storable in the catalog, not in the application programs.

Course Developed by - KKN


      

CODD's VWELVE §ULER
§ule 11: Distribution cndependence: ë relational Dx`S
has distribution independence. Distribution independence implies
that users need not have to be aware of whether a database is
distributed.

§ule 12: Nonsubversion §ule: If a relational system has a


low-level (single-record-at-a-time) language, that low-level
language cannot be used to subvert or bypass the integrity rules or
constraints expressed in the higher-level (multiple-records-at-a-
time) relational language.

Course Developed by - KKN


      

Important: There is a rider to these 12 rules known as §ule
Zero: â 
   
   
 


 

  

             â


On the basis of the above rules, there is no fully relational
Dx`S available today.

Course Developed by - KKN


      

ë   
       
3              
-      
 
  
(*'")
            
    

  
   
. '           
   
. +                 
         
. /            
    
   

Course Developed by - KKN


      

Vypes of Databases
        /*'"    


" 
    #   
    

    ' 
      
 
    ë  ,
i 
  0  " 

i /     /    " 

i 
  &   

Course Developed by - KKN


      

   
         
     !
- ë  
.  
. &

 

Course Developed by - KKN


      

ë   
*            
      
                    

      
       ë
              

                    
                  
                   
        
       
   ,     "#     
$

Course Developed by - KKN


      

 
m       
     
               
              
                
              
          

           

Course Developed by - KKN


      

%    
m                

          
ë             
   
  
0                
    
   
  # 
        
  

ë   
     
 % 
            
               
  ,

Course Developed by - KKN


      

Rome cmportant Considerations:
3    #  1    
  
          
   
            


2. + ..     1 &        


       
       

        &   
  
           
     
      

3.  
  .     1
#  
     

2 #        1
"              
          '  
               

       
      
   

Course Developed by - KKN


      

Some of the Common Databases are:
- `S-ëccess
- Oracle
- `S-Sql Server 2000
- Sybase
etc.

Course Developed by - KKN


      

All the databases provide the facility to
work with:
Vables ± Containing Data
Queries ± Selected information is displayed
on the screen
§eports ± Formatted Printed information
Forms ± Screen Created to add,modify and delete records

Course Developed by - KKN


      

Vasks that involved with Vables are:
Creating a Table
- Specify field names
- Specify data types
- Specify field sizes
etc.

Course Developed by - KKN


      

Vasks that involved with Queries are:
Creating Queries to obtain information by:
- Specifying conditions on the basis of which
data is fetched from one or more tables
- Specifying fields on the basis of which the
data is to be sorted

Course Developed by - KKN


      

Creating queries to update the data by:
- Specifying conditions to determine which
records are to be updated

Creating Queries to delete the data by:


- Specifying conditions to determine
which records are to be deleted
      

Report ± This is the final presentation of the data captured.
The report is easy-to-understand and good-to-look at.
The report may generated from one or more tables
depending on the requirement.
The tasks involved are:
Creating a Report by:
- Specifying the table or query from which the
report is to be created.
- Specifying the fields from the above that are to
included in the report
- Formatting the Report

Course Developed by - KKN


      

Forms ± These are used of entering/modifying and
deleting the data.

The tasks involved are:


Creating the Forms by:
- Specifying the table or query from which the
form is to be created.
- Specifying the fields from the above that are to
be displayed in the form
- Formatting the form

Course Developed by - KKN


      

RDx`S ±make things easier for the user, if it provides
the facility of some basic functions like:

-ëdding records
- Querying
- `odifying Records
- Deleting Records

Course Developed by - KKN


      

  

  
      
  

   

           


         
  
         

 !     
 

Course Developed by - KKN


      



  

 
 

Course Developed by - KKN


      

The Databases may be classified as:

-Data /Text stored in an ëSCII File


- Data stored in a xinary File (Cobol,xasic etc.)
- Data stored in a Database
- Data stored in RDx`S
- Data stored in Web Server

Course Developed by - KKN


      

      ë
%%& 

      ë"&&    


 
         

    
          
   
    
    

Course Developed by - KKN


      

Data Rtored in a Binary File
&                 
   *   &           
   

     
  
              
 
 

 
    
 


Course Developed by - KKN


      

  
      
ë          * &&
           
     
         # 

  
 
  
      
    

Course Developed by - KKN


      

  
   #      
/        
    
            
    

     
      
        

0    
         
 
       

  


          , ë  "


"   m  "  

Course Developed by - KKN


      


ë  


 
Course Developed by - KKN
      

 ë       

 /     
 '          
    .
  .
  
 ë     
 /      

 "    

Course Developed by - KKN


      


Course Developed by - KKN


      

´     
            
             
          '    ( 
            
        
   )ë      
 
 )
       
 '   (     
     

Course Developed by - KKN


      

Advantages of §DBMR
 ë    
ë       ' 
*(
           
        

  
           
 

Course Developed by - KKN


      

 &    
          
          
    

 %  
        
            

Course Developed by - KKN


      

 6      
        
        

   


%         
         
        
   
 )  # 

  

Course Developed by - KKN


      

            
          
 )
       
    
     
 

   
 " 
 

Course Developed by - KKN


      

A word about RQL(Rtructured Query Language)
"30               

 
  
  m  " 
&
 '   "30 "   ë 
"30                

      

Course Developed by - KKN


      

"30     
     
  
  +            
 ,
 " 4  

  
 
 
   
 $ 
 ë
 

Course Developed by - KKN


      



   


 

Course Developed by - KKN


      

J          
        
          
  #    " 
 
     
      
 

            
 
      
       
          
  
        
       

             
  
  
             

Course Developed by - KKN


      

  3 
"             
  
                
        
       
            
      5
              
  
 
 

Course Developed by - KKN


      

  %  
"   
           
               
    
        
      
  
  
      
   
 
     
 
            
                

Course Developed by - KKN


      

  ´    
                


          
       
           
    

      
          
    
           
         
        

Course Developed by - KKN


      

   )

        
     
 
  .        "
 
  66           
        ë       

            
   


              
           

Course Developed by - KKN


      


w 


 

Course Developed by - KKN


      

      #   
        
3 /*'"         
   
     
   
          
  
         

  
- /*'"           
"30

Course Developed by - KKN


      

    # 

     77 % 


"           
/*'"

2   /*'"       


        
    

Course Developed by - KKN


      


J 
 


J    

Course Developed by - KKN


      

Data Warehousing
Definition
ë            
         
     
+         
. ,         
    
. %          
            
+ %            

Course Developed by - KKN


      

         
  ) % '%
 (
 "%.  .       %    
  
.     
          
 
   

   
       
  (   )
.      
       
  

Course Developed by - KKN


      


 %  .          


. 
    8'6  86  9  3 
    
  
    
 
            

    

Course Developed by - KKN


      

-Time-variant - the data warehouse contains a place for
storing data that are 5 to 10 years old, or older e.g.
- this data is used for comparisons, trends, and
forecasting
- these data are not updated
- Non-volatile - data are not updated or changed in any
way once they enter the data warehouse data are only
loaded and accessed

Course Developed by - KKN


      


 

Das könnte Ihnen auch gefallen