Sie sind auf Seite 1von 18

Expt: 01

Aim: Study of computer Networks.

Computer Network
A computer network is a network of geographically distributed multiple
computers connected in such a manner such that meaningful transmission &
exchange of information become possible among them. Sharing of information,
sharing of resources (both hardware & software) and sharing of processing load are
some of the major objectives of a computer network. Networks are built with a
combination of computer hardware and computer software.
Networks are classified on different basis. One of the ways to classify the
networks is by scale/area. Here networks are classified in three groups namely;

LAN - Local Area Network

A local area network (LAN) is a communication network that interconnects a
variety of data communicating devices within a small geographic area, and
broadcasts data at high data transfer rates with very low error rates and these are
relatively inexpensive. Since the local area network first appeared in the 1970s, its use
has become widespread in commercial and academic environments. It would be very
difficult to imagine a collection of personal computers within a computing
environment that does not employ some form of local area network.

Primary Function of a Local Area Network

The majority of users expect a local area network to perform the primary
function of sharing resources. This often includes the following applications: file
serving, database and application serving, print serving, electronic mail, remote
links, video transfers, process control and monitoring, and distributed processing. A
LAN is useful for sharing resources like files, printers, games or other applications. A
LAN in turn often connects to other LANs, and to the Internet or other WAN.
A LAN connects network devices over a relatively short distance. A
networked office building, school, or home usually contains a single LAN, though
sometimes one building will contain a few small LANs (perhaps one per room), and
occasionally a LAN will span a group of nearby buildings.
In addition to operating in a limited space, LANs are also typically owned,
controlled, and managed by a single person or organization. They also tend to use
certain connectivity technologies, primarily Ethernet and Token Ring.
Most local area networks are built with relatively inexpensive hardware such
as Ethernet cables, network adapters, and hubs. Wireless LAN and other more
advanced LAN hardware options also exist. Specialized operating system software
may be used to configure a local area network. For example, most flavors of
Microsoft Windows provide a software package called Internet Connection Sharing
(ICS) that supports controlled access to LAN resources.
Data transmission rates are usually much higher in LANs than WANs.
Transmission rate in LANs usually ranges from 0.2 Megabit per second (Mbps) to 1
Gigabits per second (Gbps). Error rates in LANs are in the range of 10 -8 to 10-12. Since
LANs are privately owned communication cost is negligible.
Examples: The most common type of local area network is an Ethernet LAN. The
smallest home LAN can have exactly two computers; a large LAN can accommodate
many thousands of computers. Many LANs are divided into logical groups called

Advantages and Disadvantages of Local Area Networks

Local area networks have several advantages, including: hardware and
software sharing, workstation survival during network failure, component and
system evolution, heterogeneous mix of hardware and software, and access to other
LANs, WANs, and mainframe computers. Disadvantages include complexity,
maintenance costs, and the network is only as strong as the weakest link.

WAN - Wide Area Network

Definition: A WAN spans a large geographic area, such as a state, province or
country. WANs often connect multiple smaller networks, such as local area networks
(LANs) or metro area networks (MANs).
A WAN (wide area network), in comparison to a MAN, is not restricted to a
geographical location, although it might be confined within the bounds of a state or
country. A WAN connects several LANs, and may be limited to an enterprise (a
corporation or an organization) or accessible to the public. The technology is high
speed and relatively expensive. The Internet is an example of a worldwide public
A WAN is a geographically-dispersed collection of LANs. A network device
called a router connects LANs to a WAN. In IP networking, the router maintains
both a LAN address and a WAN address.
A WAN differs from a LAN in several important ways. Most WANs (like the
Internet) are not owned by any one organization but rather exist under collective or
distributed ownership and management. WANs tend to use technology like ATM,
Frame Relay and X.25 for connectivity over the longer distances. The world's most
popular WAN is the Internet. Some segments of the Internet, like VPN-based
extranets, are also WANs in themselves. Finally, many WANs are corporate or
research networks that utilize leased lines.
WANs generally utilize different and much more expensive networking
equipment than do LANs. Key technologies often found in WANs include SONET,
Frame Relay, and ATM. Data transfer rate in WANs is usually in the range of 1200
bits per second to slightly over 1 Mbps. Bit error rate with WANs is in the range of
10-5 to 10-7. Communication links used are telephone lines, microwave links &
satellite channels. WANs are not privately owned so communication cost is higher.

