Rdbms Practical file diploma

Post on 21-Apr-2017

84 views 5 download

transcript

RELATIONAL DATABASE MANAGEMENT SYSTEM

SUBMITTED TO: SUBMITTED BY:

LECT. ROHIT GOYAL MUSTKEEMADD.NO.:14S121

BRANCH: 5 CS.

DIGAMBER JAIN POLYTECHNIC BARAUT BAGHPAT

Admission no.:14S121

Page | 1

INTRODUCTION OF RDBMS:

RDBMSs have been a common choice for the storage of information in new databases used forfinancial records, manufacturing and logistical information, personnel data, and other applicationssince the 1980s. Relational databases have often replaced legacy hierarchicaldatabases and network databases because they are easier to understand and use. However,relational databases have received unsuccessful challenge attempts by objectdatabase management systems in the 1980s and 1990s (which were introduced trying to addressthe so-called object-relational impedance mismatch between relational databases and object-oriented application programs) and also by XML database management systems in the 1990s.

REQUIREMENT OF RDBMS (11g Release 2 32 bit):

Hardware Requirement:

IBM- Intel Pentium 4 processor or AMD Athlon, 3.0 GHz or greater or Intel or AMD Dual Coreprocessor, 2.0 GHz or greater.

Minimum of 2 GB RAM. A CD-ROM drive or USB port. A hard disk of 9 GB for installation and 6 GB free hard disk available not including installation

requirements. A mouse.

Software Requirement:

Operating system- Window XP or higher. Browser- Internet Explorer® 7.0 or later. .NET Framework-.NET Framework Version 4.0 Update 1. 11g express release 2 32 bit.

Setup of 11g express release 2 32 bit:

Step 1:

Download 11g express release 2 32 bit from “http://www.oracle.com/downloads.”

Admission no.:14S121

Page | 2

Step 2:

Accept License Agreement and download zip file to click download button.

win32_11gR2_database_1of2.zip (1,625,721,289 bytes).

win32_11gR2_database_2of2.zip (631,934,821 bytes).

Admission no.:14S121

Page | 3

Step 3:

Unzip files and move 1 folder both two unzip files.

Step 4:

Start setup in open folder and run 11g setup.

Admission no.:14S121

Page | 4

Admission no.:14S121

Page | 5

Admission no.:14S121

Page | 6

Admission no.:14S121

Page | 7

Admission no.:14S121

Page | 8

Admission no.:14S121

Page | 9

Step 5:

Open SQL Developer and create a database connection.

Admission no.:14S121

Page | 10

Program 1: Creating database.

- Creating a database- Creating a table- Specifying relational data types- Specifying constraints- Creating indexes.

Creating a data base:

1. Start Database Configuration Assistant.This procedure varies by platform. In Windows, for example, choose Start > All Programs >Oracle - OraDb11g_home1 > Configuration and Migration Tools > Database ConfigurationAssistant.

2. Click Next to skip the Welcome page.3. On the Operations page, select Create a Database, and then click Next..

Database Configuration Assistant guides you through the steps needed to create a database.

4. On the Database Templates page, select General Purpose or Transaction Processing, and thenclick Next

5. On the Database Identification page, type books in the Global Database Name and SID boxes,and then click Next

6. On the Management Options page, accept the default settings, and then click Next.7. On the Database Credentials page, set the user password(s), and then click Next.8. On the Database File Locations page, select “File System” for the Storage Type, select “Use

Database File Locations from Template” for the Storage Locations, and then click Next.9. On the Recovery Configuration page, accept the default settings, and then click Next.10. On the Database Content page, accept the default settings, and then click Next.11. On the Initialization Parameters page, select the following options, and then click Next.12. On the Database Storage page, accept the default settings, and then click Next.

13. On the Creation Options page, select Create Database, and then click Finish.

14. In the Confirmation dialog box that opens, review the configuration options (and save them toan HTML file if you like), and then click OK.

15. Click Exit in the message box that opens when Oracle finishes creating the database.16. Start SQL*Plus (sqlplus) and connect to the books database.

At a command prompt, type:sqlplus user/password@dbname.

Create a table:

Create index:

Program 2: Table and Record Handling.

- INSERT statement- Using SELECT and INSERT together- DELETE, UPDATE, TRUNCATE Statement.- DROP, ALTER statement.

Insert statement:

Select and Insert together:

DELETE, UPDATE, TRUNCATE:

Delete:

Update:

Truncate:

DROP, ALTER:

Drop table:

Alter :

Program 3: Retrieving Data from a Database.

- The SELECT statement- Using the WHERE clause- Using Logical Operators in the WHERE clause- Using In, BETWEEN, LIKE, ORDER BY, GROUP BY & HAVING clause- Using Aggregate Functions- Combining Tables Using JOINS.

Select:

Where clause:

Using IN,BETWEEN,LIKE,ORDER BY,GROUP BY,AND,HAVING clause:

IN operator:

BETWEEN operator:

LIKE operator:

ORDER BY operator:

GROUP BY operator:

HAVING clause:

Using aggregate function :

Sum()

Count()

Avg():

Max():

Min():