0% found this document useful (0 votes)
144 views

Core Paper X - Computer Applications in Business: Course

This document provides an overview of the contents and topics that will be covered in Units II through V of the core course "Computer Applications in Business" for Semester IV. The topics include: Unit II covers word processing concepts like templates, editing text, formatting, tables, pictures and mail merge. Unit III will discuss preparing presentations using features like themes, charts, smart art and hyperlinks. Unit IV focuses on spreadsheet applications and how to use features like formatting, functions, charts and linking worksheets. Unit V introduces database management systems and how to create, query and manage databases. The document lists these unit topics and provides some introductory information and examples for the word processing topics

Uploaded by

Tushar Rana
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
144 views

Core Paper X - Computer Applications in Business: Course

This document provides an overview of the contents and topics that will be covered in Units II through V of the core course "Computer Applications in Business" for Semester IV. The topics include: Unit II covers word processing concepts like templates, editing text, formatting, tables, pictures and mail merge. Unit III will discuss preparing presentations using features like themes, charts, smart art and hyperlinks. Unit IV focuses on spreadsheet applications and how to use features like formatting, functions, charts and linking worksheets. Unit V introduces database management systems and how to create, query and manage databases. The document lists these unit topics and provides some introductory information and examples for the word processing topics

Uploaded by

Tushar Rana
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 138

B.Com(Hons.

) Semester-IV

Core Course
Paper X - Computer Applications in Business
Study Material : Unit II-V

SCHOOL OF OPEN LEARNING


University of Delhi

Department of Commerce
CONTENTS

UNIT II WORD PROCESSING

UNIT III PREPARING PRESENTATIONS

UNIT IV SPREADSHEET AND ITS BUSINESS APPLICATIONS

UNIT V DATABASE MANAGEMENT SYSTEM

Editor
Dr. U.S.Pandey

SCHOOL OF OPEN LEARNING


University of Delhi
5, Cavalry Lane, Delhi
Delhi-110007
Unit II

WORD PROCESSING
 Word Processing: Introduction to word Processing,
 Word Processing concepts,
 Use of Templates, Working with word document:
 Editing text, Find and replace text, Formatting, spell check, Autocorrect,
 Auto text; Bullets and numbering, Tabs, Paragraph Formatting, Indent,
 Page Formatting, Header and footer, Tables: Inserting, filling and
 formatting a table; Inserting Pictures and Video;
 Mail Merge: including linking with Database;
 Printing documents. Creating Business Documents using the above facilities.

WORD PROCESSING: INTRODUCTION TO WORD PROCESSING


The concept of word processing was introduced in 1972. The change in title from “typist” to
“word processor” has improved morale and encouraged Word Processors to use computers.
Word processors used this software to create, edit, and print, running text in a form of
documents which can be stored into computer for a long time and there is no need to retype
the same information again and again as it was on typewriter. Information can be edited any
time and any number of times.

WORD PROCESSING CONCEPTS


For all computer applications, word processing is the most common. To perform simple
typing or word processing, you need a computer and a special software/ program called a
Word Processor. A word processor enables you to create a document, store it electronically on
a Hard Disk or any other storage media of a computer, display it on a screen, modify it by
entering commands and characters from the keyboard, and print it on a printer.
The great advantage of word processing over using a typewriter is that you can make changes
(editing) without retyping the entire document. If you make a typing mistake, you simply use
the arrow keys to replace the cursor and correct your mistake. If you want to delete a
paragraph, you simply remove it, without leaving a trace. It is equally easy to insert a word,
sentence, or paragraph in the middle of a document. Word processors also make it easy to
move sections of text from one place to another within a document, or between documents.
When you have made all the changes you want, you can send the file to a printer to get a
hardcopy.
Some commonly used word processors are:
— Word Perfect
— Perfect Writer
— Word Star
— Lotus Notes

1
USE OF TEMPLATES
Templates have some features in all documents that are being sent. For example, the letter
pads head or the end of the letters. They may be pre-defined and stored in Boiler plate text
called as Templates. With this example you can easily understand the uses of Templates.
Working with Word document : Editing Text, Opening / Creating new documents

Shows how to open Microsoft word


The word window contains various components they are
1. Home
2. Insert
3. Page Layout
4. References
5. Mailing
6. Review
7. View
8. PDF(if installed)
Some of the default tool bars are shown in the Figure below

Menus of Microsoft word

2
View of Microsoft word
When we open document in MS-Word it looks like the same Working with word document :
Office Button:
Office Button is used like File Menu to open an existing document / creating a new document.
Which is part of Menu Bar can be used for Creating a new document or Opening of
previously stored document in a given below Figure.

Opening of a New Document

3
New Option is used to open the new blank document and short cut key Ctrl
+N (Control key and N both keys to be pressed simultaneously).

Opening of a Template
Open Option is used to open already/previously stored file short cut key is Ctrl + O see fig
below

Opening of a file from list of files


4
FIND AND REPLACE
Find command is used to find the specific text / number from the file. After finding the text or
number you can also replace the text/ number with some other text / number. For example if
you typed Vaneeta in the text but that is Navneeta. So with the help of find with replace
command you can change this particular word with navneeta in the entire text. You can try
using this example.
Example 1: find and replace command
Vaneeta and sunita are good friends and they used to visit gym every day in the morning.
Vaneeta used to call Sunita every day but one day sunita did not come for calling vaneeta.
That day vaneeta did not wake up and missed the gym.
(You have to use find and replace command and replace Vaneeta with Navneeta)

Find and replace command

Find command in MS Word

5
Replace all command will replace all the words according to the example
1 Formatting, spell check,

Test Alignment
There are four types of text alignments
1. Left Alignment
In case of left alignment text starts from left side of the page and blank spaces comes
on the right side of the page.
2. Centre Alignment
In case of Centre alignment text starts from centre of the page and blank spaces comes
on the right side and left side of the page.
3. Right Alignment
In case of Right alignment text starts from Right side of the page and blank spaces
comes on the left side of the page.
4. Justified Alignment
In case of left alignment text starts from left side of the page and touches on the right
side of the page and blank spaces comes between the text.
Autocorrect : This option is used to correct the spelling mistakes in the document file. For
example
If you are typing SCHOL
THE Auto will correct it with SCHOOL
The menu is shown below how this command works

6
7
Bullets and numbering,

Use of bullet and numbers for main point and numbering of the text.

For numbering of points in the text


3. Tab
This is used for indenting the text for complete paragraph. Tab key of the keyboard is used.
4. Paragraph Formatting,
There are various methods of paragraph formatting. Here are some of the methods
mentioned below. You have to use and practice and see the impact of these commands.

8
Paragraph settings : Includes Line spacing, indentation, and alignment

For shading

9
For sorting

Border

Increase an decrease indent

Show / hide paragraph spaces only


5. Indent :This is used to indent first line of each paragraph
6. Page Formatting,

Page formatting Page Layout, Themes, Page Setup, Page Background, Paragraph,
Arrange

10
Themes

Orientation

Page setup

11
See command for page size

Type of page sizes

Multiple columns can be created

12
13
14
REFERENCES MENU includes Table of Contents, Footnotes, Citations & Bibliography,
Captions, Index , Table of Authorities

7. Header and footer,


Header :This is used for writing name of the book/chapter of the book / page number
of the book on the top most of the page.
Footer :This is used to write Page numbers on the bottom of the page and this is also
used to write some information about some words. (Description of the word on the
bottom of the page).

15
8. Tables:Inserting,

Tables
Inserting Table. 8 Rows and 10 columns can insert according the given table option

Insert Table

Insert Picture ( from illustration) from File

16
Insert Clip Art

Insert Shapes

Insert Smart Art

17
Insert Charts

Insert Chart
Insert Hyper Links

Hyper Link

9. filling and formatting a table;


The format Table is used for format Table. Commands how to use this is mentioned
below:

18
Example how to create file is shown below :

10. Inserting Pictures and Video;

19
Mail Merge: including linking with Database;
Mail Merge is used to merge two documents in to one. There are many examples of
Mail Merge used in our day to day life and various applications.

11. Printing documents,


The following steps will help you print your Microsoft Word document.
Step 1 − Open the document for which you want to see the preview. Next click the File tab
followed by the Print option which will display a preview of the document in the right
column. You can scroll up or scroll down your document to walk through the document
using given Scrollbar. The middle column gives various options to be set before you send
your document to the printer.

20
Step 2 − You can set various other printing options available. Select from among the
following options, depending on your preferences.

CREATING BUSINESS DOCUMENTS USING THE ABOVE FACILITIES


Create a document file using following instructions
Size of the page should be legal
Orientation will be landscape
Four column News from any daily English Newspaper
Using New Times Roman font size 12

21
Unit III

PREPARING PRESENTATIONS
Preparing Presentations: Basics of presentations: Slides, Fonts,
Drawing, Editing; Inserting: Tables, Images, texts, Symbols, Media;
Design; Transition; Animation; and Slideshow.
Creating Business Presentations using above facilities.
PREPARING PRESENTATIONS BASICS OF PRESENTATIONS: SLIDES
Creating a presentation in Microsoft PowerPoint involves starting with a basic design; adding
new slides and content; choosing layouts; modifying slide design, if you want, by changing
the colour scheme or applying different design templates; and creating effects such as
animated slide transitions. The information below focuses on the options available to you
when you start the process.
The New Presentation task pane in PowerPoint gives you a range of ways with which to start
creating a presentation. These include:
Blank Start with slides that have minimal design and no colour applied to them.
Existing presentation Base your new presentation on one that you have already written and
designed. This command creates a copy of an existing presentation so you can make the
design or content changes you want for the new presentation.
Design template Base your presentation on a PowerPoint template that already has a design
concept, fonts, and color scheme. In addition to the templates that come with PowerPoint, you
can use one you created yourself.
Templates with suggested content Use the AutoContent Wizard to apply a design template
that includes suggestions for text on your slides. You then type the text that you want.
A template on a Web site Create a presentation using a template located on a Web site.
A template on Microsoft.com Choose from additional PowerPoint templates in the Microsoft
Office Template Gallery. These are arranged according to type of presentation.
Note The hyperlink in this topic goes to the Web. You can switch back to Help at any time.
Content inserted from other sources
You can also insert slides from other presentations or text from other applications such as
Microsoft Word.

22
Create a presentation using blank slides
Blank Presentation: Blank presentation contains only the outline and there will be no
presentations. It contains values for colour, font, etc.

Presentation using blank slides

Pick a Look Wizard contains different models of presentation. User can select the “look
and feel.” User can create the presentation for black and white transparencies, colour
transparencies, on-screen presentation etc. Slide background, notes, audience handout etc.
can also be included in the slide.
1. On the Standard toolbar, click New.
2. If you want to keep the default title layout for the first slide, go to step 3.
If you want a different layout for the first slide, in the Slide Layout task pane, click the
layout you want.
3. On the slide or on the Outline tab, type the text you want.
4. To insert a new slide, on the toolbar, click New Slide, and click the layout you want.

23
a. Presentation using blank slides
5. Repeat steps 3 and 4 for each new slide, and add any other design elements or effects
you want.
6. When you finish, on the File menu, click Save, type a name for your presentation, and
then click Save.

Create a new presentation from an existing one

24
When you follow these steps, you create a copy of an existing presentation so you can
make design and content changes to it for a new presentation, without altering the original.
1. If the New Presentation task pane isn’t displayed, on the File menu, click New.
2. Under New from existing presentation, click Choose presentation.
3. In the file list, click the presentation you want, and then click Create New.
4. Make the changes you want to the presentation, and then on the File menu, click Save
As.
5. In the File name box, type a name for the new presentation.
6. Click Save.

 Fonts,
Fonts can be embed in the file

 Drawing,
Inserting Drawing Objects
You can add a variety of diagrams, using the diagramming tools on the Drawing toolbar.
Diagram types include Cycle, Target, Radial, Venn, and Pyramid. Use the diagrams to
illustrate various conceptual material and enliven documents and presentations (diagrams
are not numerically based).
Diagram (radial type) Diagram toolbar Drawing sizing handle Drawing border
When you add or change a diagram, the diagram appears with drawing space around it,
outlined by a non-printing border and sizing handles. You can size the diagram by using
sizing commands to make the drawing area larger so you have more room to work, or you
can get rid of extra space by fitting the border more closely to the diagram.
Format the entire diagram with preset styles; or, format pieces of it like you format shapes
— add colour and text, change line weight and style, and add fill textures, and
backgrounds. Use the Diagram toolbar that appears with your diagram to add elements or
segments and to move them forward or backward. You can also animate a diagram to
direct focus to different pieces of a diagram and control the flow of information during a
presentation.
Flowcharts
Flowcharts (or flow diagrams) can be created using a combination of AutoShapes on the
Drawing toolbar, including flowchart shapes and connectors.
On the Drawing toolbar, click Diagram. Click one of the following diagram types:
25
• Venn
• Cycle
• Pyramid
• Target
• Radial
Click OK.
Do one or more of the following:
If you want to add text to an element in the diagram, right-click the element, click Edit
Text, and then type the text.
For cycle and target diagrams, you can only add text to the text placeholders that appear
when you insert the diagram or diagram element.
If you want to add an element, click Insert Shape on the Diagram toolbar.
If you want to add a preset design scheme, click AutoFormat on the Diagram
toolbar, and select a style from the Diagram Style Gallery.
Click outside the drawing when you are finished.
 Editing;
Opening an Existing presentation:

26
OPENING AN EXISTING PRESENTION
Select O. Open an Existing presentation – Select the files.ppt-Click OK.

Work Area
The work area of the PowerPoint contains Outline Area, Menu Bar, Toolbar, Slide area etc. In
the bottom, there will be view buttons, Status bar, Drawing tool, notes area etc.

27
Views in PowerPoint
Five different views are available in PowerPoint.

1. Normal View : In which only the current slide is seen


2. Outline View : in which a test outline of the presentation is seen.
3. Slide Sorter View : In which thumbnail images of each slide in the presentation are seen.
4. Notes Page View : In which a small image of the slide is accompanied by a notes section
5. Slide Show : In which a full sized version of each slide is seen on the full computer screen.
MASTERS IN MS POWERPOINT
Masters are like that of a letterhead. The Matters incorporated will not change like the name
of the firm, address, logo, date, reference etc.
There are many masters in PowerPoint. They are Slide Master, Title Master, Handout Master,
The Notes Master etc.
Slide Master
Slide Master is used to control text characteristics of the presentation. Font Type, Font Size,
Color, background color and effects such as shadowing, bullet style etc. can be controlled. For
this purpose, Text Box Button on the Drawing Toolbar can be used.
Title Master
Title master is used to show a different look for titles. It will create more emphasis for the
title.
Notes Presentation
Notes Presentation is used to add the items on the notes which may be art, text, headers etc.
Slides can be viewed in Black and White. For this purpose:
View - Black and White – Click. Slide Miniature is used to minimize the slide. It is a tiny
slide that resembles the current slide. For this purpose:
28
View – Slide Miniature – Click.
Zooming can also be done.
Handout Master
Handout master is used to add items in the presentation. Items such as text,
art, header, footers, date, time, page number etc can be added in the presentation.
Slide Master
You must be working in slide View to edit text, images, or colors on the slide.

There are two options in slide master


1. Insert Slider Master
2. Insert Layout

Insert Slide Master: This is used to add a new slide master to the presentation

Insert Layout : Add a new slide master to the presentation . CTRL +M is used

29
Outline View
In outline view you can quickly scan the entire presentation, edit text, but
not the color of text or do a spell check. You could also print the outline view to
keep for speaker’s notes as you present your show.
 Inserting: Tables,

