Welcome to Scribd, the world's digital library. Read, publish, and share books and documents. See more
Standard view
Full view
of .
Save to My Library
Look up keyword or section
Like this
P. 1
Oracle Tutorial

Oracle Tutorial

Ratings: (0)|Views: 1 |Likes:
Published by Lalit Shaktawat

More info:

Published by: Lalit Shaktawat on Jan 18, 2013
Copyright:Attribution Non-commercial


Read on Scribd mobile: iPhone, iPad and Android.
download as PDF, TXT or read online from Scribd
See more
See less





Lalit Shaktawat
Oracle and PL/SQL tutorial
: I am preparing this tutorial because I found if you know basics of Oracle/SQL/PL-SQL then you can have a chance to enter in IT Company orother Industries as a Database Admin. And there is lots of Scope in IT fordatabase handler. Now a days there are lots of database is available. MostPopular database is Oracle/SQL/Postgresql/Mysql/SQL Servre
Here I am trying to give some important information about SQL and PL/SQL.When we will start the discussion about database first you should haveknowledge about data.In my notes I will discuss some important interview questions. So pl. keeps allthe answer in your mind. It will definitely help you at the time of interview.Question: What is Data?Answer: Data is a collection of facts or which is typed from keyboard. It maybe numbers like 0 to 9, alphabets: A to Z or a to z.Question: What is Information?Answer: Collection of meaning full data is called information. Like APPLEDatabase: Database is an organized collection of data. Its content can easilyretrieve, update, add and delete. In database information can manage easily.Before giving introduction of Oracle we should know:DBMS
Database Management System. It is set of computer program orsoftware. It designed for specific purpose for creation, update, and retrieval of organized data from database. It store in computer hard disk. In DBMScollection of data is stored in file. It is called database. It is used to controlcreation of data, maintain and retrieval of data.DBMS Approach: it is a shared collection of logically related data, designed tomeet the information needs of an organization. So database approach willrenew.What is the advantage of DBMS?-
Control of data redundancy.-
Data consistency.-
More information from the same amount of data.-
Sharing of data.-
Improve data integrity.-
Improve security.-
Economy of scale.-
Balance conflicting requirement.
Lalit Shaktawat
Improve data accessibility and responsiveness.-
Improve maintenance through data independence.-
Increased concurrency.-
Improve backup and recovery service.There are some disadvantages
of DBMS…………
Complexity, Size, Cost of DBMSs, Additional H/W costs.-
Cost of conversion, Performance, Higher impact of failure.I will not discuss more about DBMS. Because some time Company will ask thedifference between DBMS and RDBMS (Oracle). I will give the answer for thesame in later.What is Oracle?Oracle is RDBMS (Relational Database Management System). RelationalDatabase, data stores in a form of Row and Column in Table. A table iscategory of data like employee and column have information about data like
Emp_no, Emp_name………….etc.
 What is the system architecture of oracle?In this section we learn the basic term of oracle, which are commonly used inoracle.In oracle database : database is a collection of data file and programs thatmanipulate those data files.Two type of data we can able to store in database:I.
User data : it is related to particular application.II.
System data : It is required to manage database itself.Component of Database:1.
Database File : It consist of physical storage of data. That means datawill store in hard disk. In oracle database we can make one o moredatabase file. These file contain data, which is accessible by SQL(Structured Query language). A file can be associated with one and onlyone logical file (Tablespace). When we create any database it consists of one and only one physical storage or physical file and one logical file.Logical file have information about data and index.Note: By default we can able to open 32 files at a time.2.
Control File : Physical architecture of databases are controlled bycontrol file. It is a binary file that is used to store physical information of database. Control file includes:
The database name.
Name and location of associate datafiles.
Timestamp of creation of database file.
Current log sequence number.
Checkpoint information.The control file automatically created by oracle at the time of creation of 
database. User can’t edit control file. With
out it oracle can not functioning.
Lalit Shaktawat
It is use full for backup and recovery.3.
Redo Log file : It contain all transaction that have occurred againstdatabase. When we will do any changes in database. It is used to storeall changes made in database. No activity takes place without recordingin redo log file. Redo log necessary to protect data loss. Redo log is alsocalled transaction logs. Every database required minimum of two redofile.It is used in recovery operations to restore lost and damage file.4.
Tablespace : When we create any database it create two files, One isphysical file and another one is logical file. Logical file is calledTablespace. It is a logical storage unit within oracle database. It islogical because tablespace is not visible in file system. It is build abridge between (logical and physical database) oracle database and filesystem, where indexes and data will store.Typically tablespace present in oracle database are:
SYSTEM : It is used to store information that will manage itself.
TEMP : Store all temporary table.
TOOLS : Store database objects that are need to supports differenttool.
USER : Information about user to store.
DATA & INDEXES : Hold the information about users.
ROLLBACK : Where all undo information is stored.5.
Data block : Datablock is a small logical unit to store oracle data.Onedatablock represent specific number of byte on physical storage of HDD.6.
Segments : All data in Tablespace are stored in allocation of databasespace. It is called segment. For each table there is a table segment. Forindexes, So called index segments are allocated. The segment associatedwith database object belongs to exactly on tablespace.-
In oracle there are five type of segments :
Data Segments
Index Segment
Rollback Segment
Temporary Segment
Bootstrap Segment7.
Extents : Is a collection of contiguous datablock. One or more segmentsmakeup a Segments. It express in byte.

You're Reading a Free Preview

/*********** DO NOT ALTER ANYTHING BELOW THIS LINE ! ************/ var s_code=s.t();if(s_code)document.write(s_code)//-->