0% found this document useful (0 votes)
25 views2 pages

Oracle SID and Table Creation Guide

Kgxitcixutxukxukfxukxkukfxufzkufxukfxjgxugxkhxifsvxufzgjxigxigxi c producer yfhodogcogxogsgixgixgidgidyi

Uploaded by

samidaudzai786
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
25 views2 pages

Oracle SID and Table Creation Guide

Kgxitcixutxukxukfxukxkukfxufzkufxukfxjgxugxkhxifsvxufzgjxigxigxi c producer yfhodogcogxogsgixgixgidgidyi

Uploaded by

samidaudzai786
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Name: Samiullah Daudzai

ID: 201-2309072

Class: DBA Saturday Morning

Assignment: 1

Oracle SID, Table Crea on, and


Database Concepts
Oracle SID and Tables Crea on
a. What is an Oracle SID and why is it important?

• An Oracle SID (System Identi ier) uniquely identi ies a speci ic Oracle database instance.
It's essential because it tells the Oracle client which database to connect to. Without
setting the correct SID, you might fail to establish a connection with the intended Oracle
database instance.

b. Write a basic command to set Oracle SID in Windows.

• set oracle_sid=XE

• Or if your SID is named differently, like DBAMF22: set oracle_sid=DBAMF22

c. What command is used to create a table in Oracle?

• The basic SQL command is:


CREATE TABLE table_name (
column1 datatype,
column2 datatype,
...
);

d. Create a simple table student with columns id, name, and age.

• CREATE TABLE student (


id NUMBER PRIMARY KEY,
name VARCHAR2(50),
age NUMBER
);

Business Rules and En ty Rela onship


a. What is a business rule in the context of databases?
ti
f
ti
ti
f
ti
f
• A business rule is a formal statement that de ines or constrains some aspect of business.
In database terms, it sets the guidelines and policies that determine the relationships,
attributes, and behaviors of data elements within a system.

b. Give one example of a business rule related to a university database.

• "Each student must be enrolled in at least one course, and each course can have many
enrolled students." This implies a many-to-many relationship between students and
courses.

c. Identify two entities from a university database and describe their relationship.

• Entities: Student and Department


Relationship: A student belongs to one department, but a department can have many
students. (This is a one-to-many relationship: one department → many students)

d. Why is it important to identify entities and relationships before creating a database?

• Identifying entities and relationships beforehand ensures proper database design, data
integrity, and ef icient data retrieval. It helps prevent redundancy and supports clear
understanding of the data structure and how different data elements relate to each
other.
f
f

You might also like