Use PowerPoint Insert -> Table.


 Images,
The below mentioned pic shows how u can use image in Power Point
Select FORMAT-> Picture Styles

Power Point has introduced many new features like : Change of size , Rotation , picture can
be Crop , Backgrounds and many image effects
30
 Symbols,

31
32
 Media;
This is used for online recording from latest power point versions specially from 2016
on wards
Themes
1. Select the Design tab.
2. Select one of the Themes
Themes.
3. Select one of the Variants
Variants.

Use PowerPoint Designer


1. Insert one or more pictures, a list of items, or a list of dates.
2. The Designer panel will open. Select the design you want.
You can also bring up Designer by selecting a picture, and then selecting Design >Design
Ideas.

 Transition;
This is modern and motion effect that can used with add movement in the slide.’
Applying Transitions are used for the many special effects in various slides

 Animation;
Animation is very useful tool now a days and this can be used in various formation of
the files
33
Like JPG and MP4 etc.
All whatsapp applications can be used for the animation
 Slideshow,
I recently created a photo slideshow (using PowerPoint) of my dad’s life-sized chess set
sculpture that’s at Facebook (Go Dad!).
I found that PowerPoint was a surprisingly powerful slideshow creation tool.
And once I learned the basics, I was able to create my next slideshow in under 1 minute!
Below is what I learned, as well as some bonus lessons such as adding music, creating a
custom title slide, saving the slideshow as YouTube video, and more.
 Creating Business Presentations using above facilities.
Presentation should be of at least 10 pages.
Use of flow chart is required
Times new Roman font be used with font size of 12
Take the news from English news paper and make PPT on Indian Economy.

34
Unit IV

SPREADSHEET AND ITS BUSINESS APPLICATIONS


Spreadsheet Concepts
Managing Worksheets : Formatting, Entering Data
Printing worksheet
Worksheet Concepts
Methods of building a workbook
Important features of Excel
Shaving Workbook
Editing in workbook
Entering data in a cell
Formula copying
Moving data from selected cells
Rearranging worksheet
Project evolving multiple spreadsheets
Summary of the chapter
Exercise

SPREADSHEET CONCEPTS

Spreadsheet is defined as a large sheet containing a matrix of rows and columns. It is an


effective tool for keeping track of all sorts of data like student attendance, marks and grades, a
list of major purchases and amounts etc. It provides the facility to organize data into rows and
columns. Excel is one of the Microsoft Office tools, which is used to create spreadsheets. It
might some time you realized the importance of computer in everybody’s life. It has now
come to a stage that without computers it will be very difficult to perform certain tasks in our
life, for example, banking transaction, railway, airlines and other transport reservation, traffic
controls etc. Many business applications require the analysis of data, which may involve
statistical and mathematical calculations. In these kinds of financial and commercial
applications Spread Sheet Software plays an important role. The Spread Sheet makes the
calculations, analysis, and presentation of any numerical data in a very simple and effective
way. There are quite a few application packages available in this category, viz. Lotus 1-2-3,
Quattro Pro,Symphony, Excel, etc. Ms Excel is Windows based Spread Sheet developed by
Microsoft Corporation.

35
MANAGING WORKSHEETS : FORMATTING, ENTERING DATA

Explain the method for building a worksheet.


The worksheet is a grid of Columns (designated by letters) and Rows
(designated by numbers).. It is the important part of Excel. The letters and
334 Computer Fundamentals and Information System
numbers of the columns and rows called labels are displayed in gray buttons across the top
and left side of the worksheet.
The intersection of a column and a row is called a cell. Shown in figure below and the cell
reference is A1 ( A means column name and 1 means row name)

Figure above shows the cell which is intersection of coloumn( shown in alphabets and row
shown in numbers only) Each cell on the spreadsheet has a cell address that is the column
letter and the row number.

36
The column name and row number forms the address. For example, in the first row the first
column has the address A1, the next column B1, like this. The second row of first column has
the address A2. Cell is formed by the interaction section of column and row, formula has to be
used only with reference to cell address.
The left most line shows the numbers from 1 to 18 rows and the top most line of the
worksheet shows A to I columns. However, there are 256 columns and 16384 rows in the
worksheet. The Excel worksheet is about 7 meters wide and 100 meters long. The rows are
numbered from 1 to 16,384. The columns are named as A to Z then AA, AB, AC,…, BA, BB,
etc.
Data Type in a Worksheet
MS-Excel recognizes four types of data.
1. Numbers
2. Text
3. Formula
4. Date and Time
1. Numbers or Numeric Data :- This can be any numerical value, consisting of digits ( 0-
9), leading + or – sign, decimal point (.), and numerical operators are +, -, /, *, %, (, ) , $,
E, e,. If you type the data, which begins with any other character, then it will be treated
as nonnumeric value.
2. Alphanumeric or Text Data :- The text data, may contain a combination of alphabets,
spaces, digits and any other characters; for example, 75XYZ , 75-123, ABC 12. Texts
are aligned to the left of the cell.
This may be changed using the alignment command, from the formatting tool bar.
3. Formula :- Formula is sequence of values, Cell-addresses, names, function or operators
in a cell that produces a new value from existing values. It is a equation that analyzes
data on a worksheet.
Formula in MS-Excel start with = sign. The formula = A4+B7 will add the contents of
cell A4 and B7 and put the resulting value in the current cell.
4. Date and Time :- Microsoft Excel stores dates as sequential numbers known as serial
values. Excel stores the time as a decimal fraction because time is considered as a
portion of a day. Dates and time are values and, therefore can be added, subtracted and
included in other calculations.

ENTERING DATA IN A CELL

A is the column name and 1 is the row number and the cell reference is A1 as the same B is
the name of the column and 1 is the row number. These cell references used in formulas
where as there is no need to write values.

Editing Cell Data


Editing can be done only in active cells. Press F2 or double click the cell for editing. The
status bar shows edit and the formula bar shows the data in the cell.343

37
Editing can be done in the cell or in the active bar. Press Home key to get the cursor to the
first position that is left of data in the cell. Press Del key to delete and enter “andpress enter”
The data is aligned right.
Label prefix characters and label itself can be edited by F2 key. If Excel is operating in Insert
mode, typing can be done. OVR shows the Overtype mode and INS shows the Insert mode.
If many changes are to be done, editing can be done directly by selecting the cells and
entering new data. It replaces the entire old data with new data. Confirm button can be clicked
or Enter can be pressed to save changes in the cells. Sum function is an inbuilt function.
For example, formula = C3 + D3 + E3 +F3 + G3 + H3 can be easily added ifthe sum function
is clicked which is in the status bar. Ranges can also be specifiedin Formula bar which can be
used for sum function. Select the cell and to get theresult press = Sum (C5: E5)
Example :
Sometimes error may occur if any non-numeric data are entered in the cells.Sum function can
be used for numbers only and not for characters.Sometimes if the range is not given the
formula is displayed in the cell andthe results can be got.
If you want total activate cell A9 and type total : Then activate cellB9byarrow key. See fig.

Showing formula

Showing solution using formula

38
You can add sales total vertically or add BLD in horizontal manner by pointer.
It may be either:
= Sum (D2 :D7) or
= Sum (E2 :E7)
Mouse can be used to click the Sum function in the tools bar.
Change of Row Height or Column Width
Sometimes the data entered in the cell may require more space than the column width. The
full data or numerals cannot be visible in the cell. Sometimes the character entries may not be
visible as the column width is not sufficient. For this purpose column width is to be changed.
Changes in column width can be made.

For cells command

Fig Shows the way you can change the size of the cells with row height and column width
command in the Home Menu-> Cells

39
SAVING THE WORK BOOK
The file should be saved before switching off the computer. The worksheetentries are first
stored in RAM and they are to be saved in the hard disk or thefloppy disk. See fig showing
saving of workbook for that purpose, the file is to be saved by giving a name.

Fig shows saving of workbook using various methods

1. Use save button on the standard tool bar.


2. Use save Command from the file menu
3. Use Keyboard keys ^S to Save the file
4. Use close in the work sheet window. The MS office assistant will ask “ Doyou want to save
the file? Press Enter. The file will be saved with .xlsx tag.

40
339
Some of the important points to be noted are that the worksheet is mostlyused for
manipulation of data at various levels. High Level manipulations aredone in the worksheet.
Keyboard and Mouse are mostly used as input devices.

41
42
43
44
45
EDITING IN WORK BOOK
What does Editing of Cells mean? Explain.
Editing is the concept of making changes, modification or corrections in thedata as well as
positioning data as per requirements. Data can be edited only ifthe concerned cell is made
active. Some of the functions of editing and functionsare to be studied.
Alignment of data

Fig shows various types of alignments in ms excel

The data in the cell may be either left aligned or right aligned as default. Number will be right
and the character data are aligned left in default. For example, Name is aligned left in the cell
and 85 is aligned right in the cell.
To change the alignment in cells the alignment button can be used for this purpose formatting
tool bar is to be used.
In the formatting tool bar, there are four buttons for alignment. They are
(a) Right align (b) Left align (c) Center align (d) Center across column
Marks MarksMarksMarks
A specific cell or a series of range of cells can be selected for alignment proposes.After
selecting the cell or series of cells, place the pointer on the specific button,right or left or
center align and press. The cell data or center cells data will bealigned as per instructions.
The center across the columns button can be pressed for aligning data in Cparticular cell. For
example, the cell data mark-sheet can be selected and thenthe button center across columns is
to be pressed. Then the data will be alignedcenter across columns.
Wrap text command is used to wrap text in the specified cell , shown in fig a

Fig a wrap text command


For example showing below “This is my wraping of text “ in a single sentence and wrap
text command will fold the text according to the shape / size of the of the cell. Shown in
fig below

46
Result shown in fig below

Fig shows how to merge and centre text in excel file using merge & centre command.

Fog merge & centre command.


See fig below “type this line in a cell “this is my wraping of text”shown in fig below

Fig shows a single line typed in the excel

Fig shows that all three cell A,B,C are merged together and comes into centre of the these
three cells.
INSERTING, DELETING WORKSHEETS

47
Fig. shows how to use insert, delete and renameing worksheet

Fig shows Insert worksheet


Worksheet can be inserted using Insert Menu command. See fig 5.17 and fig 5.18 You can
also name the sheet1,sheet 2, sheet 3 according to your choice and work using rename
command. Steps to rename the sheet1 are given below:
1. Select the Sheet1 Press right click of the mouse and select rename command shown in the
figure below. Give new name according to your choice after using rename command give new
name to the sheet1 of your choice shown in the figure below (Sheet1 rename to Payroll)
Selected Sheet can be deleted using delete command. Steps to remember are select the sheet -
>right click the mouse ->select delete command.
FORMULA COPYING

Fig.
If you copy formula from D2 cell to F2 cell the cell references will change automatically. This
is somehow advantage of Excel that Total class/ marks is calculated for every employee.

48
But in some cases we need same Cell value for all calculations, see figure below using $ to fix
Cell references by putting $sign in front and after the Alphabet ($A$) for example given
below Instalment Amount is same for all calculations so we are using = $B$1 to $B$6 cell
reference , see figure below

Fig.use of $ for fixed cell reference


Opening a new file
Select the MS Excel program directly by clicking the Icon in the Desktop if it is in Desktop.
If MS Excel is in the programs menu, select MS Excel from program and click. By using
keyboard form windows key. Use arrow key to select the program menu and then MS Excel
program and press Enter. Now MS Excel window with Book 1 opens and it will be a new
work-sheet.
If any one of the existing files say mark list .xls is to be opened. Open file menu Alt + F and
use key to select open command. Standard Tool bar contains a button Open. Now the files
will be opened. The open dialog box will save some of the files, directories, sub-directories
and Excel files and the directories drive.
File can be opened by typing the File menu in the text area provided. You can open the file of
your choice. Otherwise you can use the scroll bar to select the required file.

49
MOVING DATA
The worksheet file already prepared may have to be changed or moved to some other files or
area. All the columns and row may not be needed and hence the data required are to be
removed.

Data can be short and filter using short & filter command

Movement of data can be done by moving cell data. All cells can be moved or some specific
cells can be moved.
The ways for moving data are :
(1) Use of cut and paste command, and
(2) Mouse movement.
Cut and paste

The required columns and rows can be selected by for the purpose of moving.
For example, the file has the following:

Fig shows salary statement


The general method is to select the required cells, order cut and then go to the area already
selected, order for paste. In this case if first 4 rows are to be moved the following should be
done. Make A1 cell active by pressing ^Home or Home key or by mouse. For cutting A1 cell :
Dotted moving line is seen in the border around the cell. The dotted moving line is called as
“MARQUEEING”. Now the status bar shows select the destination and press enter or choose
paste. Now use arrow key to move the pointer to C1 from A1. Then press enter key. Or use
mouse to select or activate C1 cell.

50
^V can be used for paste command that is the short cut key.
Now the data is moved from A1 cell to C1 cell.
Mouse pointer shape may be in three kinds:
1. When the pointer is inside the cell.
2. Arrow mark when it is outside the borders.
3. If the pointer is in the right corner (bottom) of the border.
Without releasing the button drag the mouse pointer to C1 cell. A Grey border is seen around
C1 cell. If the mouse button is released the data is moved to C1 cell.
Copying data to another area
If the same data are to be copied in another area, then copy command can be used.
1. Copying data in single cell.
2. Copying data in range of cells.
3. Copy the data to C new location.
4. Copy the data to C new area in the worksheet.
For example, if the data in B1 cell is to be copied in H1 cell.
Activate B1 cell by using arrow keys or mouse. Open Edit menu-use Copy command. Select
the new cell H1 by activating the cell by arrow key or mouse click. Paste command. Now the
data in B1 is pasted in H1 also.
For erasing the cell data
— Activate B2 cell and press Del.
— Now data in B2 is deleted.
— Activate B2 cell and press shift key use arrow or arrow to select cells
and release the button. Now series of cells are selected.
— Press Del in keyboard.
— The selected cells are cleared and data are erased.
For the purpose of deleting rows
Move mouse pointer to row (left side) and click and right click. Delete dialog box will appear.
Select shift cells up or entire row options. Then the entire row will be deleted.
In the similar manner, series of rows and columns can be deleted. Model :
Delete using Keyboard
— Activate B1 cell or B2 cell using pointer.
— Open Edit menu, select Delete command.
— Delete dialog box is opened.
— Select shift cells up or entire row and Press OK.
— Now the cell row is deleted.
51
Delete using keyboard
— Activate any column in C by using arrow key.
— Press Ctrl + Space bar to select column C.
— Right click mouse or press Shift + F 10.
— Short cut menu appears. Choose delete command.
— Now rows are deleted. If column is selected then column will be deleted.
Entering data in workbook.
In the formula bar, now A1 is seen. In the status bar, the word Ready is
found. The mode indicator shows ready. The terms such as edit, point, etc. can
be seen as mode indicators. The cells can save values and formula. The values
may be characters or numerals. The word length should not be more than 255
characters.
Examples of numeric entries :
2346
0.2346
23.46
+23.46
-23.01
#345
(567) – this is taken as – 567
If any non-numeric characters are found then the entire cell will be a non- numeric cell.
Example, 10th March, 1990-91, 34 + 5, 1234_76, etc. Non-numeric or characters entries
Sampath Raj
Sunandha
V. Pad
K.S.V.
Accounting year
7.2.98
REARRANGING WORKSHEET
Rearranging can be done by selecting worksheet for example salary of Feb2009should come
before salary of March 2009.In WINDOW menu arrangeoption can also be use to arrange.
See figure below