Metropolitan Area Network

A network sharing some of the properties of both LANs & WANs is referred
to as metropolitan area network. MAN spans a physical area larger than a LAN but
smaller than a WAN, such as a city. The main objective of MAN is to interconnect
LANs located in entire city or metropolitan area. MAN operates at speed very close
to LAN speed. Communication links commonly used for MANs are coaxial cable and
microwave links.
There are three important features which discriminate MANs from LANs or WANs:

1. The network size falls intermediate between LANs and WANs. A MAN typically
covers an area of between 5 and 50 km diameter. Many MANs cover an area the size
of a city, although in some cases MANs may be as small as a group of buildings or as
large as a country.
2. A MAN (like a WAN) is not generally owned by a single organization. The MAN,
its communications links and equipment are generally owned by either a consortium
of users or by a single network provider who sells the service to the users. This level
of service provided to each user must therefore be negotiated with the MAN
operator, and some performance guarantees are normally specified.

3. A MAN often acts as a high speed network to allow sharing of regional resources
(similar to a large LAN). It is also frequently used to provide a shared connection to
other networks using a link to a WAN.


The Internet is a global system of interconnected computer networks that

interchange data by packet switching using the standardized Internet Protocol Suite
(TCP/IP). It is a "network of networks" that consists of millions of private and public,
academic, business, and government networks of local to global scope that are linked
by copper wires, fiber-optic cables, wireless connections, and other technologies.

The Internet carries various information resources and services, such as

electronic mail, online chat, file transfer and file sharing, online gaming, and the
inter-linked hypertext documents and other resources of the World Wide Web

Common methods of internet access include dial-up network, landline

broadband (over coaxial cable, fiber optic , copper wires), Wi-Fi, satellite and 3G
technology cell phones.

The terms Internet and World Wide Web are often used in every-day speech
without much distinction. However, the Internet and the World Wide Web are not
one and the same. The Internet is a global data communications system. It is a
hardware and software infrastructure that provides connectivity between computers.
In contrast, the Web is one of the services communicated via the Internet. It is a
collection of interconnected documents and other resources, linked by hyperlinks
and URLs

The Internet viewed on mobile devices

The Internet can now be accessed virtually anywhere by numerous means. Mobile
phones, datacards, handheld game consoles and cellular routers allow users to
connect to the Internet from anywhere there is a cellular network supporting that
device's technology. Within the limitations imposed by the small screen and other
limited facilities of such a pocket-sized device, all the services of the Internet,
including email and web browsing, may be available in this way. Service providers
may restrict the range of these services and charges for data access may be
significant, compared to home usage.

Common Uses of internet

1. E-mail:
the E-mail service of the internet allows an internet user to send a
mail/message to another internet user in any part of the world in a real time manner.
Many people are preferring e-mail service than other services like paper mail,
telephone, fax. E-mail service is faster than paper mail. Unlike telephone, persons
communicating with each other need not be available at the same time. Unlike the
fax document, e-mail documents can be stored on the computer & can be easily

2. World Wide Web (WWW):

internet is vast ocean of information. Obiviously, this large information bank
will be of little use or no use if one cann‟t find something of his interest. Therefore
several user friedly tools are available that allow user to succesfully navigate the
internet and find useful information. Process of navigating the internet is known as
internet surfing & search tools are called as surfing tools.
The World Wide Web is a huge set of interlinked documents, images and
other resources, linked by hyperlinks and URLs. These hyperlinks and URLs allow
the web servers and other machines that store originals, and cached copies of, these
resources to deliver them as required using HTTP (Hypertext Transfer Protocol).
HTTP is only one of the communication protocols used on the Internet.
WWW is most popular surfing tool. The main reason for its popularity is use
of a concept known as hypertext. Hypertext is a way of information storage and
retrival. Hyperrtext document is also known as web page. A well designed web page
helps user rapidly locate the desired information from vast amount of information.

3. Remote access:
The Internet allows computer users to connect to other computers and
information stores easily, wherever they may be across the world. They may do this
with or without the use of security, authentication and encryption technologies,
depending on the requirements. This possible with an internet service known as
Telnet. telnet allows user to log into another computer somewhere on the internet.

