Lab Manual
Lab Manual
AIM:
To execute the DATA DEFINITION LANGUAGE (DDL) commands.
CREATING A TABLE
SYNTAX:
create table <table name> (column 1 datatype 1,
……., column n datatype n);
EXPLANATION:
EXAMPLE:
OUTPUT:
Table created.
DESC COMMAND
SYNTAX:
desc <table name>;
EXPLANATION:
EXAMPLE:
VT NUMBER
NAME VARCHAR (10)
ALTERING A TABLE
EXPLANATION:
The structure of the table can be changed using this command like
add new column, change the width of a datatype, change the datatype
of a column.
1. MODIFY
SYNTAX:
alter table <table name> modify (column datatype, …);
EXAMPLE:
OUTPUT:
Table altered.
ADD / DROP
SYNTAX:
alter table <table name> add/drop (column datatype, …);
EXAMPLE:
OUTPUT:
Table altered.
TRUNCATING A TABLE
SYNTAX:
truncate table <table name>;
EXPLANATION:
EXAMPLE:
OUTPUT:
Table truncated.
DROPPING A TABLE
SYNTAX:
drop table <table name>;
EXPLANATION:
EXAMPLE:
OUTPUT:
Table dropped.
RESULT:
Thus, the data definition language commands were executed and their
outputs were verified
EXP.N0:1b DATA MANIPULATION LANGUAGE [DML]
DATE:
AIM:
To execute the DATA MANIPULATION LANGUAGE (DML) commands.
INSERT COMMANDS
SYNTAX:
insert into <table name> values (value1, value2,……, value n);
EXPLANATION:
EXAMPLE:
SQL> insert into student values (4169, „rameeze‟);
OUTPUT:
1 row created.
SYNTAX:
insert into <table name> values (&value1, &value2,……, &value n);
EXPLANATION:
EXAMPLE:
SQL> insert into student values (&vt, „&name‟);
OUTPUT:
Enter value for vt: 4169
Enter value for name: rameeze
Old 1: insert into student values (&vt, „&name‟)
New 1: insert into student values (4169, „rameeze‟)
1 row created.
SELECT COMMANDS
SYNTAX:
select * from <table name>;
EXPLANATION:
This select command is used to retrieve all the values stored in the table.
EXAMPLE:
SQL> select * from student;
OUTPUT:
VT NAME
4169 RAMEEZE
SYNTAX:
select <field name> from <table name>;
EXPLANATION:
This select command is used to retrieve the particular field values stored
in the table.
EXAMPLE:
SQL> select name from student;
OUTPUT:
RAMEEZE
3. SELECT USING WHERE COMMAND.
SYNTAX:
select <field name> from <table name> where <search condition>;
EXPLANATION:
EXAMPLE:
SQL> select name from student where vt=4169;
OUTPUT:
NAME
RAMEEZE
UPDATE COMMAND
SYNTAX:
update <table name> set column1=expression, column 2=expression, ……,
column n=expression where <search condition>;
EXPLANATION:
This command is used to update (changing values in) one or two columns
of a row in a table. Specific rows can be updated based on some
condition.
EXAMPLE:
SQL> update student set name=‟md rameeze‟ where vt =4169;
OUTPUT:
1 row updated.
SQL> select * from student;
VT NAME
4169 MD RAMEEZE
DELETE COMMAND
SYNTAX:
delete from <table name> where <search condition>;
EXPLANATION:
EXAMPLE:
SQL> delete from student where vt =4169;
OUTPUT:
1 row deleted.
no rows selected.
RESULT:
Thus, the data manipulation language commands were executed and their
outputs were verified.
EXP.N0: 1c TRANSACTION CONTROL COMMANDS TCL
DATE:
AIM
To execute the transaction control commands TCL
TRANSACTION CONTROL LANGUAGE
• Transaction control language is statements to manage the changes made by DML statements.
• It allows statements to be grouped together into logical transactions. There are lots of TCL
commands which are used in SQL in which some are namely defined as follows:
✓ COMMIT
✓ SAVEPOINT
✓ ROLLBACK
SET OPERATORS
SQL set operators allows combine results from two or more SELECT statements.
✓ UNION
✓ UNIONALL
✓ INTERSECT
✓ MINUS
ARITHMETIC OPERATORS
Arithmetic operators can perform arithmetical operations on numeric operands involved.
✓ MAX
✓ MIN
✓ COUNT
✓ AVG
✓ SUM
SQL COMMANDS
EXECUTION
TABLE CREATION:
SQL> create table emp1(emp_name varchar2(10),emp_no number primary key,dept_no
number,dept_name varchar2(10));
Table created.
SQL> create table em1(emp_name varchar2(10),emp_no number primary key,dept_no
number,dept_name varchar2(10));
Table created.
INSERTING VALUES:
SQL> insert into emp1 values('vijay',345,54,'cse');
1 row created.
SQL> insert into emp1 values('ajay',35,6,'cse');
1 row created.
SQL> insert into em1 values('ajay',35,6,'cse');
1 row created.
SQL> insert into em1 values('vinoth',45,504,'cse');
1 row created.
DISPLAY THE TABLE:
SQL> select * from emp1;
EMP_NAME EMP_NO DEPT_NO DEPT_NAME
---------- ---------- ---------- ----------
vijay 345 54 cse
ajay 35 6 cse
SQL> select * from em1;
EMP_NAME EMP_NO DEPT_NO DEPT_NAME
---------- ---------- ---------- ----------
ajay 35 6 cse
vinoth 45 504 cse
COMMIT & ROLLBACK COMMAND:
SQL> commit;
Commit completed.
SQL> delete from em1 where emp_no=45;
1 row deleted.
SQL> select * from em1;
EMP_NAME EMP_NO DEPT_NO DEPT_NAME
SET OPERATORS
SQL> insert into em1 values('arjun',87,978,'mech');
1 row created.
SQL> insert into em1 values('akshai',83,98,'it');
1 row created.
SQL> insert into emp1 values('akash',38,56,'eee');
1 row created.
SQL> insert into emp1 values('arjun',87,978,'mech');
1 row created.
SQL> select * from em1;
EMP_NAME EMP_NO DEPT_NO DEPT_NAME
ajay 35 6 cse
vijay 345 54 cse
arjun 87 978 mech
akshai 83 98 it
SQL> select * from emp1;
EMP_NAME EMP_NO DEPT_NO DEPT_NAME
akash 38 56 eee
arjun 87 978 mech
SQL> select emp_no from em1 union select emp_no from emp1;
EMP_NO
35
38
83
87
345
SQL> select emp_no from em1 union all select emp_no from emp1;
EMP_NO
35
83
87
345
38
87
6 rows selected.
SQL> select emp_no from em1 intersect select emp_no from emp1;
EMP_NO
----------
87
SQL> select emp_no from em1 minus select emp_no from emp1;
EMP_NO
----------
35
83
345
RESULT:
Thus the TCL commands were executed and their outputs were verified.
EXP.N0:2a QUERIES IN SQL
AIM:
To write and execute simple,nested and joins queries in SQL.
TYPES OF COMMANDS:
JOIN QUERIES
✓ INNER JOIN
✓ LEFT OUTER JOIN
✓ RIGHT OUTER JOIN
✓ FULL OUTER JOIN
NESTED QUERIES
• A subquery is a query within a query. In Oracle, you can create subqueries within your SQL
statements.
• These subqueries can reside in the WHERE clause, the FROM clause, or the SELECT clause.
SQL COMMANDS
Command returns the matching rows from the tables that are being joined.
Command returns matching rows from the tables being joined and also non-matching row
from the left table in the result and places null values in the attributes that come from the right
side table.
3. COMMAND NAME: RIGHT OUTER JOIN
Command returns matching rows from the tables being joined and also non-matching row
from the right table in the result and places null values in the attributes that come from the left
side table.
EXECUTION
TABLE CREATION
SQL> create table emp_det(eno number(3) not null, ename varchar2(25),address varchar2(30),
basic_sal number(12,2),job_status varchar2(15),dno number(3));
Table created.
SQL> create table pro_det(pno number(3) not null,pname varchar2(30), no_of_staff number(3));
Table created.
Table created.
ENAME VARCHAR2(25)
ADDRESS VARCHAR2(30)
BASIC_SAL NUMBER(12,2)
JOB_STATUS VARCHAR2(15)
DNO NUMBER(3)
PNAME VARCHAR2(30)
NO_OF_STAFF NUMBER(3)
PNO NUMBER(3)
ENO NUMBER(3)
PJOB CHAR(12)
SQL> insert into emp_det values(&eno,'&ename','&address',&basic_sal,'&job_status',&dno);
1 row created.
SQL> /
'&job_status',&dno)
new 1: insert into emp_det values(4,'Shirley','KKnagar',8000,
'AsstManager',3)
1 row created.
SQL> alter table emp_det modify(ename varchar2(15), address varchar2(15)); Table altered.
1 row created.
SQL> /
1 row created.
1 pname 2
2 pname 3
3 pname 1
1 row updated.
1 row updated.
SQL>update pro_det set pname='C' where pno=3;
1 row updated.
1 DBMS 2
2 COMPILER 3
3 C 1
1 row created.
SQL> /
1 row created.
1 1 Programmer
2 1 Analyst
1 2 Analyst
2 2 Programmer
EXP.N0:2.b NESTED QUERIES
DATE:
i)SQL> select ename from emp_det where dno not in(select dno from emp_det where ename
='SaravanaKumar');
ENAME
RajKumar
Shirley
ii)SQL> select ename, dno from emp_det where dno = (select dno from emp_det where ename
='RajKumar');
ENAME DNO
RajKumar 2
(iii)SQL> select ename from emp_det where eno in(select eno from work_in where pno = (select
pno from pro_det where pname = 'DBMS')) order by ename;
ENAME
-Mahendran SaravanaKumar
(iv)SQL> select ename, basic_sal from emp_det where dno = 2 and basic_sal>(select
max(basic_sal) from emp_det where dno = 10) order by ename;
ENAME BASIC_SAL
RajKumar 10000
(v)SQL> select pno,pname from pro_det where exists(select pno from work_in where
work_in.pno =pro_det.pno);
PNO PNAME
1 DBMS
2 COMPILER
(vi)SQL>select ename, job_status,basic_sal from emp_det where (dno,basic_sal) in (select
dno,basic_sal from emp_det where ename ='RajKumar');
8000
(ix)SQL> select * from emp_det where basic_sal < (select avg(basic_sal) from emp_det);
2c) JOINS
Table created.
1 row created.
SQL> /
1 row created.
SQL> /
1 row created.
NAME SALARY
Ashu 10000
Asma 1200
Asif 2000
Arif 1000
Niyas 3000
Table created.
1 row created.
SQL> /
1 row created.
SQL> /
1 row created.
NAME EMPID
fathi 12
sumi 32
priya 11
wahab 10
sweety 9
asma 1200
6 rows selected.
NATURAL JOIN
asma 1200
NAME SALARY
Asma 1200
Asif 2000
Arif 1000
Niyas 3000
Ashu 10000
NAME EMPID
asma 1200
sweety 9
sumi 32
wahab 10
fathi 12
priya 11
6 rows selected.
FULL JOIN
SQL>select emp1.name,emp.name,emp1.empid,salary from emp full join emp1 on
emp.name=emp1.name;
NAME NAME EMPID SALARY
asif 2000
arif 1000
niyas 3000
ashu 10000
sweety 9
sumi 32
wahab 10
fathi 12
priya 11
RESULT:
Thus the simple, nested ,join queries were executed and their outputs were
verified.
EX.NO:3 a SQL COMMANDS FOR VIEWS
DATE:
VIEWS
AIM:
To study the Simple View and Complex View and to execute them.
SQL COMMANDS
Command is used to change a value in a tuple without changing all values in the tuple.
TABLE CREATION:
Table created.
TABLE DESCRIPTION:
EMP_NAME VARCHAR2(10)
EMP_NO NUMBER(8)
DEPT_NAME VARCHAR2(10)
DEPT_NO NUMBER(5)
DOJ DATE
CREATION OF VIEW:
View created.
DESCRIPTION OF VIEW:
EMP_NAME VARCHAR2(10)
EMP_NO NUMBER(8)
DEPT_NAME VARCHAR2(10)
DEPT_NO NUMBER(5)
DOJ DATE
INSERT TABLE VALUES:
1 row created.
1 row created.
1 row created.
MODIFICATION:
1 row updated.
View dropped.
RESULT
Thus, the Simple view and Complex view were executed and the outputs were verified.
EX.NO:3b SQL COMMANDS FOR SYNONYMS
DATE:
AIM:
ALGORITHM:
STEP 5: Create the synonyms from the above created table or any data object.
STEP 8: Check the database object table and view the inserted values presented
OR
COMMANDS:
CREATE THE TABLE
SQL> CREATE TABLE student_table(Reg_No number(5),NAME varchar2(5),MARK number(3));
Table
10002 sam 75
10003 samu 9
10002 sam 75
10003 samu 95
10006 RAJA 80
SQL> select * from STUDENT_SYNONYM;
RESULT:
Thus the SQL commands for creation and various operation on Synonyms has been verified
and executed successfully.
EX.NO:3C SQL COMMANDS FOR SEQUENCES
DATE:
AIM:
To create the Sequence and verify the various operations on Sequence to get
the incremented number.
ALGORITHM:
Step 1: Start the DMBS.
Step 2: Connect to the existing database (DB)
Step 3: Create the sequence with its essential optional parameter.
Step 4: Display the data presented on the sequence by using pseudo column.
Step 5: Alter the sequence with different optional parameter.
Creating a Sequence
You create a sequence using the CREATE SEQUENCE statement, which has the following.
SYNTAX:
SQL>CREATE SEQUENCE sequence_name
[START WITH start_num]
[INCREMENT BY increment_num]
Command:
SQL> CREATE SEQUENCE seq1
INCREMENT BY 1
START with 1
MAXVALUE 5
MINVALUE 0;
Sequence created.
TO DISPLAY THE VALUES OF SEQUENCES
After creating sequence use nextval as nextval is used to generate sequence
values SQL> select seq1.nextval from dual;
NEXTVAL
1
SQL> select seq1.nextval from dual;
NEXTVAL
2
SQL> select seq1.nextval from dual;
NEXTVAL
3
SQL> select seq1.currval from dual;
CURRVAL
3
TO ALTER THE SEQUENCES
alter SEQUENCE
seq1 maxvalue 25
INCREMENT BY
a cycle
cache
2
drop SEQUENCE seq1;
EXAMPLE: 2
EXAMPLE: 3
CREATE SEQUENCE seq3
INCREMENT BY -
1 start with 2
maxvalue 5
minvalue 0;
EXAMPLE: 4
EXAMPLE: 5
CREATE SEQUENCE seq1
INCREMENT BY
1 start with 1
maxvalue 10
minvalue 0;
EXAMPLE: 6
create table test1(a number primary key);
RESULT:
Thus the SQL commands for creation and various operations on Sequence has been
verified and executed successfully.
EX.NO:4 CURSORS
DATE:
AIM:
To write and execute Cursors queries in SQL
SYNTAX:
EXECUTION
Table created.
1 row created.
1 row created.
1 row created.
OUTPUT:
EXPLICIT CURSOR
DECLARE
CURSOR er IS select eid,name from emp order by name ;
id emp.eid%type;
ename emp.name%type;
BEGIN
OPEN er;
Loop
FETCH er into id,ename;
Exit when er%notfound;
dbms_output.put_line (id || ename);
end loop;
close er;
END;
OUTPUT:
1||parimal
2||preet
PL/SQL Procedure successfully completed.
RESULT:
Thus, the Cursors were executed and the outputs were verified.
EXP.N0:5 HIGH LEVEL PROGRAMMING LANGUAGE EXTENSIONS
FUNCTIONS AND PROCEDURES
AIM:
ALGORITHM:
1. Create the function using function name.
2. Declare the variables to be used.
3. Begin the function.
4. Specify the operations.
5. Return the value to the variable declared.
6. End.
7. Procedure does not return value, but helps to call a function.
SYNTAX:
Create or replace function < function_name > [ argument ]
return datatype is
(local declaration)
Begin
(executable statements)
[Exception]
(exception handlers)
end;
EXECUTION
TABLE CREATION & VALUE INSERTION:
SQL> create table phonebook(pno number(6) primary key,username varchar2(30),doorno
varchar2(10),street varchar2(30),place varchar2(30),pincode char(6));
Table created.
SQL> insert into phonebook values(20312,'vijay','120/5D','bharathi street','NGO
colony','629002');
1 row created.
SQL> insert into phonebook values(29467,'vasanth','39D4','RK bhavan','sarakkal vilai','629002');
1 row created.
DISPLAY THE TABLE:
SQL> select * from phonebook;
PNO USERNAME DOORNO STREET PLACE
PINCODE
20312 vijay 120/5D bharathi street NGO colony 629002
29467 vasanth 39D4 RK bhavan sarakkal vilai 629002
CREATING A FUNCTION:
SQL> set serveroutput on
SQL> create or replace function findAddress(phone in number)return varchar2 as address
varchar2(100);
2 begin
3 select username||','||doorno||','||street||','||place||','||pincode int address from phonebook where
pno=phone;
4 return address;
5 exception
6 when no_data_found then return 'address not found';
7 end;
8 /
Function created.
SQL> declare
2 address varchar2(100);
3 begin
4 address:=findaddress(20312);
5 dbms_output.put_line(address);
6 end;
7 /
OUTPUT 1:
vijay,120/5D,bharathi street,NGO colony,629002
PL/SQL procedure successfully completed.
SQL> declare
2 address varchar2(100);
3 begin
4 address:=findaddress(23556);
5 dbms_output.put_line(address);
6 end;
7 / OUTPUT 2:
address not found
PL/SQL procedure successfully completed.
PROCEDURES
SYNTAX:
Create or replace procedure <proc_name>[parameter list]is
<local declaration>
Begin
(executable statements)
[exception] (exception handlers)
End;
EXECUTION:
TABLE CREATION & VALUE INSERTION:
SQL> create table stdnt1(rno number(4),name varchar2(20),mk1 number(3),mk2 number(3),mk3
number(3),mk4 number(3),mk5 number(3));
Table created.
SQL> insert into stdnt1 values(101,'preethi',78,88,77,60,89);
1 row created.
SQL> insert into stdnt1 values(102,'sarva',99,77,69,81,99);
1 row created.
SQL> insert into stdnt1 values(103,'suryapriya',100,90,97,89,91);
1 row created.
DISPLAY THE TABLE:
SQL> select * from stdnt1;
RNO NAME MK1 MK2 MK3 MK4 MK5
---------- -------------------- ---------- ---------- ---------- ---------- ----------
101 preethi 78 88 77 60 89
102 sarva 99 77 69 81 99
103 suryapriya 100 90 97 89 91
CREATING PROCEDURES:
SQL> set serveroutput on;
SQL> declare ave number(5,2);
2 tot number(3);
3 cursor c_mark is select * from stdnt1 where mk1>=40 and mk2>=40 and mk3>=40 and
mk4>=40 and mk5>=40;
4 begin
5 dbms_output.put_line('rno name mk1 mk2 mk3 mk4 mk5 total average');
6 dbms_output.put_line('-----------------------------------------------------');
7 for stdnt1 in c_mark
8 loop
9 tot:=stdnt1.mk1+stdnt1.mk2+stdnt1.mk3+stdnt1.mk4+stdnt1.mk5;
10 ave:=tot/5;
11dbms_output.put_line(stdnt1.rno||rpad(stdnt1.name,15)||rpad(stdnt1.mk1,6)||rpad(stdnt1.mk2,6)
||rpad
(stdnt1.mk3,6)||rpad(stdnt1.mk4,6)||rpad(stdnt1.mk5,6)||rpad(tot,8)||rpad(ave,5));
12 end loop;
13 end;
14 /
OUTPUT:
rno name mk1 mk2 mk3 mk4 mk5 total average
----- ------- ------ ------ ------ ------ ------ ----- ------
101 preethi 78 88 77 60 89 392 78.4
102 sarva 99 77 69 81 99 425 85
103 suryapriya 100 90 97 89 91 467 93.4
PL/SQL procedure successfully completed.
RESULT:
Thus, the Functions and Procedures were executed using SQL
and the outputs were verified.
EXP.N0:6 TRIGGERS
DATE:
AIM:
EXECUTION:
Table created.
1 row created.
1 row created.
1 row created.
SQL> select * from std;
1 sharath 100 90 98
2 ram 98 99 79
3 arun 88 98 90
CREATING A TRIGGER:
3 begin
10 end;
Trigger created.
OUTPUT:
1 sharath 100 90 98
2 ram 98 99 79
3 arun 90 89 99
RESULT:
Thus, the Triggers were executed using SQL and the outputs were verified.
EXP.N0:7 EXCEPTION HANDLING
DATE:
AIM:
SYNTAX:
Begin
Sequence_of_statements;
Exception
When <exception_name> then
Sequence_of_statements;
When others then
Sequence_of_statements;
End;
EXECUTION:
set serveroutput on;
declare
empid number(5);
emname varchar(50);
begin
empid:=&empid;
select empname into emname from employe where empno=empid;
dbms_output.put_line('The employe name is:'||emname);
exception
when no_data_found then
dbms_output.put_line('data not found');
end;
OUTPUT :
Enter value for empid: 1
old 5: empid:=&empid;
new 5: empid:=1;
The employe name is:radha
PL/SQL procedure successfully completed.
SQL> /
Enter value for empid: 5
old 5: empid:=&empid;
new 5: empid:=5;
data not found
PL/SQL procedure successfully completed.
SYNTAX:
<exception_name> exception;
raise <exception_name>;
EXECUTION:
declare
co number;
exceeds_value exception;
begin
if co <5 then
else
raise exceeds_value;
end if;
exception
end;
OUTPUT:
SQL> /
RESULT:
Thus, the exception handling were executed using SQL and the outputs were
verified.
Ex.No:8 DATABASE DESIGN USING ER MODELING,NORMALIZATION
DATE:
Aim:
ER diagram:
Chen Notation
Chen Notation
Chen Notation
RESULT:
Thus the ER Database design using E-R model and Normalization was implemented
successfully.
Ex.No:9 FRONT END TOOLS
DATE:
Aim:
To study about the various front end tools to design forms and reports.
Examples Front End Tools:
• Visual Basic
• Visual C++
• Java
• PHP
• HTML
• C 3.0 was the first version developed inside Microsoft. It was extremely compatible with
K&R and the later ANSI standard. It was being used inside Microsoft (for Windows and
Xenix development) in early 1984. It shipped as a product in 1985.
• C 4.0 added optimizations and CodeView, a source level debugger.
• C 5.0 added loop optimizations and Huge Model (arrays bigger than 64k) support.
Microsoft FORTRAN and the first 32 bit compiler for 80386 were also part of this project.
• C 6.0 released in 1989. It added global flow analysis, a source browser, and a
new
debugger, and included an optional C++ front end.
• C/C++ 7.0 was released in 1992. It added built-in support for C++ and MFC 1.0.[2]
• Visual C++ 1.0 (original name: Visual C++ 32-bit Edition) was the first version for 32-
bit development. Although released when 16-bit 1.5 was available, it did not include
support for OLE2 and ODBC. It was also available in a bundle called Visual C++ 16/32-
bit Suite, which included Visual C++ 1.5.
• Visual C++ 2.0, which included MFC 3.0, was the first version to be 32-bit only. In many
ways, this version was ahead of its time, since Windows 95, then codenamed "Chicago",
was not yet released, and Windows NT had only a small market share. As a result, this
release was almost a "lost generation". Microsoft included and updated Visual C++ 1.5 as
part of the 2.x releases up to 2.1, which included Visual C++ 1.52, and both 16-bit and 32-
bit version of the Control Development Kit (CDK) were included. Visual C++ 2.x also
supported Win32s development. It is available through Microsoft Developer
• Visual C++ 4.0, which included MFC 4.0, was designed for Windows 95 and Windows
NT. To allow support of legacy (Windows 3.x/DOS) projects, 4.0 came bundled with the
Visual C++ 1.52 installation CD. Updates available through subscription included Visual
C++ 4.1, which came with the Microsoft Game SDK (later released separately as the
DirectX SDK), and Visual C++ 4.2. Version number 3.0 was skipped to achieve version
number parity between Visual C++ 4.0 and MFC 4.0.[9]
• Visual C++ 4.2 did not support Windows 3.x (Win32s) development.[10] This was the
final version with a cross-platform edition for the Macintosh available and it differed
from the 2.x version in that it also allowed compilation for the PowerPC instruction set.
• Visual C++ 5.0, which included MFC 4.21, was a major upgrade from 4.2.[11] Available
in four editions:
O Learning
O Professional
O Enterprise
O RISC
• Visual C++ .NET 2003 (known also as Visual C++ 7.1), which included MFC 7.1, was
released in 2003 along with.NET 1.1 and was a major upgrade to Visual C++ .NET 2002.
It was considered a patch to Visual C++ .NET 2002. Accordingly, the English language
upgrade version of Visual Studio .NET 2003 shipped for minimal cost to owners of the
English language version of Visual Studio .NET 2002. This was the last version to
support Windows 95 and NT 4.0 as a target.
Java is a programming language originally developed by James Gosling at Sun
Microsystems (now part of Oracle Corporation) and released in 1995 as a core component of Sun
Microsystems' Java platform. The language derives much of its syntax from C and C++ but has a
simpler object model and fewer low-level facilities. Java applications are typically compiled to
byte code (class file) that can run on any Java Virtual Machine (JVM) regardless of computer
architecture. Java is a general-purpose, concurrent, class-based, object-oriented language that is
specifically designed to have as few implementation dependencies as possible.
There were five primary goals in the creation of the Java language:
1. It should be "simple, object-oriented and familiar"
2. It should be "robust and secure"
3. It should be "architecture-neutral and portable"
Version
Major release versions of Java, along with their release dates:
• JDK 1.0 (January 23, 1996)
• JDK 1.1 (February 19, 1997)
• J2SE 1.2 (December 8, 1998)
• J2SE 1.3 (May 8, 2000)
• J2SE 1.4 (February 6, 2002)
• J2SE 5.0 (September 30, 2004)
• Java SE 6 (December 11, 2006)
• Java SE 7 (July 28, 2011)
Features of Java
One characteristic of Java is portability, which means that computer programs written in
the Java language must run similarly on any hardware/operating-system platform. This is
achieved by compiling the Java language code to an intermediate representation called Java byte
code, instead of directly to platform-specific machine code. Java byte code instructions are
analogous to machine code, but are intended to be interpreted by a virtual machine (VM) written
specifically for the host hardware. End-users commonly use a Java Runtime Environment (JRE)
installed on their own machine for standalone Java applications, or in a Web browser for Java
applets.
4.HTML
HTML is a language for describing web pages.
• HTML stands for Hyper Text Markup Language
HTML Tags
HTML markup tags are usually called HTML tags
• HTML tags are keywords surrounded by angle brackets like <html
• HTML tags normally come in pairs like <b> and </b>
• The first tag in a pair is the start tag, the second tag is the end tag
• Start and end tags are also called opening tags and closing tags
Result:
Thus the front-end languages visual basic, java, HTML are studied.
EX. NO: 9B FORMS- PAYROLL PROCESSING SYSTEMS
DATE:
AIM:
To implement the operations of PAYROLL PROCESSING SYSTEM using the visual
basic as front end and oracle as back end to design a forms..
PROCEDURE:
1. Collect the details of how the program is expected by the user and also the atmosphere in
which it is going to work.
2. Collect the user requirement. Develop a sketch of the program about how it is going to appear
in its final design.
3. Implement the various diagram carefully, based on which the entire project design is
going to be developed.
5. In the component diagram, using the update code command we generate the code
for the required program.
PROGRAM:
Table created.
End Sub
Private Sub exit_Click()
Unload Me
End Sub
Private Sub main_Click()
Form1.Show
End Sub
Private Sub modify_Click()
Adodc1.Recordset.Update
End Sub
End Sub
Private Sub modify_Click()
Adodc1.Recordset.Update
End Sub
Output:
RESULT:
Thus, the payroll processing system using VB was implemented.
Ex. no: 10 DESIGN AND IMPLEMENTATION OF BANKING SYSTEM
DATE:
AIM:
To develop a banking system using Oracle as s back end(data base) and Microsoft
PROCEDURE :
2. Design the corresponding form with labels,text boxes and command buttons.
Form1→ customer details
Form2→ withdraw
Form3→ deposit
3. Create the back with the front end using DAO method by creating a dsn as follows
a.Select administrative tools option from control panel.
Then click on data source(ODBC),which displays a dialog box named
NAME TYPE
ACNO NUMBER(6)
NAME VARCHAR2(30)
ADDRESS VARCHAR2(20)
BALANCE NUMBER(8,2)
FORM 1:
Dim DB As Database
Dim RS As recordset
Text1.text=RS(0)
Text2.text=RS(1)
Text3.text=RS(2)
Text4.text=RS(3)
End Sub
Text1.text=””
Text2.text=””
Text3.text=””
Text4.text=””
End Sub
RS.DELETE
RS.MoveNext IfRS.EOF
records” Else
Text1.text=RS(0)
Text2.text=RS(1)
Text3.text=RS(2)
Text4.text=RS(3)
End If
End Sub
End
End Sub
RS .MoveFirst
Text1.Text=RS(0)
Text2.Text=RS(1)
Text3.Text=RS(2)
Text4.Text=RS(3)
End Sub
RS.MoveLast
RS.AddNew
RS(0)=Text1.Text
RS(1) =Text2.Text
RS(2)=Text3.Text
RS(3)=Text4.Text
MsgBox”record is inserted”
RS.UPDATE
End Sub
RS. MoveLast
Text1.text=RS(0)
Text2.text=RS(1)
Text3.text=RS(2)
Text4.text=RS(3)
End Sub
RS.Move Next
If RS.EOF Then
Text1.text=RS(0)
Text2.text=RS(1)
Text3.text=RS(2)
Text4.text=RS(3)
EndIf
End Sub
RS.Move Previous
If RS.EOF Then
Else
Text1.text=RS(0)
Text2.text=RS(1)
Text3.text=RS(2)
Text4.text=RS(3)
EndIf
End Sub
RS.Edit
RS(0)=Text1.Text
RS(1) =Text2.Text
RS(2)=Text3.Text
RS(3)=Text4.Text
RS.UPDATE
MsgBox”record is inserted”
End Sub
rs.FindFirst”[ACNO]=”&I
If rs.NoMatch Then
Else
Text1.text=RS(0)
Text2.text=RS(1)
Text3.text=RS(2)
Text4.text=RS(3)
EndIf
End Sub
Form2.Show
End Sub
Form3.Show
End Sub
FORM 2:
Form1.Show
Form2.Hide
End Sub
Text2.Text=val(Form1.Text)-Text1.Text
Form1.Text4=Text2.text
End Sub
End
FORM 3:
Text2.Text=val(Form1.Text)+Text1.Text
Form1.Text4=Text2.text
End Sub
Form1.Show
Form3.Hide
End Sub
WITHDRAW FORM:
DEPOSIT FORM:
RESULT:
Thus the banking system has been successfully developed in Visual Basic.