52
PROJECT INVOLVING MULTIPLE SPREADSHEETS HANDLING OPERATORS
IN FORMULA
There are four types of operators in Excel as follows:
1. Arithmetical Operators
2. Relational Operators
3. Text Concatenation Operator
4. Reference Operators
Arithmetical Operators Relational Operators Text concatenation Reference Operators
Operator
num( ) Parenthesis > Greater than : (colon)– Range
^ Exponential < Less than Operator
# Multiplication <= Less than or equal
/ Division to &
+ Addition >= Greater than or
- Subtraction equal to , (Comma) – Union
= Equal to Operator
Not equal to
Examples for Operators:
Arithmetical Operators:
Arithmetic operation can be entered in the formula bar.
Example:= 3 ^ 3 * 7 – 9
Here as per the operator precedence first 3 ^ 3 will be evaluated that is 27.
Then * is done 27 × 7 = 189 – 9 = 180 will be displayed. Brackets can be used for
changing the results 3 ^ 3 * (7 – 9) = 27 * (-2) = - 54

53
Operator precedence
^ - exponential
* - Multiplications
/ - Division
÷ - Remainder
+ - Addition
- - Subtraction
1. Parenthesis : = 7*(5+4) gives 63
2. Exponential : = 7^2 gives 49
3. Multiplication : = 5 * 6 gives 30
4. Division : = 45 / 9 gives 5
5. Subtraction : = 35-6 gives 29
Relational Operators:
1. Greater than : = 7>5 returns TRUE
2. Less than : = 7<5 returns FALSE
3. Less than or equal to : =5<=7 returns TRUE
4. Greater than or equal to : = 7>= returns FALSE
5. Equal to : = 7=9 returns FALSE
6. Not equal to : = 59 returns TRUE
Text Concatenation Operator
Example : =”Sampath”&Raj” gives SampathRaj
Reference Operators:
: Colon = B2:B10 means reference from cell B2 to B10.
, Comma = SUM (B2:B10,D2:D10) means adding the values from B2 to B10
and D2 to D10.
PRINTING WORKSHEET
Print button on a standard tool bar enables to print entire or a part of the worksheet. When you
print, you can change the page set up, i.e., top, bottom, left, etc. We can print the Mark list.
XLSX worksheet that we had created. Print command can be used only on worksheet that is
locked in memory of the PC.
• Open the MARK LIST.XLSX work sheet.

• Open the menu and choose see figure below and use

54
the print Command.
• Then Excel displays print dialog box.
It helps us to select what to print. It also has select options such as the number of copies, page
range and to set up page and printer. In the top left corner of the dialog box, it displays the
name of the printer and the printer type. The printer name can be selected by pressing printer
set up button. If you try to print with a different printer you are using, then it is selected in the
print dialog box. Else you may not get the correct print-out.
The print dialog box contains a number of options. However, the default options are current
worksheet. By default Excel prints one copy of the current sheet. The Excel worksheets have
multiple sheets. It is used for complex tasks. Most of these can be completed within a single
sheet. Press ENTER or Click the OK button. Excel starts printing the worksheet. Print dialog
box differs according to the specification. The print has various options such as selection,
selected sheets, entire workbook. Number of copies can also be changed. Range can be
selected. Either all pages can be typed or pages from-to-can be printed.
In the dialog box there are buttons with O.K., cancel, page set-up, Print preview, printer set-
up and Help. Printer Set-up and help can be studied separately. Page Set-up: In the page set-
up dialog box, following options are available :
Orientation may be portrait or Landscape, Paper printing may be horizontal
or vertical. Sealing can be done as adjust to % of size. Fit to page can be given,
wide can also be given. Page size can be selected. Print quality may also be
selected. Use mouse pointer to click the options available.
FUNCTIONS IN MS-EXCEL
Functions are predefined or in built formulas that can perform calculations by using specific
values or range of cells, called arguments, in a particular order, or Figure below is showing
how you can use functions.
First go to Formulas -> Function Library

55
Figures will help to use all the four functions in your syllabus structure. Functions can be used
to perform simple or complex

Fig. functions
calculations. Function can be called from Function Library see in the figure below, a list of
available functions will appear or by a short cut method if you click a cell and press
SHIFT+F3 a list of available functions will appear see in the figure

Fig function library


Some to the commonly used following functions are:
1. Mathematical function see fig below

Fig. Mathematical functions

56
2. Statistical function see figure below

Fig Statistical functions

3. Financial functions see figure

Fig of financial functions

4. Logical functions see figure below

Fig Logical functions

57
In figure above you can find various functions but most commonly used functions are
financial, Mathematical & Trigonometric ( Math & Trig), Statistical and Logical.
STRUCTURE OF A FUNCTION
Structure :The structure of a function begins with an equal sign (=), followed by the function
name, an ([)opening parenthesis, the arguments for the function separated by commas, and a
(])closing parenthesis.
Arguments :Arguments can be numbers, text, logical values such as TRUE or FALSE, Group
of numbers (array), or cell references. The argument you designate must produce a valid value
for that argument. Arguments can also be constants, formulas, or other functions.
Entering formulas :When you create a formula that contains a function, the Insert Function
dialog box helps you enter worksheet functions. As you enter a function into the formula, the
Insert Function dialog box displays the name of the function, each of its arguments, a
description of the function and each argument, the current result of the function, and the
current result of the entire formula.
See example given below the SUM function adds all the numbers
specified in the argument i.e. values or can be range of the numbers like A1 cell
to A10 cell.
Example
= Name of the function ( parameter1, parameter 2)
= SUM(number1, number2)
Or
= SUM(A1,A2, A3,A4)
Or
= SUM(A1:A4)
FINANCIAL FUNCTIONS
PMT
Calculates the payment for a loan based on constant payments and a constant interest rate.
Syntax is = PMT(rate,nper,pv,fv,type) Rate – Interest rate for the loan.
Nper– Total number of payments for the loan.
Pv– Present value, or the total amount that a series of future payments is
worth now; also known as the principal.
Fv– Present value, or a cash balance you want to attain after the last payment is made. If fv is
omitted, it is assumed to be 0 (Zero), that is, the future value of a loan is 0.
Type - is the number 0 (Zero) or 1 and indicates when payments are due. Set type equal to 0
or omitted If payments are due at the end of the period. 1 If payments are due at the beginning
of the period.

58
Remarks
The payment returned by PMT includes principal and interest but no taxes, reserve payments,
or fees sometimes associated with loans. Make sure that you are consistent about the units you
use for specifying rate and nper if you make monthly payments on a four-year loan at an
annual interest rate of 12 percent, use 12%, 12 for rate and 4*12 for nper. If you make annual
payments on the same loan, use 12 percent for rate and 4 for nper.
Tip – To find the total amount paid over the duration of the loan, multiply the returned
PMT value by nper.
Examples
The following formula returns the monthly payment on a Rs. 20,000 loan at an annual rate of
16 percent that you must pay off in 20 months. For the same loan, if payments are due at the
beginning of the period, the payment is: PMT (16% / 12, 20, 20,000, 0, 1) equals -- Rs.
1,130.79 The following formula returns the amount someone must pay to you each month if
you loan that person Rs. 10,000 in at 24 percent and want to be paid back in 10 months.
You can use PMT to determine payments to annuities other than loans. For example, if you
want to save Rs. 50,000 in 18 years by saving a constant amount each month. You can use
PMT to determine how much you must save. If you assume you’ll be able to earn 6 percent
interest on your saving, you can use PMT to determine how much to save each month.
PMT (6%/12, 0, 50,000) equal –Rs.129.08
If you pay Rs.129.08into a 6 percent savings account every month for 18 years, you will have
Rs. 50,000.
IPMT
Returns the interest payment for given period for an investment based on periodic, constant
payments and a constant interest rate.

Syntax of the function is =IPMT(RATE,PER,NPER,PV,FV,TYPE)


Rate – Interest rate per period.
Per – Period for which you want to find the interest and it must be in the
range 1 to Total number of payment periods in an annuity( NPER)
Nper – Total number of payment periods in an annuity.
Pv – present value or the lump-sum amount that a series of future payments is worth right
now. Fv – future value or a cash balance you want to attain after the last payment is made. If
fv is omitted, it is assumed to be 0 (the future value of a loan, for example, is 0).
Type – number 0 or 1 and indicates when payments are due. If type is omitted, it is assumed
to be 0.
Remarks
Make sure that you are consistent about the units you for specifying rate andNper. If you
make monthly payments on a four-year loan at 12 percent annual
59
Interest, use 12%/12 for rate and 4*12 for Nper. If you make annual payments on the same
loan, use 12% for rate and 4 for Nper. For all the arguments, cash you pay out, such as
deposits to savings, is represented by negative numbers; cash your receive, such as dividend
checks, is represented by positive numbers.
PPMT
Returns the payment on the principal for a given period for an investment based on periodic,
constant payments and a constant interest rate.
Syntax
PPMT (rate,per,nper,pv,fv,type) Rate – is the interest rate per period.
PER – specifies the period and must be in the range 1 to nper.
Nper– is the total number of payment periods in an annuity.
Pv– is the present value and the total amount that a series of future payments is worth now.
Fv– is the future value, or a cash balance you want to attain after the last
payment is made. If fv is omitted, it is assumed to be 0 (Zero), that is, the future value of a
loan is 0.
Type – is the number 0 or 1 and indicates when payments are due.
Set type equal to
O or omitted If payments are due at the end of the period 1 If payments are due at the
beginning of the period
Remark
Make sure that you are consistent about the units you use for specifying rate and nper. If you
make monthly payments on a four year loan at 12 percent annual interest, use 12%12 for rate
and 4*12 for nper. If you make annual payments on the same loan, use 12%12 for rate and 4
for nper.
Examples
The following formula returns the principal payment for the first month of a two-year
Rs.2,000 loan at 8 percent annual interest:
The following formula returns the principal payment for the last year of a 10-year Rs. 200,000
loan at 8 percent annual interest:
PPMT (16%, 10, 400000) equals –Rs. 71345.20
Value in RED Colour means this is payment. You can also change loan amount with negative
amount then this RED Colour figure will not come.
LOGICAL FUNCTION
AND
Returns TRUE if all its arguments are TRUE; returns FALSE if one or more arguments is
FALSE.

60
AND Condition is used where both the conditions must be true for example Student must
clear Xth and XIIth class for getting admission into Graduation.(Means student must have
passed Xth Class and XII th Class before getting admission into college)
Syntax
AND (logical1, logical2,…)
Logical1, logical2, … are 1 to 30 conditions you want to test that can be either TRUE or
FALSE.
1. The arguments must evaluate to logical values such as TRUE or FALSE, on the arguments
must be arrays or references that contain logical values.
2. If an array or reference argument contains text or empty cells, those values are ignored.
3. If the specified range contains no logical values, AND returns the #VALUE! Error value.
See example
Examples
AND (2+2=4, 2+3=5) equals TRUE
AND (TURE, TRUE) equals TRUE
AND (TRUE, FALSE) equals FALSE
If B1:B3 contains the values TRUE, FALSE, and TRUE, then:
AND (B1:B2) equals FALSE
If B4 contains a number between 1 and 100, then:
AND (1<B4, B4<100) equals TRUE
Suppose you want to display B4 if it contains a number strictly between 1 and 100, and you
want to display a message if it is not. If B4 contains 104 then:
IF (AND(1<B4, b4<100), b4, “The value is out of range.”) equals “The value is out of range.”
If B4 contains 50, then:
IF(AND(1<B4<B4<100), B4, “The value is out of range.”) equals 50
Example
Student must clear Xth and XIIth class for getting admission into Graduation.
(Means student must have passed Xth Class and XII th Class before getting admission into
college)
= IF(AND(B5 = ”PASSED”, C5 = ”PASSED”), ”ELEGIBLE OF ADMISSION IN
GRADUATION”,”NOTELEGIBLE FOR ADMISSION INTO GRADUATION”)
FALSE
Returns the logical value FALSE.
Syntax
FALSE ( )

61
Remark. You can also type the word FALSE directly onto the worksheet or into the formula,
and Microsoft Excel interprets it as the logical value FALSE.
IF
Returns one value if a condition you specify evaluates to TRUE and another value if it
evaluates to FALSE. Use IF to conduct conditional tests on values and formulas.
Syntax
IF (logical_test,value_if_ture,value_if,false)
Logical_test– is any value or expression that can be evaluated to TRUE or
FALSE
Value_if_true– is the value that is returned if logical_test is TRUE. If
logical_test is TRUE and value_if_true is omitted, TRUE is returned.
Value_if_true can be another formula.
385
Value_if_false– is the value that is returned if logical_test is FALSE. If
logical_test is FALSE and value_if_false is omitted, FALSE is returned.
Value_if_false can be another formula.
Examples
In the following Example, if the value in cell A10 is 100, then logical_test is
TRUE, and the total value for the range B5:B15 is calculated. Otherwise,
logical_test is FALSE, and empty text (“ “) is returned that blanks the cell that
contains the IF function.
IF(A10=100,SUM(B5:B15),””)
Suppose an expense worksheet contains in B2:B4 the following data for “Actual
Expenses” for January, February, and March: 1500, 500, 500. C2:C4 contains the following
data for “Predicted Expenses” for the same periods: 900, 925 You can write a formula to
check whether you are over budget for a particular month, generating text for a message with
the following formulas:
IF(B3>C2, “Over Budget”, “OK”) equals “Over Budget”
IF(B3>C3, “Over Budget”, “OK”) equals “OK”
Suppose you want to assign letter grades to numbers referenced by %age.
See the following table:
= IF(I3>90,”A”,IF(I3>80,”B”,IF(I3>70,”C”,IF(I3>60,”D”,IF(I3>50,”E”,”F”)))))
NOTE : “A” = These ” ” are used only in case of Character otherwise
there is no need of ” “in case of numeric results required for example
386
62
Basic is given but calculate DA,HRA,TA etc. you can check this in Part-B examples.
OR
Returns TRUE if any argument is TRUE; returns FALSE if all arguments are FALSE.
Syntax
OR (logical1,logical2,…)
Logical1,logical2,… are 1 to 30 conditions you want to test that can be either TRUE or
FALSE.
The arguments must evaluate to logical values such as TRUE or FALSE, or in array or
references that contain logical values.
If an array or reference argument contains text, numbers, or empty cells, those values are
ignored.
If the specified range contains no logical values, OR returns the #VALUE! error value.
You can use an OR array formula to see if a value occurs in an array. To enter an array
formula, press CTRL+SHIFT+ENTER in Microsoft Excel 97 for Windows.
Examples
OR(1+1=1,2+2=5) equal FALSE
If A1:A3 contains the values TRUE, FALSE, and TRUE, then:
OR(A1:A3) equals TRUE
TRUE
Returns the logical value TRUE.
Syntax
TRUE( )
Remark. You can enter the value TRUE directly into cells and formulas without using this
function. The TRUE function is provided primarily for compatibility with other spreadsheet
programs.
MATHEMATICAL FUNCTION
ABS
ABS returns the absolute value of a number. The absolute value of a number is the number
without its sign.
Syntax
Example :
ABS(number)
Put following numbers in the excel sheet you will get these results to understand the
concept of ABS function Number absolute number
=ABS(2%) Result will be
2% =.02
63
1/2 =0.5
2-4 =2
2*-4 =8
2/-5 =0.4
RAND
Returns an evenly distributed random number greater than or equal to 0 and less than 1. A
new random number is returned every time the worksheet is calculated.
Syntax
= RAND( )
If you want to find random numbers between 0 to 50 then try formula given:

= RAND()*50 (value will be generated between 0 to 50 only) = 88(


Remarks
If you want to generate a random real number between 50 to 100 then use the given below
formula.
=RAND( )*(b – a) + a
Here B will the maximum number b= 100 and a will the minimum number i.e. a= 50
If you want to use RAND to generate a random number but don’t want the numbers to change
every time the cell is calculated, you can enter = RAND( ) in the formula bar and then press
F9 to change the formula to a random number. B will the higher no
RANDBETWEEN
Returns a random number between the numbers you specify. A new random number is
returned every time the worksheet is calculated. If this function is not available, and returns
the #NAME? error, install and load the Analysis Tool Pak add-in. How?
On the Tools menu, click Add-Ins. In the Add-Ins available list, select the Analysis Tool Pak
box, and then click OK. If necessary, follow the instructions in the setup program.
Syntax
ROUND
ROUND(number,num_digits)
Number is the number you want to round.
Num_digitsspecifies the number of digits to which you want to round number.
• If num_digitsis greater than 0 (zero), then number is rounded to the specified number of
decimal places.
• If num_digitsis 0, then number is rounded to the nearest integer.
• If num_digitsis less than 0, then number is rounded to the left of the decimal point.
See Examples
64
Formulas for ROUND Function0
ROUND (2.15, 1) equal 2.2 ROUND(2.149, 1) equals 2.1
ROUND (-1.475, 2) equals -1.48 ROUND(21.5, -1) equals 20
ROUNDDOWN
Rounds a number down, toward zero.
Syntax
ROUNDDOWN(number,num_digits)
Number is any real number that you want rounded down.
Num_digitsis the number of digits to which you want to round number.
Remark
• ROUNDDOWN behaves like ROUND, except that it always rounds a
number down.
• If num_digitsis greater than 0 (zero), then number is rounded down to
the specified number of decimal places.
• If num_digitsis 0 or omitted, then number is rounded down to the nearest
integer.
• If num_digitsis less than 0, then number is rounded down to the left of
the decimal point.
Examples
ROUNDDOWN(3.2, 0) equals 3 ROUNDDOWN(76.9, 0) equals 76
ROUNDDOWN(3.14159, 3) equals 3.141
ROUNDDOWN(-3.14159, 1) equal -3.1
ROUNDDOWN(31415.92654, -2) equals 31,400
ROUNDUP
Rounds a number up, away from 0 (zero).
Syntax
ROUNDUP(number,num_digits)
Number is any real number that you want rounded up.
Num_digitsis the number of digits to which you want to round number.
Remark
• ROUNDDOWN behaves like ROUND, except that it always rounds a number up.
• If num_digitsis greater than 0 (zero), then number is rounded up to the specified number of
decimal places.
• If num_digitsis 0 or omitted, then number is rounded up to the nearest integer.
65
• If num_digitsis less than 0, then number is rounded up to the left of the decimal point.
Examples
ROUNDDOWN(3.2, 0) equals 4 ROUNDDOWN(76.9, 0) equals77
ROUNDDOWN(3.14159, 3) equals 3.142
ROUNDDOWN(-3.14159, 1) equal -3.2
ROUNDDOWN(31415.92654, -2) equals 31,500
SQRT
Returns a positive square root.
Syntax
SQRT (number)
Number is the number for which you want the square root.
= SQRT(16)
=4
Remark
If number is negative = SQRT(-16) Then, SQRT returns the #NUM! error value.
SUM
Adds all the numbers in a range of cells.
Syntax
SUM(number1,number2, …)
Number1,number2, .are 1 to 30 arguments for which you want the total value or sum..
Remarks
Numbers, logical values, and text representations of numbers that you type directly into the
list of arguments are counted. See the first and second examples following.
If an arguments is an array or reference, only numbers in that array or reference are counted.
Empty cells, logical values, text, or error values in the array or reference are ignored.

66
SUMIF
Adds the cells specified by a given criteria.
Syntax
SUMIF(criteria range, criteria,,sum_range)
Criteria_Rangeis the range of cells you want to evaluate the criteria
Criteria is the criteria in the form of a number, expression, or text that defines which cells
will be added. For Example Commission of two flats which are greater than 200000 lacs. Is
49000
Sum_rangeare the actual cells to sum i.e. to pick values from this range.
The cells in sum_range are summed only if their corresponding cells in range match the
criteria. If sum_range is omitted, the cells in criteria_range are summed.
Example
Suppose A1:A4 contain the following property values for four homes :
Rs. 100,000, Rs. 200,000, Rs. 300,000, Rs. 400,000, respectively. B1:B4 contain
the following sales commissions on each of the corresponding property values:
Rs. 7,000, Rs. 14,000, Rs. 21,000, Rs. 28,000.
SUMIF(A1:A4,
“>200000”,B1:B4)
equals Rs. 49,000
SUMSQReturns the sum ofthe squares of thearguments.
Syntax
SUMSQ (number 1, number 2 …)
Number1, number2, … are 1 to 30 arguments
for which you want the sum of the squares. You can also use a single array or a reference to
an array instead of arguments separated by commas.
Example
SUMSQ (3, 4) equals 25
67
STATISTICAL FUNCTION

AVEDEV
Returns the average of the absolute deviations of data points from their mean. AVEDEV is a
measure of the variability in a data set.
Syntax
AVEDEV(number 1, number 2, …)
Number 1, number 2, … are 1 to 30 arguments for which you want the average of the
absolute deviations. You can also use a single array or a reference to an array instead of
arguments separated by commas
Remarks
• The arguments must be either numbers or names, arrays, or references that contain numbers.
• If an array or reference argument contains text, logical values, or empty cells, those values
are ignored; however, cells with the value zero are included.
AVEDEV is influenced by the unit of measurement in the input data.5
Example
AVEDEV(4, 5, 6, 7, 5, 4, 3) equals 1.020408
AVERAGE
Returns the average (arithmetic mean) of the arguments.
Syntax
AVERAGE(NUMBER1,NUMBER2,…)
Number 1, number 2, … are 1 to 30 numeric arguments for which you want the average.
Remarks. The arguments must either be numbers or be names, arrays, or references that
contain numbers. If an array or reference argument contains text, logical values, or empty
cells, those values are ignored; however, cells with the value zero are included.
TIP :When averaging cells, keep in mind the difference between empty cells and those
containing the value zero, especially if you have cleared the Zero values check box on the
View tab (Options command, Tools menu). Empty cells are not counted, but zero values are.
CORREL
Returns the correlation coefficient of the array1 and array2 cell ranges. Use the correlation
coefficient to determine the relationship between two properties.396
For Example, you can examine the relationship between a location’s average temperature and
the use of air conditioners.
Syntax
CORREL(array1,array2)
Array 1 is a cell range of values.
Array 2 is a second cell range of values.
68
Example
CORREL ({3,2,4,5,6},{9,7,12,15,17}) equals 0.997054
FRQUENCY
Calculates how often values occur within a range of values, and then returns a vertical array
of numbers. For Example, use FRQUENCY to count the number of test scores that fall within
ranges of scores. Because FRQUENCY to return an array, it must be entered as an array
formula.
Syntax
FRQUENCY(data_array,ins_array)
Data_arrayis a set of values for which you want to count frequencies. If data_array contains
no values, FRQUENCY returns an array or zeros.
Bins_arrayis an array (Set) of or reference to intervals into which you want to group the
values in data_array. If bins_array contains no values, FRQUENCY returns the number of
elements in data_array.
Remarks
• FRQUENCY is entered as an array formula after you select a range of adjacent cells into
which you want the returned distribution to appear.
• The number of elements in the returned array is one more than the number of elements in
bins_array
• FRQUENCY ignores blank cells and text.
• Formulas that return arrays must be entered as array formulas. To get the output in an array,
press CTRL+SHIFT+ENTER instead of enteronly.
Example
FRQUENCY(A2:E6,B9:B13) equals {7;3;4;6;5}
INTERCEPT
Calculates the point at which a line will Intersect the y-axis by using existing x-values and y-
values. The intercept point is based on a best-fit regression line plotted through the known x-
values and known y-values. Use the intercept when you want to determine the value of the
dependent variable when the independent variable is 0 (zero). For Example, you can use the
INTERCEPT function to predict a metal’s electrical resistance at 0ºC when your data points
were taken at room temperature and higher.
Syntax
INTERCEPT(known_y’s,known_x’s)
Known_y’sis the dependent set of observations or data.
Knows_x’sis the Independent set of observations or data.
Remarks
• The arguments should be either numbers or names, arrays, or references that contain
numbers.

69
• If an array or reference argument contains text, logical values, or empty cells, those values
are Ignored; however, cells with the value zero are included.
• If known_y’s and known_x’s contain a different number of data points or contain no data
points, INTERCEPT returns the #N/A error value.
Example
INTERCEPT({2, 3, 9, 1, 0,}, {6, 5, 11, 7, 5}) equals 0.0483871
MAX
Returns the largest value in a set of values.
Syntax
MAX(number1,number2,…)
Number1, number2, … are 1 to 30 numbers for which you want to find the maximum value.
Remarks
You can specify arguments that are numbers, empty cells, logical values, or text
representations of numbers. Arguments that are error values or text that cannot be translated
into numbers cause errors.
If an argument is an array or reference, only numbers in that array or reference are used.
Empty cells, logical values, or text in the array or reference are ignored. If logical values and
text must not be ignored, use MAX instead.
If the arguments contain no numbers, MAX returns 0 (zero).
MIN
Return the smallest number in a set of values.
Syntax
MIN(number1,number2,…)
Number1, number2, … are 1 to 30 numbers for which you want to find the minimum value.
Remarks
You can specify arguments that are numbers, empty cells, logical values, or text
representations of numbers. Arguments that are error values or text that cannot be translated
into numbers cause errors.
If an argument is an array or reference, only numbers in that array or reference are used.
Empty cells, logical values, or text in the array or reference are ignored. If logical values and
text should not be ignored, use MINA instead.
If the arguments contain no numbers, MIN returns 0.
MODE
Returns the most frequently occurring, or repetitive, value in an array or range of data. Like
MEDIAN, MODE is a location measure.
Syntax
MODE(number1,number2,…)
70
Number1, number2, … are 1 to 30 arguments for which you want to calculate the mode.
You can also use a single array or a reference to an array instead of arguments separated by
commas.
Remarks
• The arguments should be numbers, names, arrays, or references that contain numbers.
• If an array or reference argument contains text, logical values, or empty cells, those values
are ignored; however, cells with the value zero are included.
• If the data set contains no duplicate data points, MODE returns the #N/Aerror value.
SLOPE
Returns the slope of the linear regression line through data points in known_y’s and
known_x’s. The slope is the vertical distance divided by the horizontal distance between any
two points on the line, which is the rate of change along the regression line.
Syntax
SLOPE (known_y’s,known_x’s)
Known_y’sis an array or cell range of numeric dependent data points.
Known_x’sis the set of independent data points.
Remarks
• The arguments must be either numbers or names, arrays, or references that contain numbers.
• If an array or reference argument contains text, logical values, or empty cells, those values
are ignored; however, cells with the value zero are included.
• If known_y’s and known_x’s are empty or have a different number of datapoints, SLOPE
returns the #N/A error value.
400
Example
SLOPE({2,3,9,1,8,7,5},{6,5,11,7,5,4,4,}) equals 0.3.5556

=STDEV
STDEV(number1,number2,...)
Number1, number2, ... are 1 to 30 number arguments corresponding to a sample of a
population. You can also use a single array or a reference to an array instead of arguments
separated by commas.
Remarks
STDEV assumes that its arguments are a sample of the population. If your data represents the
entire population, then compute the standard deviation using
STDEVP.
The standard deviation is calculated using the “n-1” method. Arguments can either be
numbers or names, arrays, or references that contain numbers. Logical values and text
71
representations of numbers that you type directly into the list of arguments are counted. If an
argument is an array or reference, only numbers in that array or reference are counted. Empty
cells, logical values, text, or error values in the array or reference are ignored.
Arguments that are error values or text that cannot be translated into numbers cause errors. If
you want to include logical values and text representations of numbers in a reference as part
of the calculation, use the
STDEVA function.
STDEV uses the following formula:

AVERAGE FUNCTION

72
where ON B8is the sample mean AVERAGE(number1,number2,…) and n is the
sample size.
Example
Suppose 10 tools stamped from the same machine during a production run are collected as a
random sample and measured for breaking strength. The example may be easier to understand
if you copy it to a blank worksheet.
EXERCISE PRACTICAL QUESTIONS
Check your progress
Exercise 1: Practical Questions
1. How can you generate random numbers between 100 and 200? Explain?
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
2. Explain Round function. How it is different from round down and roundup functions.
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
3. Explain AND, IF and OR function with suitable example.
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________

4. Explain the difference between count, count a, count blank functions.


______________________________________________________________________
______________________________________________________________________
______________________________________________________________________

73
______________________________________________________________________

5. Explain slope and intercept functions. How they can be used in regression equations?
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
6. Explain PMT function. How can it be used in loan and lease statement.
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________

7. Explain the difference between AND and OR functions. What are their applications?
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________

8. What is SUMIF Function? Where we can use this function explain with the help of
suitable example.
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
Exercise 2: Short Question Answers
1. Differentiate Sort and Filter Command. (DU,SOL,2010)
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________

2. Difference between PMT, PPMT and IPMT Functions


______________________________________________________________________
______________________________________________________________________

74
______________________________________________________________________
______________________________________________________________________

3. Explain the structure of Function with suitable example.


______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________

4. Explain any three Logical Functions with suitable examples.


______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________

5. Explain any three Statistical Functions with suitable examples.


______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________

6. Explain any four Mathematical functions with examples


______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________

7. Explain any three financial functions with examples


______________________________________________________________________
______________________________________________________________________
______________________________________________________________________

75
Exercise for practice
Exercise 1
Short Questions
Q.1. What is word wrap command how this command is used in MS Excel. Explain with the
help of suitable example?
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
Q2. What is Align and Centre command? What is the purpose of using this command give
example?
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
Q.3. What is a chart? List out some of the different charts available in MSExcel. 369
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
Q.4. What do you mean by cell reference in MS Excel? What are the different types of
references?
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
Q.5. Why is formatting of spreadsheets required?
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
Q.6. What do you mean by circular reference in MS Excel?
______________________________________________________________________
______________________________________________________________________

76
______________________________________________________________________
______________________________________________________________________

Q.7. What are Header and Footer Selections? Explain in detail.


______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
Q8. How to resize the cell (column width and Row width) using commands?
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
Exercise for practice
Exercise 2
Long questions
1. What are the features of MS Excel ?
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
2. What are common errors of MS Excel?
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
3. How Header and Footer can be inserted?
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
4. Differentiate between Workbook and Worksheet
______________________________________________________________________

77
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________

5. Write the cell address of the following cells:


(a) 14th row and 2nd column
(b) 10th row and 1st column
(c) 150th row and 52nd column
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
6. What do you understand by cell referencing, including absolute and Relative cell
referencing?
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
7. What is the default alignment of numbers and text in Excel?
(SOL,DU,2010)
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
8. What is Excel Screen? State the items in Excel Screen.
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
9. What does Auto Fill means? Explain.
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
78
10. What are header and footer selections? Explain in detail.
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________

11. What is meant by range of columns? Explain its use.


______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
12. Explain the method for building a worksheet.
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
13. What does editing of cells mean? Explain.
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
14. What is Watermark? How this can be used in printing of Fee receipt, Marksheet of
SOL? Explain.
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________
______________________________________________________________________

79
CREATING BUSINESS SPREADSHEET
Loan and Lease Statement
Ratio Analysis
Graphical Representation of Data
Payroll Statement
Frequency Distribution and its statistical parameters
Correlation and Regression

LOAN AND LEASE STATEMENT


When an amount is borrowed or Loan taken against some assets such a transaction will
require a settlement about the time during which the amount will be paid, the periodicity of
payment like monthly, quarterly, half yearly or yearly), and rate of interest to be paid.
Instalments payment may keeping these in mind an Equated Periodic Payment Installment is
calculated using PMT function in Excel and a statement is prepared for a complete period of
loan remains unpaid. This statement is called Loan and Lease Statement.
The problem of preparing loan & lease statement will be studied in three stages:
Stage one: where statement is for annual payment and for fixed number of years
Stage two: where statement is for one or more payments in a year and for fixed number of
years.
Stage three: None of the parameters are fixed A totally genera l ize d worsheet.
Preparing loan &
Lease Statement in three Stages are Various columns can be used for the calculation of the
instalment
1.Instalment number.
This column refers to the installment number for which the calculations are being made in a
particular row.
2. Opening Balance.
The outstanding loan amount in beginning of a period. This amount is normally the closing
balance for the last period. For the first installment the opening balance will be the original
loan amount.
3. Interest due.
Interest from the data of last the installment payment to the data of current installment
payment. This can be directly calculated by using IPMT function in excel.
4. Equated Periodic Installment.
Periodic Payment Installment is calculated keeping in view the frequency or periodicity of
payment (monthly, half yearly, quarterly, or yearly), and rate of interest to be paid and the