4. File sharing:
The File Transfer Protocol (FTP) allows an internet user to move a file from
one computer to another computer on the interrnet. Moving file from a remote
computer or server to ones own (local) computer is known as downloading and
moving file from local computer to remote computer is known as uploading.

5. Streaming media
Many existing radio and television broadcasters provide Internet "feeds" of
their live audio and video streams. They may also allow time-shift viewing or
listening such as Preview, Classic Clips and Listen Again features. These providers
have been joined by a range of pure Internet "broadcasters" who never had on-air
licenses. This means that an Internet-connected device, such as a computer or
something more specific, can be used to access on-line media in much the same way
as was previously possible only with a television or radio receiver. Podcasting is a
variation on this theme, where—usually audio—material is first downloaded in full
and then may be played back on a computer or shifted to a digital audio player to be
listened to on the move. These techniques using simple equipment allow anybody,
with little censorship or licensing control, to broadcast audio-visual material on a
worldwide basis.
Webcams can be seen as an even lower-budget extension of this phenomenon.
While some webcams can give full-frame-rate video, the picture is usually either
small or updates slowly. Video chat rooms and video conferencing are also popular
with many uses being found for personal webcams, with and without two-way
6. Internet Telephony (VoIP)
VoIP stands for Voice-over-Internet Protocol, referring to the protocol that
underlies all Internet communication. The idea began in the early 1990s with walkie-
talkie-like voice applications for personal computers. In recent years many VoIP
systems have become as easy to use and as convenient as a normal telephone. The
benefit is that, as the Internet carries the voice traffic, VoIP can be free or cost much
less than a traditional telephone call, especially over long distances and especially for
those with always-on Internet connections such as cable or ADSL.
VoIP is maturing into a competitive alternative to traditional telephone
service. Interoperability between different providers has improved and the ability to
call or receive a call from a traditional telephone is available. Simple, inexpensive
VoIP network adapters are available that eliminate the need for a personal computer.
Voice quality can still vary from call to call but is often equal to and can even exceed
that of traditional calls.

Experiment: 02
Title: Design & analysis of DBMS using Oracle/Microsoft Access- Data
Insertion, Updating & Deletion

1. To study concept of database & database systems.
2. To create the database in Oracle 10G/ Microsoft Access
3. To enter data in the database in Oracle 10 G/ Microsoft Access
4. To update and delete records using basic SQL commands

A database is collection of interrelated data or information. There is an
interrelation between different fields of database and also there is relation between
who is keeping database and of whom.

Database Management System (DBMS):

A DBMS is a collection of interrelated data and a set of programs to access that
data. Primary goal of DBMS is to provide a way to store & retrieve database
information that is both efficient & convenient.

Relational Database Management System (RDBMS):

RDBMS is most widely used system. It has attained its primary position
because of its simplicity, which eases work of programmers.
RDBMS consists of a collection of tables. Each table has its unique name.
Tables are used to represent the data & relationship among the data. A row in table
represents relationship among a set of values. A row is an entity and table is an entity
set. In RDBMS table is referred as relation & row is referred as tuple. A table has two
or more columns. Column is also known as field and row is a record. Column header
is known as attribute or field name.

Database Language:
Database languages are used to design a database and to store & retrieve
information from database. A query is a statement requesting retrieval of information
from database.

Structured Query Language (SQL):

SQL is most widely used query language. Although SQL is referred as query
language, it can do much more than just query a database. It can define the structure
of data, modify data in the database and specify security constraints.

Database Management System (DBMS):

There are several Database Management Systems (DBMS), such as:
 Microsoft SQL Server
 Oracle
 Sybase
 DBase
 Microsoft Access
 MySQL from Sun Microsystems (Oracle)
 DB2 from IBM etc.
SQL Commands
1. Create Table:
It is the command used to create tables or relations. General form of this
command is as follows

Create table R(A1 D1, A2 D2, -----------, An Dn, <integrity constraint1>,

<integrity constraint2>, --------, <integrity constraintk>);

Where, R is the name of the relation,

