Step 1)
Installation and Configuration of Oracle 10g XE.
Step 2)
After Installation create user account using Database Administrative account.
(This can be easily done using Oracle Database XE home page.Please Refer Document given at the end of the article for creating new user account using XE homepage)
Step 3)
Login with User account and Create a simple table
create table student_table (name varchar2(10),roll number(3));
Insert some values into it.
Insert some duplicate values,null values.
Explain how to avoid it by using primary and not null key.
Step 2:Create employee and department table.
create table employee_table
(
employee_id number(5) constraints empidpk primary key,
employee_name varchar2(10)constraints empnamenn not null,
hire_date date,
salary number(5),
dept_no number(2) references department_table(dept_no)
);
Explain why the table creation is failed?
create table department_table
(
dept_no number(2) constraints dept_idpk primary key,
dept_name varchar2(10) constraints dept_namenn not null,
dept_location varchar2(15) constraints dept_locnn not null
);
Insert values into Department table:
insert into department_table values (10,'account','mumbai');
insert into department_table values(30,'admin','pune');
insert into department_table values(20,'hr','delhi');
Ask them to modify student table created in step 1 accordingly.
More on this coming soon.
Refer below tutorial for you to quickly up and running using Oracle Database XE by creating a simple application.
http://download.oracle.com/docs/cd/B25329_01/doc/admin.102/b25610/toc.htm
No comments:
Post a Comment