80
time during which it is paid. This should cover the loan outstanding, as well as the interest on
the outstanding amount, in a manner that all the installments are equal. PMT function in
Excel is used for this purpose.
5. Closing Balance.
It is obtained by adding interest due in opening balance and deducting the installment paid.
This will automatically become the opening balance for the next period.
6. Principal Component in Equated Periodic Installment.
This is found by deducting the interest due for that particular period (row) from the Equated
Periodic Installment. It can also be directly calculated by using PPMT function in Excel.
Basic Inputs for Loan & Lease
1. Amount of Loan
2. Rate of Interest
3. Time of Loan (Period)
4. Periodicity
Question: Rs. 2,40,000/- borrowed at 24% p.a. rate of interest to be repaid in
24 instalments (Yearly) in 24 years.
Solution: The figure below gives the appearance of final work sheet. The figure below
displays the formula and functions used in the work sheet.

408
Fig.
81
Formula display of in figure shown below

Fig. Formula display of figure below

Formula display below.

82
. b Formula display of figurebelow .

Cell numbers C2, C3, C4 contains the information given in the question. Installment amount
in C5 has been calculated using PMT function. Look for all the formula in figure in the
corresponding cell. Since 24 installments are to paid, cells from A7 to A30 is filled with
Installment (Year wise) 1 to 30. For payment number 1, the Opening Balance is normally the
loan amount. Therefore a formula is entered in cell B7 (=C2). In C7, interest is calculated on
the opening balance given in cell B7 (=B7*$C$3). $ Sign before C and 3 refers to absolute
referencing, which is done to avoid the change during copy operation. The same way the D7
is filled with the installment calculated using PMT function. This same way the D7 is filled
with (=$C$5), this too you do not want to change during copy operation, therefore, you put $
sign before C and Before 5. Closing balance is naturally Opening Balance, plus interest,
minus installment. Therefore in cell E8 we enter (=B7+C7-D7). This completes the first row.
In the second row, the opening balance the closing balance of previous period. ThusB8 will be
replaced with =E7. This completes the formula entering. Copy from cell B8 to B9…B30, Cell
C7 to C8..C30, cell to D8..D30 and Cell E7 to E8..E30. do it in your practical
Stage Second
At stage two, one more dimension is added. That is periodicity, meaning one or more than one
installments paid in a year. This too is a generalized worksheet except for total number of
installments paid/due during the loan period.
Question: Loan amount is Rs.60000/- borrowed at 12% p.a. rate of interest to be repaid in 12
equal Half yearly installment i.e. loan period is 6 years and two installments are paid in a
year.
In Cell numbers E5 ..F8, we displays the various option of installments mode are available,
with their respective codes. Code 1 stands for yearly payments, Code 2 stands for Half yearly
payments, Code 3 stands for monthly payments, Code 4 stands for quarterly payment. In cell
E4 we write the option selected, which is 2 in this particular question.
Now we add two more rows for information to be calculated from the provided information
i.e. Effective rate and Total installments.
Effective rate is obtained by dividing rate of interest per annum with 1 for yearly, with 2 for
half yearly, with 4 for quarterly and with 12 for monthly. The same way total installments is

83
obtained by multiplying years period with 1 for yearly, with 2 for half yearly, with 4 for
quarterly and with 12 for monthly.
Now installment amount will be calculated by using effective rate and total
installment. Also every place where we use rate of interest we will use effective rate of
interest, and for period total number of instalments. Do it in practical’s
STAGE 3 (stage2 with garbage cleaning):
If may be noted, that at stage 1and 2 the worksheet is a generalized, except for the change in
period. We try to change the period from 6 to 4 in the worksheet at stage 2, keeping the
payments at half yearly intervals. Thus the total payments will be equal to 4 × 2 = 8. The
resultant worksheet. You will note that at installment number 8, the closing balance is zero.
The worksheet should have ended at this point. But it continued with irrelevant information,
for installment numbers 9, 10, 11 & 12. The information in cell number A 18 .. E 21 is
referred as garbage. At stage 3 we will improve the worksheet in which such garbage does not
appear, and the worksheet is truly generalized for all changes in the information provided.
Figure number 10 shows a worksheet which takes care of garbage.
STAGE 3 worksheet with Formula.
The problem of garbage was encountered, because at no place in the sheet, we have instructed
to stop. In a loan repayment, at least one installment will be paid. But more than one is not a
certainty. On this assumption, on comparing We check the value in cell A10 with the value in
cell B8 (indicating total installments) and if the value in A10 is less that B8 (total
installments), meaning by, that we have to continue and we fill the cell A11 with a value one
larger than the value in A10 by entering the following formula in cell A11:
=IF(A 10 <B8,a10+1,” “)
and we copy this formula from cell A11, to cells A12 to A250 (assuming that in a transaction
there can be maximum of 240 installments) Now cells B11, C11, D11, and E11 will be
dependent on the fact, whether A11 is blank or it contains any value. If A11 is blank, then
B11, C11, D11, and E11 will also be blank otherwise they will contain the same value as
calculated in above. Thus the following formula will be entered in B11, C11, D11, and E11
respectively:
= IF(A11 = “” “”,E10)
= IF(A11 = “” “”,B11*$B$7)
= IF(A11 = “” “”,$B$6)
= IF(A11 = “” “”,B11+C11 – D11)
All these cells will be copied up to row number 250.
You will notice that later part of formula is the same as given in figure. This completes the
preparation of a generalized loan and lease statement. Do this in practical.
RATIO ANALYSIS
In a financial statement, absolute figures, always, do not convey meaningful information.
Ratio analysis is a technique under which relationship between figures of the financial

84
statement is expressed as a ratio. For example a statement that profit of the company is
Rs.30000/- may be correct, but does not give the picture of profitability of the company. If we
state, that profits are 30% of sales, definitely it conveys that is the profitable one. There may
be various ratios for various purposed. We will cover only two of the Financial Ratios like:
See figures below:
1. Current Ratio
2. Liquidity Ratio

Fig.

412
Figure

85
Figure
PAYROLL ACCOUNTING
Question: Prepare a generalized worksheet to produce a payroll statement
in the format given below:
Emp. Name, Basic, Performance Dearness, House Rent, Provident Income, Gross,
No Pay Grade, Allowance, Fund, Tax Pay, Net Salary
Employee is entitled Basic Pay, Dearness Allowance (DA), House Rent Allowance (HRA). A
Gross salary is the total of these three. Out of Gross Salary employee contributes 10% of
Basic pay + DA towards PF and pays 25% of Gross Salary as Income tax. Net Salary is found
after deducting PF and ITAX from the Gross Salary. DA is calculated 150% of Basic Pay for
those having basic up to Rs.16,000 and 100% for those having more than Rs. 16,000 with a
condition that a person having basic more than Rs. 16,000 get a minimum DA of Rs. 24,000.
HRA for employee of Performance Grade ‘A’ is Rs. 1,600, for B is Rs. 1,200 and for C
Rs.1,000.

86
415
Solution :A worksheet incorporating the above information is shown infigure 1.

Figure
In Cells E2 formula to calculate DA is shown in figure

Figure

87
In Cells F2 formula to calculate HRA is shown in figure

Figure
In Cells G2 formula to calculate Gross Salary is shown in figure

Figure
In Cells H2 formula to calculate DA is shown in figure

Figure with formula


In Cells I2 formula to calculate Income Tax is shown in figure

88
Figure with formula
In Cells J2 formula to calculate Income Tax is shown in figure
GRAPHICAL REPRESENTATION OF DATA
Four different types of charts are shown in figure below. These chart types are:
1. Clustered Column with 3-d effect.

Figure

2. Exploded Pie
3. Clustered column
4. Pie

89
Figure
We will create chart using the following steps:
1. Select the data range to be used for chart.
2. Click the chart button on the tool bar.
3. A dialog box will open showing the types of charts/graphs available. We will select any one
type.
4. On hand side of dialog box, there will be may sub options. Click on the desired sub option.
5. Finally click on finish option. The chart is ready.
6. If you want to format the chart, instead clicking on FINISH, click on NEXT. A new dialog
box asking for following will open.
(a) Title
(b) Axes
(c) Gridlines
(d) Legend
(e) Data Labels
(f) Data Tables
Give the requisite information and then click to complete the graph.
FREQUENCY DISTRIBUTION AND ITS STATISTICAL PARAMETERS
Frequency Distribution and its statistical parameters. Frequency distribution is a table in
which number of times (called frequency), values for a variable occur within a range of values
(known as class). The data tabulated in a frequency distribution is called grouped data.
Question: In cells A3 …J12(100 cells) enter positive numbers randomly as values of certain
observation. Group this data into 10 classes. Calculate:
(i) Mean from individual observation
90
(ii) Standard Deviation from individual observation.
(iii) Smallest observed value.
(iv) Largest observed value.
(v) Frequencies.
(vi) Mean from grouped data.
(vii) Standard Deviation from grouped data.
Solution: below Figure shows the final worksheet for the above problem.
Cell A1…J12 show title of worksheet and observations. In cells A3…J12 (100cells)
observation values are entered.

17

91
(i) In cell J13, mean from individual observation is calculated using function
Average. Formula entered in cell J13, is =AVERAGE(A3:J12),returned
answer is 20.97023

(ii) In cell H13, standard deviation from individual observation is calculatedusing function
STDEV. Formula entered in cell H13, is =STDEV(A3:J12),which returned answer as
20.97023.

92
93
(iii) In cell f13 largest observed value is found using formula:

(iv) =MAX(A3:J12)

(v) Frequencies: To find the frequencies, first we have to group the data. For grouping, class
interval, is the first thing is to be decided. The class interval are calculated by dividing the
difference in the largest and smallest value by number of classes desired.
Approximate interval= (largest value-Smallest value)/ no of classes
In our question since we desire to have 10 classes:

94
Approximate interval = (99 – 1) / 10 = 9.8

418
Thus we decide our group interval as 10 starting with 1 out groups are entered in cells
A15…B24 (column ‘A’ having the lower limits and column ‘B’ having the upper limits). We
reserve the cells C15…C24 to show corresponding frequencies.
HOW TO CALCULATE FREQUENCY
Frequency function is used to calculate, the number of time, the values are falling with in a
particular group. Frequency returns a vertical array, as an answer, as a answer, therefore
must be entered as an array formula. We have already reserved cells C15…C24 to show
the output (frequencies).

95
Steps in entering the Formula
1. Select the cells C15…C24. You will find cells C16..C24 have changed color and C15
remains white (at this stage, till the frequencies appear in cell C15..C4, please do not tough
mouse or change the current cell in any manner).
2. Enter formula. When you enter formula, it will show in cell C15, but is
valid for the full array of cells i.e. C15 ..C24. Formula requires the reference to cells
containing data (referred as data array) and also the range containing the upper limits (referred
as bins array). The following formula will be entered:
=FREQUENCY(A3:J12, B15:B24)
3. Press CTRL+SHIFT+ENTER. You have to strike on ENTER keeping the SHIFT and
CTRL keys pressed. Please note that Enter key will be the last in the above sequence.
Mean from grouped data. For calculating mean we require the total of
the product of mid values of the group with frequencies.
Steps:
1. To find the mid values of group, in cells D15, we enter formula as :
= (A15+B15)/2
Which is copied to cells A16 ..A24.
2. To find the product of mid values with frequency, in cells E15, we enter
formula as :
= (D15*C15)
which copied to cells E16..E24
419
3. To find total observations, we sum up the cells C15..C24, in cell C25weEnter formula:=
sum(C15:C24)
4. To find sum of product of frequency and mid-value we enter, in cell E25the following
formula:
= sum (E15:E24)
5. To find the MEAN in cell I18 we enter formula as:
= E25/C25
6. Standard Deviation from grouped data. For calculating S.D. we require, additionally, sum
of product of frequency with square of mid values. In cell number C15, we enter the formula
as given below to find the product of frequency with square of mid values:
= C15*D15*D15
This is copied to cell F16….F24. In cell F25 we have obtained the sum ofF15..F24 with the
formula =sum(F15:F24). S.D. is obtained by entering following formula In cell 117:

96
=SQRT((F25/C25)-(E25/C25)^2)
CORRELATION AND REGRESSION ANALYSIS
Linear Regression Analysis (use of intercept and slops): Regression analysis helps in
estimating a dependent variable, the value of which is associated with other variable known as
independent variable. For fitting a regression line, the method of lease square criterion is
followed. The linear equation that represents the simple linear regression model is:
Y=a + bx
Where ‘y’ is the value of dependent variable, ‘a’ represent the value of ‘y’ when ‘x’ is zero. In
other words, it is constant and in EXCEL is calculated by INTERCEPT function. ‘b’ represent
the angle of regression line and in EXCEL is calculated by slope function. It is also called
regression coefficient.
QUESTION
Given data for 10 recent shipment made by the company. A record of distance in miles and
time taken was made. Draw a regression line after finding the estimated time of delivery, from
the given information:

420
Fig A
The worksheet given in figure A, B and C shows original data (for distance in miles) in cells
A11…A20, and data for delivery time in cells B11…B20. In cell E8 intercept is calculated
using the formula in cell C18
=INTERCEPT(B7:B16,A7:A16).

97
Fig B
Likewise in cell slope is calculated using the formula in cell
C19 (=SLOPE(B7:B16,A7:A16)). With the help of calculated intercept and slope, we have
estimated the value of ‘y’ for all values of ‘x’,

98
Fig C
by putting in cell C7 the formula =$C$18+$C$19*A7, then copying it to cells C7…C16.
Exercise 1: Practice questions
1. Rs. 4,80,000/- borrowed at 12% p.a. rate of interest to be repaid in 48 instalments
(Yearly) in 48 years.
2. Employee is entitled Basic Pay, Dearness Allowance (DA), House Rent Allowance
(HRA). A Gross salary is the total of these three. Out of Gross Salary employee
contributes 20% of Basic pay + DA towards PF and pays 25% of Gross Salary as
Income tax. Net Salary is found after deducting PF and ITAX from the Gross Salary.
DA is calculated 150% of Basic Pay for those having basic up to Rs.16,000 and 100%
for those having more than Rs. 16,000 with a condition that a person having basic
more than Rs. 16,000 get a minimum DA of Rs. 42,000. HRA for employee of
Performance Grade ‘A’ is Rs. 10,600, for B is Rs. 10,200 and for C Rs.10,000.
3. Enter positive numbers randomly as values of certain observation from 0 to 100 and
frequency between 0-10, 11-20, 21-30, 31-40, 41-50, 51-60, 61-70, 71-80, 81-90, 91-
100. Group this data into 10 classes.