Ai is the of the attribute,
Di is the domain of the attribute,
Integrity Constraints:
An authorized user can make changes in the database. Sometimes these
changes may result in loss of data consistency. Integrity constraint ensures that
changes made to database do not result in data inconsistency. Thus integrity
constraints guard against accidental damage to database. Different integrity
constraints are available such as primary key, not null, unique etc.
e.g. consider the query to create student table
Create table student (rollno number, name varchar(10), city varchar(10), class

2. Insert into:
Insert command is used to insert data or record into a relation. Data/records
to be inserted are specified directly or by writing a query. General form is as follows
Insert into R values (V1, V2, V3, ………….., Vn);
Where R is table name, V1 to Vn are the values of attributes to be inserted.
Sequence of values should be as per the attributes in the table.

e.g. Insert into student values (1134, „amit‟, „miraj‟, „sytt‟)

One record is added in student table.

3. Update:
In certain situations it becomes necessary to change a value in a tuple, without
changing remaining values. For this purpose, update command can be used. Also it
is possible to update some selected tuples from a relation using where clause.
Update R
Set A=V
Where P;
Where R is tha table name which is to be updated, A is attribut whose value is to be
updated and V is the new value of the attribute A, P is predicate or condition. If this
condition is TRUE, then that record is updated; other wise not.

e.g. Update student

Set class= „fytt‟
Where rollno= 1134
Class of student whose roll number is 1134 is updated.

4. Delete:
Delete command is used to delete whole tuples from a relation. Delete
command can not delete values of particular attributes from a tuple. General form is
Delete from R where P;
Delete whole tuples from relation R if predicate P is true. The where clause
can be omitted in which case all tuples from relation R are deleted. Delete command
operates on only one relation. If tuples from several relations are to be deleted, then
for each relation one delete command should be used.

e.g. Delete from student where rollno = 1234

Record of student whose roll number is 1234 will be deleted.

Experiment: 03
Title: Design & analysis of DBMS using Oracle/Microsoft Access- Data

1. To retrieve data from database
2. To study various clauses, operators, functions


SQL Commands
1. SQL Queries:
Query is a statement requesting information from the database. SQL query
consists of 3 clauses: select, from & where. A query takes one or more relations as
input and gives a single relation as output.

Select clause is used to list the attributes desired in the result of the query.
From clause is used to list the relation from which information is to be

Where clause consists of a predicate/ condition involving attributes of the
relations that appear in from clause. General form of SQL query is

Select A1, A2, --------, An

From R1, R2, -----------, Rm
Where P

Where, Ai is an attribute, Ri is a relation,

P is predicate or condition
If predicate P is true then select attributes A1 to An from relations R1 to Rm.
e.g. Select rollno, name
From student
Where city= „Ichalkaranji‟;
This query will select roll numbers, names of students who are from

2. Distinct:
The keyword „distinct‟ is used to eliminate duplicates (repetitions) from the
output of the query.

e.g. Select distinct city

From student
Output of this query will consist of list of cities & city name will not repeat.

3. Asterisk symbol *
To select all attributes from a relation, asterisk symbol, * can be used after
select clause.
e.g. Select * from student
All attributes of student table will be selected.

4. SQL provides logical operators and, or, not which can be used in where clause.
Also SQL provides comparison operators <, <=, >, >=, =, <> which a predicate from
where clause can involve.

5. Like:
The most commonly used operation on strings is pattern matching using
operator like. Patterns are described by using percent (%) operator. This percent (%)
character matches any substring. Patterns are case sensitive & are expressed by like
comparison operator.
e.g. select name from student where class like „%tt%‟;
This query will select names from student table where class includes substring

6. Order by:
In actual practice, it may happen that information is not stored in sorted order.
Order by clause can be used to display information in ascending or descending order
of one or more attributes. General form is
Select A1, A2, -------, An
From R
Order by Aa, ----, Ac asc/ desc
After order by clause, specify attributes Aa to Ac on which records are to be
sorted. Specify order after these attributes. Keyword asc is used for ascending order
& keyword desc is used for descending order.

e.g. Select rollno, name

From student
Order by rollno asc
This query will arrange roll numbers & names in ascending order of roll

7. Aggregate functions
Aggregate functions are the functions that take a collection of values as input
and return a single value. SQL offers five inbuilt aggregate functions:
1. avg: to compute average
2. sum: to compute total sum
3. min: to find out minimum value
4. max: to find maximum value
5. count: to count number of tuples/ collections

The input to avg and sun functions must be collection of numbers. Other
functions operate on collection of numbers as well as nonnumeric data such as

e.g. Select count(*)

From student
This query will count number of tuples (records), student table has.

8. Group by:
Aggregate functions can be applied not only on a single set of tuples but also
to a group of sets of tuples by using group by clause. The attribute or attributes given
in group by clause are used to form groups. Tuples with the same value on all
attributes in the group by clause are placed in one group.
e.g. consider the query “find the number of students coming from a city”
select count(rollno), city
from student
group by address
Here groups of students from same city are formed & then count function is

9. Having:
Having clause is used to specify a condition applicable ot a group of records,
hence it will always comes inconjunction with Group by clause. If the condition in
having clause is TRUE, then that group is selected otherwise not.

Expt: 04
AIM: Study of Visual Basic. NET Integrated Development Environment.

TITLE: Design and implementation of user interface using VB.NET Framework


.NET Framework-
The .NET Framework is a software framework that runs primarily on Microsoft
Windows. It includes a large library and supports several programming languages
which allow language interoperability (each language can use code written in other
languages). The .NET library is available to all the programming languages that .NET
supports. Programs written for the .NET Framework execute in a software
environment, known as the Common Language Runtime (CLR), an application
virtual machine that provides important services such as security, memory
management, and exception handling. The class library and the CLR together
constitute the .NET Framework.


The Visual Studio product family shares a single integrated development
environment (IDE) that is composed of several elements: the Menu bar, Standard
toolbar, various tool windows docked or auto-hidden on the left, bottom, and right
sides, as well as the editor space. The tool windows, menus, and toolbars available
depend on the type of project or file you are working in. Below we see the Visual
Studio IDE (Integrated Development Environment):

The main tool windows such as toolbox, form designer window, code designer
window, solution explorer, properties window are discussed further.

Solution Explorer

From the solution explorer window one can visualize all the files which are
currently in use. Solutions and projects contain items that represent the references,
data connections, folders, and files that you need to create your application. A
solution container can contain multiple projects and a project container typically
contains multiple items.

The Toolbox contains all the necessary controls we need to create our user interface.
It shows various categories such as data, components, windows forms etc. under
each category number of controls to use. In order to use them in our user interface,
we just drag and drop them to the “Form” or we can just double click on the control.

Properties Window
When we select an object like a control in Visual Basic using the mouse, that
object‟s properties appear in the Properties window. To change or examine a
property setting in the properties window, we just find that properties item in that
window (the properties appear on the left in the properties window and their setting
on the right). If we want to change that property, nothing could be easier-just click
the current setting. For properties that we set our self, the current property value is
highlighted, and we just type in the new setting (such as placing new text in a text
box). If the property can only be set to one of a specific range of properties, a
downwards arrow will appear in the property setting box; click this button to see the
possible values this property can have.

Form designer and code designer windows

It shows form which is to be designed for providing graphical use interface. To do
this one has to place desired controls from the toolbox at the appropriate location on
the form.
We just place the code we want to attach to an object in the code window (to
open an object‟s code in the code window, just double click that object). There are
two drop-down list boxes at the top of the code window: the left list lets us select the
object to add code to, and the right list lets us select the procedure to add.
Expt: 05

Title: Design and implementation of VB.Net program for decision making

statements using VB.Net Framework


A program or an application frequently needs to take a decision. For this

decision-making statements are used. Usually these statements consist of a
condition, which is specified by logical, and comparison operators.

Comparison operators:
Comparison operators compare two data values against each other &
produce true or false result. Mathematical or arithmetic operators produce
numeric values, as result while result of comparison operator is either true or
false. Decision making statements use this true or false result to make the
decision. Comparison operators available in VB are = (equal to), < > (not
equal to), < (less than), <=(less than or equal to), > (greater than), >= (greater
than or equal to).

Logical operators:
Comparison operators are used to specify a condition & logical operators
are used to group two or more conditions into a single condition. Result of
logical operators is true or false. Three main logical operators are AND, OR,

Operator Use Result or Output

AND Condition 1 and Condition 2 Result is true if both condition 1 and
condition 2 are true otherwise result is false.
OR Condition 1 or Condition 2 Result is false if both conditions are
false otherwise result is true.
NOT Not (Condition) Result is complement of condition i.e. if
condition=true then result=false, if condition= false then result=true.

Decision Making Statements:

1. If Else statement
General form of If Else statement is
If condition Then
If block
Else block
End If

End If tells where body of if statement ends. During execution,

condition is evaluated if condition is True then if block is executed. After

execution of if block, execution is transferred to the statement next to End If
i.e. if condition is true then only if block is executed & else block is skipped.
If condition is false then if block is skipped & only else block is executed &
then execution is transferred to statement next to End If.
Else is an optional part of If statement. If there is no else block then If
statement look like
If condition Then
If block
End If
So if block is executed only if condition is true.
If else block is absent & if „if block‟ consists of a single statement in a
single line like this.
If condition Then statement
This single line If statement doesn‟t require End If.
If there are multiple conditions then we can nest if else statement in
another if else statement.

2. Nested if else:
When multiple conditions are to be specified, nested if else is useful the
Syntax of which is as follows
If condition1 Then
Elseif condition2 then
Elseif condition3 then
Elseif condition then
Else block
End If

At run time, first condition1 is tested, if it is TRUE then block1 is

executed else condition2 is tested. If condition2 is TRUE then block2 is
executed else condition3 is tested and so on. If condition n is TRUE then
blockn is executed. If all conditions are FALSE, then else block is executed.

3. Select case statement:

Writing deeply nested if else a statement is very difficult. In
such case, we can use select case statement. General form of select case is like
Select case expression
Case value 1
Block 1
Case value 2
Block 2
Case value 3
Block 3
Case value n
Block n
Case Else
Else Block
End select

During execution, expression is evaluated & its value is matched with

case values. If match occurs then that case block is executed & then execution
is transferred to statement next to End select. If expressions value does not
match with any case value then case Else is selected i.e. Else block is executed.
End select tells where body of select case ends.

Expt: 06

Title: Design and implementation of VB .Net program for different loops

(Nested Loop)

Looping statements are used to execute a block of statements repeatedly.
These statements consists of a condition statement block is executed
repeatedly till condition is satisfied. If conditions is unsatisfied then loop
1. Do-While loop:
Do-While loop has 2 versions; we can either evaluate a condition at the
beginning or at the end. Following is syntax for

Condition evaluated at beginning Condition evaluated at

Do While condition Do
[Statements] [Statements]
[Exit Do] [Exit Do]
[Statements] [Statements]
Loop Loop While condition

If condition is specified at the beginning then loop condition is

evaluated first and if it is true then loop body is executed. Again condition is
evaluated, if it is True, again loop body is executed & so on. When condition
becomes false then loop is terminated.
If condition is specified at the end then first loop body is executed &
then condition is evaluated. If condition is true then again loop body is
executed again condition is evaluated & so on. When condition becomes false,
loop terminates. So this form of Do-While loop ensures that loop body is
executed at least once.
Loop tells where Do-While loops ends. Statement Exit Do can be used
to terminate the loop immediately or terminate the loop early.

2. Do Until Loop:
In Do while loop, body of the loop is executed repeatedly as long as condition
is true. Do-Until loop executes, loop body repeatedly till the condition is false.
When condition becomes true, loop terminates. Do-Until loop has also two
versions, condition at the beginning & condition at the end.
Condition at beginning Condition at end
Do Until condition Do
[Statements] [Statements]
[Exit Do] [Exit Do]
[Statements] [Statements]

Loop Loop Until condition

3. While Loop:
Working of While Loop exactly similar to that of Do-While loop, loop
body is repeatedly executed as long as condition is true. When condition
becomes false, loop terminates.
While condition
Wend tells where while loop ends.

4. For Loop:
Do loops & While loop repeatedly execute loop body as long as
condition is satisfied. For loop executes loop body for specified number of
times. Syntax of for loop is as follows

For index = start to end [step size]

[Exit For]
Next [index]

For loop begins with for statement & ends with Next statement. Index is a
variable whose starting value is start & ending or last value is end. Step size is
a value which is used to increment or decrement index variable. If step size is
a positive value then index variable will increment by that value. On the other
hand, if step size is a negative value then index variable will decrement by
that value.
Loop body is executed if value of index variable is in between start to
end range. After execution of loop body, „Next‟ statement will increment or
decrement the index variable by step size. Again loop will check if index
variable‟s value is in between start to end range, if yes then loop body is again
executed. If value of index variable is out of start to end range then loop
Exit For statement can be used to terminate loop at early or immediately.