99
UNIT-V
DATABASE MANAGEMENT SYSTEM - I

 Database Designs for Accounting and Business Applications: Reality- Expressing the
Application;
 Creating Initial design in Entity Relationship (ER) Model; Transforming ER Model to
Relational data model concepts;
 Implementing RDM design using an appropriate DBMS.
 Summary
 Exercise

Database Designs for Accounting and Business Applications: Reality-


Expressing the Application;
In today’s business environment, information plays a vital role. Right information at right
time to the right person leads to success in business. The present era is, thus, known as the
information era or knowledge era. It is an integral part of everyday life. Information is
obtained from the data. The data when processed is called information (see fig 1.1.)

Fig. 1.1: Use of Database Management System (DBMS) Software

The mechanism/technology or system used to store, process and retrieve the data and
information is called a database (DB) and the tool that is used to develop a database is called
database management system (DBMS) software which allows storing the data in a logical
way. Management of data is not simple as the data which needs to be stored possesses
different characteristics. While developing the database, one has to consider the characteristics
of data which will be made available through the database. Following are the characteristics
of data which makes it complex in nature and difficult to manage:

100
1. Aggregation: Data can be aggregated. Aggregation is nothing but cumulating or adding
up. For example, weekly sales data can be aggregated to monthly data and monthly data
are added up to form a consolidated annual.
2. Data Base Management System: Accumulation. Cumulative percentage is always worked
out on data presented as a variable in tabular form. In business, aggregation is of great
importance. For instance, sales figure — daily, weekly, quarterly, half-yearly, annual,
region-wise, state-wise, sales agent-wise, product type-wise etc.
3. Compression: Data is compressible in nature. Large amounts of data are compressed to
make them more meaningful. Compressed data is manageable and can be grasped quickly.
There exist a number of techniques to compress data to a manageable size. Graphs and
charts are some examples of compressed data.
3. Refinement: Data requires processing or refinement. When refined, they are capable of
leading to conclusion or even generalisation. This refinement can then discover new facts.
4. Size of data: Size of the data involves the coverage of the subject understudy, data
elements and data population covering documents, data banks and field survey methods
(questionnaire, interview, observations etc.). The data usually collected for market survey
will be huge, especially the one collected by market research agencies. In science, what
already exists is in the form of data.
With the above characteristics of data, the database should ensure that data is being
utilised for planning and decision-making.
Data: Considering the above characteristics, data can be defined as stored representations of
objects and events that have meaning and importance in the user’s environment. The data can
be of different types. For example, in a hospital, the medical record department can have the
patient’s number with his/her photograph scanned along with x-ray documents as an image in
describing his/ her medical history. The terms data and information are closely related, but in
fact, they are not the same. When we process data to achieve meaningful results with help of
systems (which includes software and computers), it becomes information. We define
information (Processed Data) as data that have been processed in such a way that the
knowledge of the person who uses the data is increased. For example, consider the following
list of facts: (See Table 1.1)
Sodhi, Amit 6124917624
Verma, Anjali 6276193244
Sambher, Mohak 6348429343
Sodhi, Aarav 6351742184
Sambher, Asha 6309723145
Pandey, Preeti 6492416585
Shanker, Hari 6592416584
Table 1.1.: data table
Database: Database is a collection of related data. The database can be of any size and can
vary from simple to complex depending upon the type of data the database deals with. A list
101
of students can also be called a database. Alibrary catalogue is also a database as it gives the
details of the books available in the library. The library catalogue may be small, simple and
large and complex. Database can be generated manually or computerised. The computerised
database is called computer based database.
Database Management System (DBMS): The system or programme or application that
enables to create, store and retrieve computerised data base is called database management
system. Hence, DBMS is a collection of programs that enables the user or database developer
to create a database, maintain a database and provide controlled access to user database.
DBMS, is, thus, the general purpose software that facilitates the process of defining,
construction, manipulating database for various applications. It enables end users and
application programmers to share data, and it enables data to be shared among multiple
applications rather than propagated and stored in new files for every new application. MS-
Access is one of the popular DBMS known, that facilitates designing and maintaining a
database of any size.
Defining a database involves specifying the data types, structures and constraints for the data
to be stored in a database. Constructing the database is the process of storing the data itself on
storage medium that is controlled by the DBMS. Manipulating the database includes functions
like querying the database to retrieve the data, updating the data, modifying the data,
generation of report based on the query etc.
Before we learn more about database, database management systems, creation and
construction of database etc., it would be better to understand the reasons for the development
of database technology.

Evolution of Database Technology: File System to Database


Technology
In the initial days, when there were no computers available, the organisations still used to
manage the data. All the organisational data were stored, and maintained in papers and files.
When computer-based data processing was first available, there were no databases. Gradually,
computers were introduced into the business world. To be useful for business applications,
computers must be able to store, manipulate and retrieve large files of data. Computer file
processing systems were developed for this purpose. Still, the file systems are used in some
places for backing up database systems. Understanding the problems and limitations inherent
in file processing systems can help us avoid these problems while designing database systems.

Creating Initial design in Entity Relationship (ER) Model; Transforming


ER Model to Relational data model concepts;
Entity Relationship (ER) Model
We will discuss in detail about the data modelling, defining entities, attributes and entity
relationship diagram and various constraints that are considered while deriving the entity

102
relationship diagram. The entity relationship diagram documents the business rules and
constraints. The business rules and policies govern the data processing and management in an
organisation. For example, a policy that “every student in the university must have a faculty
adviser” forces data (in a database) about each student to be associated with data about some
student adviser. Another example could be, “a student will not be eligible for the second
semester, unless he/she clears 16 credits in the first semester”. However, business rules and
policies are not universal; different universities may have different policies for student
advising and may include different types of people as students. Also, the rules and policies of
an organisation may change (usually slowly) over time; a university may decide that a student
has to complete minimum 20 credits in order to qualify for the next semester. The objective of
a database analyst is to:
• Identify and understand those rules that govern data
• Represent those rules so that they can be unambiguously understood by information
systems developers and users implement those rules in database technology
Understanding the business rules enable to develop effective data model.
What is Entity?
An entity can be a real-world object, either animate or inanimate, that can be easily
identifiable. For example, in a school database, students, teachers, classes, and courses offered
can be considered as entities. All these entities have some attributes or properties that give
them their identity. (See Fig. 2.1).

Fig 2.1: Shows Entities

Entity Types
The Entiy Relationship (ER) model consists of different types of entities. The existence of an
entity may depends on the existence of one or more other entities, such an entity is said to be
existence dependent. Entities whose existence not depending on any other entities is termed as
not existence dependent. Entities based on their characteristics are classified as follows:
• Strong Entities
• Weak Entities
• Recursive Entities
• Composite Entities

103
Strong Entity Vs Weak Entity

Fig 2.2 Shows Strong Entity Set


An entity set that has a primary key is termed as strong entity set. An entity set that does not
have sufficient attributes to form a primary key is termed as a weak entity set. A weak entity
is existence dependent. That is the existence of a weak entity depends on the existence of an
identifying entity set.
The discriminator (or partial key) is used to identify other attributes of a weak entity set. The
primary key of a weak entity set is formed by primary key of identifying entity set and the
discriminator of weak entity set. The existence of a weak entity is indicated by a double
rectangle in the ER diagram. We underline the discriminator of a weak entity set with a
dashed line in the ER diagram. (See fig. 2.3).

Fig 2.3 Shows Weak Entity Set


Recursive Entity
A recursive entity is one in which a relation can exist between occurrences of the same entity
set. This occurs in a unary relationship.

104
Composite Entities
If a many to many relationships exist, we must create a bridge entity to convert to many.
Bridge entity is composed of the primary keys of each of the entities to be connected. The
bridge entity is known as a composite entity. A composite entity is represented by a diamond
shape with in a rectangle in anER Diagram. Entity set is a collection or set of all entities of a
particular entity type at any point of time. Take an example:
A company has many employees, and these employees are defined as entities (e1, e2, e3.......)
and all these entities having same attributes are defined under ENTITY TYPE employee and
set (e1, e, ...........) is called entity set. Entity type is like a fruit which is a class. We haven’t
seen any “fruit” yet though we have seen instance of fruit like apple, banana, mango etc.
hence.
fruit=entity
type=EMPLOYEE
apple=entity= e1 or e2 or e3
enity set= bucket of apple, banana, mango etc={e1,e2......}

ENTITY SET
An entity set is a collection of similar types of entities. An entity set may contain entities with
attribute sharing similar values. For example, a Students set may contain all the students of a
school; likewise a Teachers set may contain all the teachers of a school from all faculties.
Entity sets need not be disjoint.

ENTITY-SET AND KEYS


Key is an attribute or collection of attributes that uniquely identifies anentity among entity set.
For example, the roll_number of a student makes him/her identifiable among students.
• Super Key :A set of attributes (one or more) that collectively identifies an entity in an
entity set.
• Candidate Key :A minimal super key is called a candidate key. An entity set may have
more than one candidate key.
• Primary Key :A primary key is one of the candidate keys chosen by the database
designer to uniquely identify the entity set.

ATTRIBUTES
The entities are represented by means of their properties, called attributes. All attributes have
values. For example, a student entity may have name, class, and age as attributes. There exists
a domain or range of values that can be assigned to attributes. For example, a student’s name
cannot be a numeric value. It has to be alphabetic. A student’s age cannot be negative, etc.

105
Types of Attributes
 Simple attribute — Simple attributes are atomic values, which cannot be divided
further. For example, a student’s phone number is an atomic value of 10 digits.
 Composite attribute — Composite attributes are made of more than one simple
attribute. For example, a student’s complete name may have first_name and last_name.
 Derived attribute — Derived attributes are the attributes that do not exist in the physical
database, but their values are derived from other attributes present in the database. For
example, average_salary in a department should not be saved directly in the database,
instead it can be derived. For another example, age can be derived from data_of_birth.
 Single-value attribute — Single-value attributes contain single value. For example,
Social_Security_Number.
 Multi-value attribute — Multi-value attributes may contain more than one values. For
example, a person can have more than one phone number, email_address, etc.
These attribute types can come together in a way like?
 simple single-valued attributes
 simple multi-valued attributes
 composite single-valued attributes
 composite multi-valued attributes

RELATIONSHIPS
The association among entities is called a relationship. For example, an employee works_ata
department, a student enrollsin a course. Here, Works_atand Enrolls are called relationships.
After two or more entities are identified and defined with attributes, the participants determine
if a relationship exists between the entities. A relationship is any association, linkage, or
connection between the entities of interest to the business; it is a two-directional, significant
association between two entities, or between an entity and itself. Each relationship has a
name, an optionality (optional or mandatory), and a degree(how many). A relationship is
described in real terms. Assigning a name, optionality and a degree to a relationship helps
confirm the validity of that relationship. If you cannot give a relationship all these things, then
perhaps there really is no relationship at all. Relationship represents an association between
two or more entities. An example of a relationship would be:
 Employees are assigned to projects.
 Projects have subtasks.
 Departments manage one or more projects.
 Relationships are the connections and interactions between the entities instances e.g.
DEPT_EMP, Associates, Department and Employee.
 A relationship type is an abstraction of a relationship i.e. a set of relationships.
 Instances shared common attributes.

106
Relationship Set
A set of relationships of similar type is called a relationship set. Like entities, a relationship
too can have attributes. These attributes are called descriptive attributes.
Degree of Relationship
The number of participating entities in a relationship defines the degree of the relationship.
Binary = degree 2
Ternary = degree 3
n-ary = degree

Types of Relationships
After two or more entities are identified and defined with attributes, the participants determine
if a relationship exists between the entities. A relationship is any association, linkage, or
connection between the entities of interest to the business; it is a two-directional, significant
association between two entities, or between an entity and itself. Each relationship has a
name, an optionality (optional or mandatory), and a degree (how many). A relationship is
described in real terms.
Assigning a name, optionality and a degree to a relationship helps confirm the validity of that
relationship. If you cannot give a relationship to all these things, then perhaps there really is
no relationship at all. Relationship represents an association between two or more entities. An
example of a relationship would be: Employees are assigned to Projects. Departments manage
one or more projects Relationships are the connections and interactions between the entities
instances e.g. DEPT_EMP associates Department and Employee. A relationship type is an
abstraction of a relationship i.e. a set of relationships instances sharing common attributes.
Entities enrolled in a relationship are called its participants.

Fig.2.4 Department and Employer Relationship with two more Entities


The participation of an entity in a relationship is total when all entities of that set might be
participant in the relationship otherwise it is partial e.g. if every Part is supplied by a Supplier
then the SUPP_PART relationship is total. If certain parts are available without a supplier
than it is partial.

107
Naming Relationships
If there is no proper name of the association in the system then participants’ names of
abbreviations are used. STUDENT and CLASS have ENROLL relationship. However, it can
also be named as STD_CLS.Roles:
Entity set of a relationship need not be distinct. For example:
 phone
 name
 city
 SSN
 manager
 employee
 works-for
 worker
The labels “manager” and “worker” are called “roles”. They specify how employee entities
interact via the “works-for” relationship set. Roles are indicated in ER diagrams by labeling
the lines that connect diamonds to rectangles. Roles are optional. They clarify semantics of a
relationship. Symbol for Relationships:

Shown as a Diamond
Diamond is doubled if one of the participant is dependent on the other Participants are
connected by continuous lines, labeled to indicate cardinality.
In partial relationships roles (if identifiable) are written on the line connecting the partially
participating entity rectangle to the relationship diamond. Total participation is indicated by
double lines

Fig. 2.5 Relationship between Department and Faculty

108
Types of Relationships
(i) Unary relationship—An Entity Type linked with itself, also called recursive relationship.
ExampleRoommate, where STUDENT is linked with STUDENT
Example 1:Roommate 1:1 Student

Fig. 2.6 Unary Relationship among Vendor and Warehouse using Quantity
Example2:Sponsored1:1Person
(ii) Binary relationship—A Binary relationship is the one that links two entities sets
e.g.STUDENTCLASS. Relationships can be formally described in an ordered pair form.
Enroll = {(S1001, ART103A), (S1020, CS201A), (S1002, CSC201A)}
Entire set is a relationship set and each ordered pair is an instance of the relationship.
M:N
Student
Class
(iii) Ternary Relationship—A Ternary relationship is the one that involves three entities e.g.
STUDENT-CLASS-FACULTY.

109
Fig. 2.7 Ternary Relationship

Fig 2.7.1 Ternary mapping

(iv) N-ary Relationship—Most relationships in data model are binary or at most ternary but
we could define a relationship set linking any number of entity sets i.e. n-ary relationship.
Entity sets involved in a relationship set need not be distinct. E.g.
Roommate = {(Student1, Student2) | Student1 ? Student Entity Set, Student2 Student
Entity Set and Student 1 is the Roommate of Student2}

2.6.5 Relationship Cardinalities


The cardinality of a relationship is the number of entities to which another entity can map
under that relationship. Symbols for maximum and minimum cardinalities are:
 Maximum inside
 Entity Type
 Minimum
 Outside

Mapping Cardinalities
Car cardinality—It defines the number of entities in one entity set, which can be associated
with the number of entities of other set via relationship set. One-to-one: One entity from
entity set A can be associated with at most one entity of entity set B and vice versa.

Fig. 2.8 One to One Entity Set


 One-to-many: One entity from entity set A can be associated with more than one
entities of entity set B, however, an entity from entity set B, can be associated with at
most one entity.

110
Fig. 2.9 One-to-One
 Many-to-one: More than one entities from entity set A can be associated with at most
one entity of entity set B, however an entity from entity set B can be associated with
more than one entity from entity set A.

Fig. 2.10 Many-to-One


 Many-to-many: One entity from A can be associated with more than one entity from
B and vice versa.

Fig. 2.10 Many-to-Many

111
Implementing RDM design using an appropriate DBMS. DBMS Software:
Environment;
Relational Data Model and Data Modelling
Data modelling is an important tool in the process of database design and development. The
purpose of data modelling is to document business rules about data that govern/control and
facilitate the functions/tasks/processing an organisation. The data model is used to represent
the real facts of the application. An application may contain many facts, however, one has to
focus only on important facts ignoring others. For example, in a student application, name of
the father may not be so important or relevant as student name, student roll number etc. The
salient features of data model are:
1. Data model mainly describes the data, which gets stored and processed in a given
situation. The data will refer to the entities and their activities in the application.
2. A data model may describe data at various levels and description maybe at logical,
physical level or from the point of user.
3. Data model proposes a set of concepts for description of the nature of data and
interrelationships between them along with the syntax. To process, the data model has
operations, by which data can be stored, retrieved, deleted and edited.
4. Data model is close to real world so that the user can understand the model and verify.
However, it should be powerful enough to distinguish between different situations.
5. Data model provides primitives by which meaning of data can be captured. The meaning
contains type of value data items take, their inter relationship to higher level entities and
the correctness requirements for them. The data semantics must have information
indicating unique values for data and dependence between values of data and also
restrictions required for insertion and deletion of data.

Phase of Data Modelling


The development of a database begins with data modelling. Data modelling has different
phases. These are:
1. Conceptual Data Modelling: Conceptual data modelling begins with identifying the data
requirements which is performed at two levels, i.e., during project initiation and planning
phase and second, during the analysis phase of the database development life cycle.
Every data attribute is defined, all categories of data are listed, every business
relationship between data entities is represented, and every rule that dictates the integrity
of the data is specified. It is also during the analysis phase that the conceptual data model
(also called a conceptual schema) is checked for consistency with other types of models
developed to explain other dimensions of the target information system, such as
processing steps, rules for handling data and the timing of events.

112
2. Logical Database Design: The perspective for logical database design approach is
transforming the conceptual data model into describing the data in terms of the data
management technology that will be used to implement the database. This process is
called normalisation. We will discuss in detail about normalisation in the later chapters.
A detailed perspective of conceptual and logical data modelling phase includes:
 Enterprise data model (during the Information Systems Planning phase)
 External schema, or user view (during the Analysis and Logical Design phases)
 Conceptual schema (during the Analysis phase)
 Logical schema (during the Logical Design phase)
 Physical schema (during the Physical Design phase)
3. Enterprise Data Model: This is a high-level model that identifies, defines and relates the
major entities of interest in an organisation. The modelling process begins by listing the
high-level entities (most small-to medium-sized organisations can be described by
between one and two dozen such entities).A clear business oriented definition of each
entity is recorded. The relationships between entities are named and described, as are
important business rules or constraints. An entity-relationship model is then usually
created. Attributes or primary keys are not usually identified in this model.
User Views: Each user view is a logical description of some portion of an enterprise
database that is required by a user to perform some task. A logical version of a user view
can be represented as an E-R or object diagram or as a set of relations.

THREE-SCHEMA COMPONENTS
In 1978, an industry committee commonly known as (ANSI/ SPARC published an
important document that described three-schema architecture for describing the
structure of data). The three schemas are illustrated in the following Figure 2.12.

Fig 2.10. * Courtesy ANSI/ SPARC published an important document that


described three-schema architecture for describing the structure of data.
Three-schema architecture for describing the structure of data.

113
1. Conceptual Schema: This schema combines the different external views into a single,
coherent definition of the enterprise’s data. The conceptual scheme are presents the view
of the data architect or data administrator. It is defined as a detailed, technology-
independent specification of the overall structure of organisational data.
Following are contemporary design goals for the conceptual data model:
• Scope is the entire organisation, or at least a major business area (this goal becomes
achievable through the use of purchased data model components, as discussed earlier in
this chapter).
• All entity types and subtypes are included. All relationships are documented.
• The model is fully attributed: all attributes, primary keys and secondary keys are
included.
• All data types and formats, attribute domains, and business rules are specified and
stored in the repository.
Ideally, the conceptual data model is fully normalised, although it is acceptable (and more
common today) to normalise in the logical model
2. Internal Schema: Internal schema consists of two separate schemas: a logical schema and
a physical schema. The logical schema is the representation of data for a type of data
management technology (e.g., relational). The physical schema describes how data are to
be represented and stored in secondary storage using a particular DBMS (e.g., MS Access
or Oracle). Logical schema is defined as “representation of a database for a particular data
management technology”.
3. Physical Schema: A physical schema is a set of specifications that describe how data
from a logical schema are stored in a computer’s secondary memory by a specific
database management system. There is one physical schema for each logical schema. The
physical schema describes the organisation of physical records, the choice of file
organisations, the uses of indexes and so on.
Entity-relational model is derived by identifying entities. Entity is the most basic
concept in the ER model that represents important objects in the real application. An entity is
something which is described in the database by storing its data.
Before we discuss the ER modelling process, let us understand the business rules,
constraints that facilitate effective identification of entities and attributes.

SUMMARY
This is a high-level model that identifies, defines and relates the major entities of interest in an
organisation. The modelling process begins by listing the high-level entities (most small-to
medium-sized organisations can be described by between one and two dozen such entities).
A clear business oriented definition of each entity is recorded. The relationships between
entities are named and described, as are important business rules or constraints. An entity-

114
relationship model is then usually created. Attributes or primary keys are not usually
identified in this model.
Management of data is not simple as the data which needs to be stored possesses different
characteristics. While developing the database, one has to consider the characteristics of data
which will be made available through the database. Following are the characteristics of data
which makes it complex in nature and difficult to manage:
Exercise 1 :
(A) (B)
Data can be aggregated. Aggregation is Data Base Management System:
nothing but cumulating or adding up. For
example, weekly sales data can be aggregated
to monthly data and monthly data are added
up to form a consolidated annual.
Accumulation. Cumulative percentage is Aggregation
always worked out on data presented as a
variable in tabular form. In business,
aggregation is of great importance. For
instance, sales figure — daily, weekly,
quarterly, half-yearly, annual, region wise,
state-wise, sales agent-wise, product type-
wise etc.
Data is compressible in nature. Large amounts Refinement
of data are compressed to make them more
meaningful. Compressed data is manageable
and can be grasped quickly. There exist a
number of techniques to compress
Data requires processing or refinement. When Compression
refined, they are capable of leading to
conclusion or even generalisation. This
refinement can then discover new facts.
Ans. (1(2), 2(1), 3(4), 4(3)
Exercise 2
Fill in the blanks—
• Scope is the entire organisation, or at least a major business area
.....................................through the use of purchased data model components..
• All entity types and subtypes are included. All .......................are documented.
• The model is fully attributed: all attributes, primary keys and secondary keys are................
• All data types and .......................attribute domains, and business rules are specified and
stored in the repository.
115
Ans: 1.this goal becomes achievable 2. Relationships 3. Included 4. Formats
Exercise 3 :
True False—
1. Data model not describes the data, which gets stored and processed in a given situation.
The data will refer to the entities and their activities in the application.
2. A data model may describe data at various levels and description maybe at logical,
physical level or from the point of user.
3. Data model proposes a set of concepts for description of the nature of data and
interrelationships between them along with the syntax. To process, the data model has
operations, by which data can be stored, retrieved, deleted and edited.
4. Data model is close to real world so that the user can understand the model and verify.
However, it should be powerful enough to distinguish between different situations.
Ans:1. False 2. True 3. True 4. True
Exercise 4
1. What do mean by Entity? Explain
2. Define Attributes with an example.
3. Explain Database Management system.

116
Database Management System - II

 DBMS Constraints
 Types of Database Models
 DBMS Software: Environment;
o Tables;
o Forms;
o Queries;
o Reports;
o Modules;
 Applying DBMS in the areas of Accounting;
 Managing the data records of Employees,
 Suppliers and Customers
 Summary
 Exercise

DATABASE CONSTRAINTS
DATABASE CONSTRAINTS
Database is a representation of the real world situation and to represent the same while
designing the database, certain rules and constraints or controls that determine the retrieval of
information with respect to the realistic environment and behaviour needs to be considered.
Following are the different types of constraints identified for the effective design of database
for any application or organisation.
1. Structural Constraints: Structural constraints are used to specify the data/information
structure that best suits to the application architecture and other parameters that are
considered while developing the database. Simple data are represented using simple data
structure and complex with complex data structure. Common data structures that are used
in the process of database design are linear structures, search trees and hashing schemes.
2. Type Constraints: Type constraint is limited to the attribute definition of an entity. For
example, the database designer would like to specify the limit for the length of a specific
attribute of an entity, specify an entity as a logical field, limit by the number of characters
for a field etc. or a set pattern to key in the data to define the value of the attribute.
3. Range Constraints: Range constraints limit the values an attribute can take. For
example, the student roll number from a specific data must start from some specific
number/digit, otherwise it will be an invalid value or specify arrange of students in a
class (say 140). The attribute value will be invalid if it crosses the limit. Similar such

117
cases can be defined when we know the limit and range, for example, days in a week,
months in a year etc.
4. Relationship Constraints: A student can enroll in another course only when the student
is a residential student. A manufacturing organisation can define in its HR policy that
minimum requirements for a skilled labour is that he/she shall possess ITI qualification
and must have completed 12th class. The above two examples represent the
characteristics of relationship constraint. Relationship constraints represent the
relationships on values between the entities.
5. Temporal Constraints: These constraints are enforced for a limited time period. For
example, sales tax, excise tax, income tax etc. Now, all the database needs to be modified
to incorporate VAT, the new tax system, before they bill to the customer. The designer
needs to identify such attributes that have changing value after certain period of time.
Another example would be internal grade of a student which will keep changing as he
improves over a period of time.
6. Dependency Constraints: Dependency constraints are considered with respect to the
relationship that exists among the data of an entity. There are two such dependencies
especially in a relational database system. They are functional dependency and transitive
dependency.
7. Domain Constraints: The data associated with domains typically include integers,
floating point numbers, date, time etc. Restrictions on the set of value of the attributes
taken can be specified. For example, COURSE NUMBER should be an integer between
0-999. Maximum number of characters in STUDENT NAME should be limited to 50
characters.
8. Key Constraints: It is a relation defined for a set of tuples, since a set does not contain
duplicates, no tuple can be identical.
9. Entity Integrity Constraints: These are the set of rules called by the application and
these are applicable on all instances of the relation. For example, in an university
application, “a student should not be allowed to take more than two courses at a time”.
“Students should complete all the assignments before taking up the final examination”.
10. Referential Integrity Constraint: This is a special type of integrity constraint that
relates two relations and maintains consistency across the relations. For example, R and S
are relations.
Let PK be the primary key of R. Set of attributes Foreign Key (FK) is said to be a
Foreign Key of S.
# The attributes in FK have the same domain as the attributes of PK.
# A null value of FK in a tuple of S also occurs as a value for PK in some tuple of R
In the example of FACULTY (eno, name, dno) and DEPT (dno, name, floor), dno attribute of
FACULTY is the foreign key which has the reference to the primary key of DEPT. This

118
creates the referential integrity constraint. (Here, FACULTY and DEPT are entities, and eno,
name, dno, floor are attributes).
Data integrity falls under the following categories:
a. Entity integrity
b. Domain integrity
c. Referential integrity.
Entity integrity ensures that each row can be uniquely identified by an attribute called
primary key. The primary key cannot have a NULL VALUE.
Domain integrity refers to the range of valid entries for a given column. It ensures that there
are only valid entries in the column.
Referential integrity ensures that for every value of a ‘y’ foreign key, there is a matching
value of the primary key.
Identifying the Entity Names The above factors indicate that the primary elements of data
modelling are entity attribute, and relationship that exist between the entities. ER model is
derived enforcing business rules and constraints. While naming the entity, one needs to ensure
that the entity identified must:
• Relate to business, not technical (hardware or software) characteristic, for example
“STUDENT’ ‘FACULTY”, ‘CUSTOMER “are good names. However, FILE1, FILE2,
PEOPLE are not good names.
• Be meaningful, i.e., the name must be self-explanatory in nature. For example, PERSON
is not a meaningful name as it may refer to a student, employee, faculty, labour, manager
etc.
• Be unique, one should be able to derive the uniqueness of the entity and its meaning. For
example, address’ does not provide unique reference. However, home address, office
address does provide the uniqueness of the entity identified. Here, address being a
common object/entity, does not provide the uniqueness.
• Readable, so that the name is structured as the concept would most naturally be said (e.g.,
grade point average is a good name, whereas average grade relative To A, although
possibly accurate, is an awkward name). It is also advisable to choose the names from the
approved list.
• Repeatable, meaning that different people or the same person at different times should
develop exactly or almost the same name; this often means that there is a standard
hierarchy or pattern for names (e.g., the birth date of a student would be student birth date
and the birth date of an employee would be Employee Birth Date).

119
GOOD DATA DEFINITIONS
Aranow gives guidelines to define the entities. They are:
• Definitions (and all types of business rules) are gathered from the same sources as all
requirements for information systems. Thus, systems and data analysts should be
looking for data objects and their definitions as these sources of information systems
requirements are studied.
• Definitions will usually be accompanied by diagrams, such as entity relationship
diagrams. The definition does not need to repeat what is shown on the diagram, but
rather supplement the diagram. A definition will state such characteristics of a data
object as:
(i) Subtitles
(ii) Special or exceptional conditions
(iii) Examples
(iv) Where, when and how the data are created or calculated in the organisation
(v) Whether the data are static or changes over time
(vi) Whether the data are singular or plural in its atomic form
(vii) Who determines the value for the data
(viii) Who owns the data (i.e., who controls the definition and usage)
(ix) Whether the data are optional or if empty (what we will call null)values are
allowed
(x) Whether the data can be broken down into more atomic parts or if it is often
combined with other data into some more composite or aggregate form if not
included in a data definition, then these characteristics need to be documented
elsewhere, where other metadata are stored.

TYPES OF DATABASE MODELS


A model is a collection of relation instances, one instance for each relation in the programme
that satisfies some condition or rule. A data model is collection of such models that are used
to describe the structure of the database which provides the necessary means to achieve data
abstraction. One can also specify the operations like add, delete, modify and retrieve any type
of data using the data model.
The data models are categorised, based on the types of concepts they describe for the database
structure. Three types of data models are identified, viz.:
a. high level or conceptual data models
b. logical data model
c. low level or physical data model

120
The conceptual data model provides the concepts that are perceived by the end user and it
uses concepts such as entity, attributes and relationships. The logical data model provides the
concepts that are understood by the designers of the database and, sometime also by the end
user. Logical model is also referred as ER model or object-oriented model as per the approach
to develop the model. The physical data model deals with the data storage concepts, data
storage structure, data structure and access paths etc. In this chapter we will discuss mainly
the logical model especially entity relationship model.

Entity-relationship model (or E-R model)


It is a detailed, logical representation of the data for an organisation or fora business area. It is
expressed in terms of:
a. entities,
b. the relationships among those entities,
c. the attributes (or properties) of both the entities and their relationships.
An E-R model is normally expressed as an entity-relationship diagram(or E-R diagram),
which is a graphical representation of an E-R model. The following figure illustrates a sample
E-R Diagram of Modi Hospital. The Purchase department of the MH can purchase any
number of items that are required for different departments from a number of different
suppliers, who then supply the items to the hospital. The entities are represented by the
rectangle symbol, whereas relationships between entities are represented by the diamond
symbol connected by lines to the related entities. The model that has resulted from extending
the original E-R model with new modelling constructs is called Enhanced entity-
relationship (EE-R) model.
The most important modelling construct incorporated in the EE-R model is super type/subtype
relationships. This facility enables us to model a generalentity type (called the super type) and
then subdivide it into several specialisedentity types (called subtypes). Thus, for example, the
entity type CAR can be modelled as a super type, with subtypes PETROL CAR, DIESEL
CAR, SOLARCAR and so on. Each subtype inherits attributes from its super type and in
addition may have special attributes of its own. Adding new notation for modelling super
type/subtype relationships has greatly improved the flexibility of the basic E-R model.
The entities in the figure are shown in fig 2.13:

121
Fig. 2.13: Simple of Entity Relationship Diagram (ER Diagram)
• Department/Customer: A department which has ordered or might order items that are
required for the provision of services at the hospital. Example: Drugs from Pharmacy
Dept.
• Item/Drug: (Here, item is drugs) that may be ordered by the Pharmacy department. The
product may be anything, e.g., papers, X-Ray machines or photocopying machine,
computers etc. which may be from any department.
• Order: The transaction associated with the purchase of one or more products to a
customer and identified by an order number from accounting department. Example: The
event of an order for a bulk order of tablet “Metacin” from pharmacy department.
• Supplier: Another company that supplies ordered items to Purchase department of MH.
Example: J J Medical Suppliers, Mangalore.
• Shipment: The transaction associated with items sent and received in the same package
by MH. All items in a shipment appear on one bill-of lading document. Example: The
receipt of 1000 straps of Tablet “Metacin” from J J Medical Suppliers on 27th April,
2005.
The symbols at the end of each line on an E-R diagram represent relationship cardinalities. In
the figure 1.13, we find cardinality symbols express the following business rules:
1. A SUPPLIER may supply many ITEMs. By ‘may supply’ we mean the supplier may not
supply any item. Each ITEM is supplied by any number of SUPPLIERs. By ‘is supplied’
we mean that the item must be supplied by at least one supplier.
2. Each ITEM must be used in at least one DEPARTMENT and may be used in many
DEPARTMENTs. Conversely, each DEPARTMENT must use one or more ITEMs.
3. A SUPPLIER may send many SHIPMENTs. However, each shipment must be sent by
exactly one SUPPLIER. Notice that sends and supplies are separate concepts. A
SUPPLIER may be able to supply an item, but may not yet have sent any shipments of
that item.
122
4. A SHIPMENT must include one (or more) ITEMs. An ITEM may be included on several
SHIPMENTS.
5. DEPARTMENT/CUSTOMER may submit any number of ORDERs. However, each
ORDER must be submitted by exactly one DEPARTMENT/CUSTOMER.
6. An ORDER must request one (or more) ITEM (S). A given ITEM may not be requested
on any ORDER, or may be requested on one or more orders.
By careful observation, we find that each of the above rules follow some semantics where
entity and relationships are defined. The cardinality of the relationship vary from minimum to
maximum.
For example, the semantic for the rule 5 can be stated as: <DEPARTMENT/CUSTOMER-
«may = <submit = <any number—ORDER
As we proceed further, we will discuss E-R Diagram in detail with examples. Before we
proceed further, we have to understand the notations used in the E-R Diagram. The following
figure 2.14. illustrates the notations used in E-R Diagram.

Fig. 2.14 Showing Basic Entity-Relationship Diagram


We will deal in detail about Extended E-R model later in this chapter.

Object-Oriented Model
A recent development in the data modelling is the development of object-oriented model. In
object-oriented model, the entity is treated as a class. In this approach, the real environment is
represented as an object. A class is an entity that has a well-defined role in the application
domain about which the organisation wishes to maintain state, behaviour and identity. An
object is an instance of a class that encapsulates data and behaviour. This approach apart from
enabling to add on operations, represent associations between objects, also enables to add user
defined features for data types, user operations etc.

123
Cardinality Constraints
Suppose, there are two entity types, A and B, which are connected by a relationship. A
cardinality constraint specifies the number of instances of entity B that can (or must] be
associated with each instance of entity A. For example, consider a library that stores the
magazines and journals received as bound volumes, once all the issues are received. Same
Journal being published every year it has to maintain the information about all the issues that
are available at the library and, hence, we can identify a ‘one-to-many’ relationship as in the
Figure 2.15.

Fig. 2.14: Cardinality Constraints


1. Minimum Cardinality—The minimum cardinality of a relationship is the minimum
number of instances of entity B that may be associated with each instance of entity A.
In Figure 2.15, the minimum number of one journal title is zero. When the minimum
number of user who will be reading that is also zero, we say that entity type Bis an
optional participant in the relationship. In this example, BOUNDVOLUME is an
optional participant in the ‘Is_stocked_as’ relationship. This fact is indicated by the
symbol zero through the line near the Bound Volume entity.
2. Maximum Cardinality—The maximum cardinality of a relationship is the maximum
number of instances of entity B that may be associated with each instance of entity A.
In the video example, the maximum cardinality for the BOUND_VOLUME entity
type is ‘many’—that is, an unspecified number greater than one. This is indicated by
the ‘crow’s foot’ symbol. Figure 2.16 illustrates minimum and maximum cardinalities.
PATIENT has recorded PATIENT HISTORY (Figure 2.16). Each patient has one or
more patient histories (the initial patient visit is always recorded as an instance of
PATIENT HISTORY). Each instance of PATIENT HISTORY belongs to exactly one
PATIENT.

124
Fig. 2.16: Showing Minimum and maximum Cardinalities
1. EMPLOYEE Is_assigned_to PROJECT (Figure 2.16). Each PROJECT has at least one
EMPLOYEE assigned to it (some projects have more than one). Each EMPLOYEE may
or (optionally) may not be assigned to any existing PROJECT (e.g., employee ‘Pete’), or
may be assigned to one or more PROJECTs.
2. PERSON is married to PERSON (Figure 2.16). This is an optional zero or one cardinality
in both directions, because a person may or may not be married.
It is possible for the maximum cardinality to be a fixed number, not an arbitrary ‘many’ value.
For example, suppose, corporate policy states that an employee may work on at most five
projects at the same time. We could show this business rule by placing a 5 above or below the
crow’s foot next to the PROJECT entity in Figure 2.16.

MODELLING TIME-DEPENDENT DATA


We know that some data or information keeps changing. For example price of a product,
grade of student etc. If one keeps track of the change, it is only possible by modelling the time
factor. This is called Time Stamp. A time stamp is simply a time value (such as date and
time) that is associated with a data value. Time stamps may be recorded to indicate the time
the value was entered(transaction time), the time the value becomes valid or stops being valid,
or the time when critical actions were performed (such as updates, corrections, or audits). In
Figure 2.17 each value of the attribute Price is time stamped with its effective date.

Fig 2.17: Time Stamp

125
Multiple Relationships
In some situations, an organisation may wish to model more than one relationship between the
same entity types. Two examples are shown in Figure2.18 which shows two relationships
between the entity types EMPLOYEE and DEPARTMENT. The relationship Works in
associates employees with the department in which they work. This relationship is one-to-
many and is mandatory in both directions. That is, a department must have at least one
employee who works there (perhaps the department manager) and each employee must be
assigned to exactly one department.

Fig. 2.18: multiple relations


(Note: These are specific business rules we assume for this illustration).
Example of E-R Model: Pharmacy Database / Information System at Modi Hospital
One can develop E-R diagram adopting either top-down approach or bottom-up approach. In
top-down approach we proceed from basic descriptions of the business while in a bottom-up
approach, we start from detailed discussions with the end user. To develop E-R model for
Modi Hospital, following business rules and constraints are considered:
• PHARMACY will be kept open 24/7. It will have its outlet in the hospital premises to
ease the logistics involved in moving around the hospital premises and also save some
time.
• PHARMACY DEPARTMENT is one of the service centres of the Modi Hospital
which sells drugs to both inpatient and outpatient who visit the hospital for various
health problems. The drugs are sold to patients based on the ‘PRESCRIPTION given
by the doctors serving at Modi Hospital.
• The PAYMENT from the PATIENT is accepted only based on the BILL.
• The BILL is prepared based on the PRESCRIPTION.
• Each PRESCRIPTION can have more than one drug prescribed but minimum of one
drug prescribed and similarly each bill contains more than one drug but minimum of
one drug billed
• The credit facility is available only to an inpatient.
• PHARMACY DEPARTMENT gives 10% discount on the bill to EMPLOYEES OF
THE MODI HOSPITAL AND THOSE WHO HAVE Medicare, 7% discount to
Health Card’ holders.

126
• The discount to inpatients – those who are employees and have medicare will get 13%
discount, inpatients with ‘health card’ 7% and others 5% if the total bill cost exceeds
`500.00
• A patient who gets admitted through a camp conducted by Lions or Rotary club will
be given free medicine but not exceeding `500.00
• All the material requirements of the PHARMACY will be the responsibility of the
PURCHASE DEPARTMENT.
• PHARMACY DEPARTMENT CANNOT PLACE ANY ORDER WITH ANY
SUPPLIER FOR ANY TYPE OF DRUG, but can always submit its requirements to
the purchase department any time.
• Each request submitted should come in a format specifying date, drug name,
manufacturer, quantity etc. with authorisation and each request once submitted cannot
be changed. In such a case, a new request has to be submitted. It can send any number
of requests in a day or not even a single request in a day.
• PURCHASE DEPARTMENT has supplier’s file.
• A SUPPLIER may supply in part or whole any number of drugs based on the order
placed but the PAYMENT is made only once all the drugs that are ordered is received.
• PHARMACY needs to maintain DRUG data.
• Since the pharmacy works 24/7 it has increased its employee strength from 10 to 15,
excluding Kamat who heads the department. Among the15, three of them are
supervisors who on shift basis supervise all the business processes. However, it has
five more people to be staffed at the outlet which would shortly start functioning.
• Each employee has exactly one supervisor. With the following rules and constraints,
the following entities were identified.
Entity Type Attribute
DRUG DrugIdentifier
Drug_Name
Drug_Type
Drug_Manufacturer
Drug_Manufacture_date
Drug_Expiry_Date
Drug_Batch_No
Drug_Unit_Cost
PATIENT Patient_Reg_No
Patient_Fname
Patient_Lname

127
Patient_Address1
Patient_Address2
Patient_Address3
Patient_State
Patient_Pin
Patient_Phone
Patient_Cell_No
Patient_Email
Patient_Healthcard_No
Patient_Medicare_Number
Patient_Medical_Details Patient_Height
Patient_Weight
Patient_Bloodgroup
Patient_Rh_Positive_Negative
ORDER Order_Number
Order_Placement_Date
Order_Fulfilment_Date
Supplier_Identifier
Order_Received_Date
ORDERED PRODUCT Order_Number
Product_Identifier
Order_Quantity
PAYMENT Invoice_Number
Payment_Date
Payment_Amount
SUPPLIER Supplier_Id
Supplier_Name
Supplier_Address1
Supplier_Address2
Supplier_Address3
Supplier_Place
Supplier_Phone
Supplier_Email

128
Supplier_Cell_No
Supplier_Trackrecord
WHOLESELLER WS_Id
WS_Name
WS_Address1
WS_Address2
WS_Address3
WS_Place
WS_Phone
WS_Email
WS_Cell_No
WS_Tarckrecord
PRESCRIPTION Prescription_No
Prescription_Date
Prescription_Dept
BILL Patient_reg_No
Patient_Reg_No
Drug_Identifier
Drug_Name
Drug_Unit_Cost
Drug_Qty
Total_Amount

129
Fig 2.19 ER Diagram for Modi Hospital

DATABASE PROCESSING AT PHARMACY DEPARTMENT


The following paragraphs illustrate simple examples of database processing using simple SQL
commands. However, we shall discuss in detail the data processing, using SQL in later
chapters. To fully understand these queries, you will need to understand concepts introduced
later in this volume. However, a few simple queries in this chapter should help you to
understand the capabilities of a database to answer important organisational questions and
give you a jump-start toward understanding SQL.
Many different users have a need to see data about the drugs available in the pharmacy. For
example, an employee whose responsibility is to accept the prescription from the patient and
bill for the drugs requested for, the head of the department certainly would like to know what
are the drugs available, manufactured by Pills and Dows. He may also be interested to know
the manufacturer’s list, total sales made etc.
Some Example Queries

130
To illustrate how to make queries, we use SQL. The three basic commands used by SQL to
query the database(s) are SELECT, FROM and WHERE.
1. To display some of the columns of a Table DRUG the command would be:
SQL>SELECT, Drug_identifier, Drug, Name, Drug_manufacturer,Drug_batch_no,
FROM DRUG
SQL will respond with the following result:
Drug_identifier Drug_Name Drug_Manufacturer Drug_batch_No
0000001 ANACIN RANBAXY 23-01-00
0000002 METACIN RANBAXY 12-11-03

2. To display all the columns, the command will be: SQL-SELECT FROMDRUG
The result will display all the columns that are defined for the entityDRUG.
3. List all details of the drugs that are manufactured by Pills and Dows and available in
the pharmacy.
The data for this query is maintained in the DRUG entity. The query scans this entity
and displays all the attributes for products that contain the description Pills and Dows’.
The SQL code for this query is:
SELECT *
FROM DRUG
WHERE Manufacturer id = “Pills and Dows’;
Typical output for this query is:
Manufacturer_id 123
1. AVON 100
2. NIBULUS 150
4. Another common information need is to show details of the bills madeon a specific
date. The data for this is available in BILL entity. The querywill be:
SELECT Bill_No, Bill_Date, Total_Amount
FROM BILL
WHERE Bill_date= ‘30-APR-05’
The output for this query is
Bill_No Bill_Date Total_Amount
20001 30-APR-05 1200.00
20002 30-APR-05 2300.00
20003 30-APR-05 700.00

131
5. To know the drugs whose expiry date is 30-APR-05’
The SQL command will be
SQL>SELECT Drug_identifer, Drug_name, Drug=manufacturer FROMDRUG
WHERE Drug_expiry date= 30-APR-05’
The output that will be displayed will be as below

Drug_identifier Drug_name Drug_manufacturer Drug_expiry_date


1232424 SARIDON NICOLAS PIRAMAL 30-APR-05
2334444 AMOX-500 RANBAXY 30-APR-05

ADVANCED TECHNIQUES IN DATA MODELLING


The E-R modelling, which we have discussed often does not satisfy the complex business
process to be modelled. Hence, to achieve that the present, E-R modelling is enhanced by
adopting new features and characterising the entities with enhanced features. The E-R
diagram developed using such enhanced characters is called enhanced entity relation (EE-R
Diagram). The enhanced features identified are super type and subtype attributes in an entity,
generalisation and specialisation, completeness, constraint, total specialisation, partial
specialisation, disjoint rule, overlap rule, subtype discriminator, super type discriminator,
structural assertion and action assertion and entity clustering etc.
Packaged Data Models
To ease out the process of data modelling today we find packed data models.

DBMS Software: Environment; Tables; Forms; Queries; Reports; Modules


Tables

132
133
Forms

134
Query

135
Report

Applying DBMS in the arears of Accounting


Managing the data records of Employees
Suppliers and Customers
Exercise :
You have to create a database of the students must have at least two tables shown in the
examples above
You have to take query of students on the basis of tables shown above in the example figures
You have to provide report on the basis of above shown report figure above

136

You might also like