Oat Material
Oat Material
Oat Material
Features of Ms-Excel, Parts of MS-Excel window, entering and editing data in worksheet, number formatting in
excel, different cell references, how to enter and edit formula in excel, auto fill and custom fill, printing options.
…………………………………………………………………………………………………………………………………………………………………………………
1Q.Features of Ms-Excel
Microsoft excel is an integrated electronic spread sheet program developed by Microsoft
corporation.It includes the following features.
Autocalc: This feature is very useful to sum a group of numbers is selected them. Their sum will
automatically appear in the status area.
Auto complete: Excel now intelligence to anticipate what you are going to type! Based upon
entries you’ve already made, AutoComplete will try to figure out what you intended to type,
once you’ve entered few letters.
Better Drag-and-Drop: Do you want to move a group of cells? Excel’s drag and drop feature lets
you reposition selected portion of your spreadsheet by simply dragging them with your mouse.
Cell tips and Scroll Tips: To help you get around better with mouse, Excel now includes scroll
tips. When you click and drag a scroll bar, a small window tells you what row or column you are
heading for.
Number Formatting: It’s easy to format numbers with excel’s new number formatting feature.
Select your numbers and choose cells command from format menu.
Templates and Template wizard: Excel’s template facility has been greatly enhanced. You can
choose from a variety of elegantly designed templates for your home or business. You can even
have a template wizard link your worksheets to a database.
Shared Lists: you can now have worksheets that are shared simultaneously over a network.
Sorting and Filtering:Excel spreadsheets help us make sense of large amounts of data. To make it
easier to find what you need, you can reorder the data or pick out just the data you need, based
on parameters you set within Excel. Sorting and filtering your data will save you time and make
your spreadsheet more effective.
Excel Charts:Excel charts help you communicate insights & information with ease. By choosing
your charts wisely and formatting them cleanly, you can convey a lot.
1
2Q.Parts of MS-Excel window:office 2007 and its parts
2
Quick Access Toolbar – Collection of buttons that provide one click access to commonly used
commands such as Save, Undo or Redo. You can also customize this according to your
preference.
Title Bar – A bar the display the name of active workbook
Ribbon – The main set of commands and controls organized task in Tabs and groups, you can
also customize the ribbon according to your preference.
Column Headings – The letters that appear along the top of the worksheet to identify the
different columns in the worksheet.
Worksheet Window – A window that displays an Excel worksheet, basically this is where you
work all the tasks.
Vertical Scroll Bar – Scroll bar to use when you want to scroll vertically through the
Worksheet window.
Horizontal Scroll Bar – Scroll bar to use when you want to scroll horizontally through the
worksheet window.
Zoom Controls – Used for magnifying and shrinking of the active worksheet.
View Shortcuts – Buttons used to change how the worksheet content is displayed. Normal,
Page Layout or Page Break Preview.
Sheet Tabs – Tabs the display the name of the worksheet in the workbook, by default its name
sheet 1, sheet 2, etc. You can rename this to any name the best represent to your sheet.
Sheet Tab Scrolling Buttons – Buttons to scroll the sheet tabs in the workbook
Row Headings – The number that appears on the left of the worksheet window to identify the
Different rows.
Select All Button – A button that selects all the cells in the active worksheet
Active Cell – The cell selected in the active worksheet
Name Box – A box that displays the cell reference of the active cell
Formula Bar – A bar that displays the value or formula entered in the active cell
Office Button/File Tab – It provides access to workbook level features and program settings.
You will notice that in Excel 2007 there is a circle.
Note:
Important terms
3
3Q.Entering and editing data in worksheet
You have several options when you want to enter data manually in Excel. You can enter data in
one cell, in several cells at the same time, or on more than one worksheet at the same time. The
data that you enter can be numbers, text, dates, or times. You can format the data in a variety
of ways. And, there are several settings that you can adjust to make data entry easier for you.
To enter data on a new line within a cell, enter a line break by pressing
If there are multiple lines of text in a cell, some of the text might not be displayed the way that
you want. You can display multiple lines of text inside a cell by wrapping the text.
4
4Q.how to enter and edit formula in excel
A formula performs calculations or other actions on the data in your worksheet. A formula
always starts with an equal sign (=), which can be followed by numbers, math operators (like a
+ or - sign for addition or subtraction), and built-in Excel functions, which can really expand the
power of a
Formula.
For Example, in the above worksheet, the formula = B5+C5+D+ adds the contents 10+20+30 and
produce the results. One can enter and edit formula in two ways.
1. Directly into cell by double clicking where the formula wants.
2. At formula bar after selection of required cell.
5
Right click your mouse; from the short hand menu select format cell option.
6
Absolute references:An absolute cell reference in a formula, such as $A$1, always refer to a cell
in a specific location. If the position of the cell that contains the formula changes, the absolute
reference remains the same. If you copy or fill the formula across rows or down columns, the
absolute reference does not adjust. By default, new formulas use relative references, so you may
need to switch them to absolute references. For example, if you copy or fill an absolute reference
in cell B2 to cell B3, it stays the same in both cells: =$A$1.
Mixed references A mixed reference has either an absolute column and relative row, or
absolute row and relative column. An absolute column reference takes the form $A1, $B1,
and so on. An absolute row reference takes the form A$1, B$1, and so on. If the position of
the cell that contains the formula changes, the relative reference is changed, and the
absolute reference does not change. If you copy or fill the formula across rows or down
columns, the relative reference automatically adjusts, and the absolute reference does not
adjust. For example, if you copy or fill a mixed reference from cell A2 to B3, it adjusts from
=A$1 to =B$1.
7
How to resolve circular cell reference?
A formula in a cell that directly or indirectly refers to its own cell is called a circular reference
.This causes the formula to use its result in the calculation, which can create errors. When a
workbook contains a circular reference, Excel cannot automatically perform calculations. You
can use error checking in Excel to locate circular references in a formula, and then remove
them.
To find your circular references, on the Formulas tab, in the Formula Auditing group, click the
down arrow next to Error Checking.
8
9
How excel displays the exact series?
All the lists such as days, months are predefined in the excel list command. When you dragged it
this Command it executed. Here the default list commands series.
11
9Q.Printing options
Use print preview to change many default print settings and see what you’ll print. Also, select a specific range of
cells to print, and print a table in a worksheet.
Print a part of a worksheet:
1.Click the worksheet, and select the range of data that you want to print.
3. Under Settings, click the arrow next to Print Active Sheets and select Print Selected Table.
4. Click the Print button. If a worksheet has defined print areas, Excel will print only those print areas. If you don’t
want to print only a defined print area, check the Ignore print area box.
3.Under Settings, click the arrow next to Print Active Sheets and select Selected Table.
2. On the PAGE LAYOUT tab, in the Sheet Options group, check the Print box under Gridlines.
12
Unit-II
Formatting options: Different formatting options, change row height, formulae and functions
Functions: Meaning and advantages of functions, different types of functions available in Excel.
…………………………………………………………………………………………………………
Ans:
1. Inserting Rows/Columns
You can insert blank cells above or to the left of the active cell on a worksheet. When you insert blank cells,
Excel shifts other cells in the same column down or cells in the same row to the right to accommodate the
new cells. Similarly, you can insert rows above a selected row and columns to the left of a selected column.
You can also delete cells, rows, and columns.
To Inserting Rows:
1. To insert a single row, select either the whole row or a cell in the row above which you want to
insert the new row. For example, to insert a new row above row 5, click a cell in row 5.
2. Right-click the selected cells and then click Insert.
On the Home tab, in the Cells group, click the arrow under Insert, and then click Insert Sheet Rows.
To Inserting Columns:
1. To insert a single column, select the column or a cell in the column immediately to the right of where
you want to insert the new column. For example, to insert a new column to the left of column B, click a
cell in column B.
2. Right-click the selected cells and then click Insert
3. On the Home tab, in the Cells group, click the arrow under Insert, and then click Insert Sheet Columns..
13
2. Deleting Rows / Columns
1. Select the cells, rows, or columns that you want to delete.
2. On the Home tab, in the Cells group, click the arrow next to Delete, and then do one of thefollowing:
14
To Change Row Height
1. Select the row or rows that you want to change.
2. On the Home tab, in the Cells group, click Format.
3. Under Cell Size, click Row Height.
4. In the Row height box, type the value that you want.
Hide or unhide columns in your spreadsheet to show just the data that you need to see or print.
Hide columns
1. Select one or more columns, and then press Ctrl to select additional columns that aren't adjacent.
2. Right-click the selected columns, and then select Hide.
15
Unhide columns
1. Select the adjacent columns for the hidden columns.
2. Right-click the selected columns, and then select Unhide.
If you enjoy working with the ribbon, you can hide rows in this way:
1. Go to the Home tab > Cells group, and click the Format button.
2. Under Visibility, point to Hide & Unhide, and then select Hide Rows.
Alternatively, you can click Home tab >Format > Row Height… and type 0 in the Row Height box.
Different formatting options
Number Formatting:
It is very common to enter various types of numbers for various applications. In Excel, you can use number
formats to change the appearance of numbers, including dates and times, without changing the number
behind the appearance. The number format does not affect the actual cell value, it changes the appearance
only.
16
1. Select the cell or cells which contain numbers.
2. On the home tab, under Number group click on down arrow mark.
Or Right click your mouse; from the short hand menu select format cell option.
If you check Excel 2003 version, auto format option is there on the menu. But, with the release of 2007 with
ribbon this option is not available in any of the tabs.
That doesn’t mean you can’t use it in earlier versions. It’s still there, but hidden. So, to use it in the Excel
versions like 2007, 2010, 2013, and 2016 you need to add it to your Excel’
From “choose commands from” select “commands not in the Ribbon”. Then find “Auto Format” and click on
Add. Then it will add to quick access tool bar.
18
How to Use Auto Format?
Once you click OK, it will instantly apply your chosen format on the data
4Q.Explain various formatting options in Microsoft
Excel (OR) What are formatting functions on Excel
sheet? Explain. (OR) Explain the formatting features
in Excel.
Ans:
19
To italicize text in Microsoft Excel:
1. Select the cell or cells in which you wish to italicize the text.
2. On the HOME tab, in the Font group, click the Italic command.
3.Select the type of border you wish to add from the drop down menu:
C) Change Text and Cell Colors
To change the color of text in cells in Microsoft Excel:
1. Select the cell or cells in which you wish to change the color of the text.
2. On the HOME tab, in the Font group, click the arrow to the right of the Font Color command.
20
3. Select a color from the drop down
1. Select the cell or cells in which you wish to change the fill color.
2. On the HOME tab, in the Font group, click the arrow to the right of the Fill Color command.
21
D) Set Font and Font Size
To change the font of text or numbers in cells in Microsoft Excel:
1.Select the cell or cells in which you wish to change the font.
2.On the HOME tab, in the Font group, click the arrow to the right of the Font command.
To change the size of the font of text or numbers in cells in Microsoft Excel:
1. Select the cell or cells in which you wish to change the font size.
2. On the HOME tab, in the Font group, click the arrow to the right of the Font Size command.
22
3. Select a font size from the drop down
For example, instead of specifying each value to be summed like in the above formula,
you can use the SUM Function to add up a range of cells: =SUM (A2:A4)
You can find all available Excel functions in the Function Library on the Formulas tab:
1. One of the key benefits of using excel functions is that they help simplify your formulas.
23
2. Another key benefit of using functions is that they help you accomplish tasks
that would be difficult with standard formulas.
3. Functions can also help save time by helping you automate tasks that would
take you hoursto accomplish manually.
Parts of Function:
A function is a predefined formula that performs calculations using values indicated in a
particular order. To use functions correctly, you’ll need to be aware of the different parts of a
function.
The specific way in which a function is written is referred to as syntax. The syntax for a function is:
Average function:
For example, the function =AVERAGE(B1:B9) would calculate the average of the values in the
cell range B1:B9. This function contains only one argument.
24
SUMIF - Adds all the values in a range that meet
specific criteria
of digits
number of digits
of significance
of significance
Statistical Functions:
in a range
in a range
cells in a range
cells in a range
COUNTIF - Counts all the cells in a range that meet specific criteria
LARGE - Return a value dependent upon its ranking in a range of values in descending order
25
SMALL - Return a value dependent upon its ranking in a range of values in ascending order
Text Functions
start of a cell
end of a cell
middle of a cell
characters
Financial Functions
PMT - Calculates loan repayments based on constant payments and a constant interest rate
PV - Returns the present value of an investment based on a constant interest rate and payments
FV - Returns the future value of an investment based on constant payments and a constant interest
rate
VLOOKUP - Looks vertically down a list to find a record and returns information related to that
record
HLOOKUP - Looks horizontally across a list to find a record and returns information related to
that record
OFFSET - Returns a value from a cell, or range of cells that are a specified number of rows and
columns from another cell
ADDRESS - Returns a text representation of a cell address from specified row and column numbers
Logical Functions
IFERROR - Performs a specified action if a formula evaluates to an error, and displays the formula
result if not Date & Time Functions
DATE - Returns the sequential serial number for the specified date and formats the
result as a date
between 1 and 12
YEAR - Returns the year corresponding to a date represented by a number in the range 1900 to
9999
WORKDAY - Returns the date a specified number of workings days before or after a date
Get Year, Month, Week or Day Number:If a cell contains a date and time, you can use the following functions
to extract the year, month number, or day number from the date. In this example, the date is in cell A2.
Year: =YEAR(A2)
Month: =MONTH(A2)
Week: = WEEKNUM(A2)
Day: = DAY(A2)
NOTE: If the result looks like a date, instead of a number, change the cell's number format to General
28
Get Month or Day Name:
If a cell contains a date, you can extract parts of that date as text. For example, show the month name,
or the weekday name of the date. In this example, the date is in cell A2.
Month Name (short): =TEXT(A2,"mmm")
Month Name (long): =TEXT(A2,"mmmm")
Weekday Name (short): =TEXT(A2,"ddd")
Weekday Name (long): =TEXT(A2,"dddd")
Function Description
DATE function Returns the serial number of a particular date
DATEDIF Calculates the number of days, months, or years between two dates. This function
function is useful in formulas where you need to calculate an age.
DATEVALUE Converts a date in the form of text to a serial number
function
DAY function Converts a serial number to a day of the month
DAYS360 Calculates the number of days between two dates based on a 360-day
function year
EDATE function Returns the serial number of the date that is the indicated number of
months before or after the start date
EOMONTH Returns the serial number of the last day of the month before or after a
function specified number of months
HOUR function Converts a serial number to an hour
29
Excel Engineering Functions
Converting Between Units of Measurement
The Microsoft Excel INFO function returns information about the operating environment.
The INFO function is a built-in function in Excel that is categorized as an Information Function. It can
be used as a worksheet function (WS) in Excel. As a worksheet function, the INFO function can be
entered as part of a formula in a cell of a worksheet.
Syntax
The syntax for the INFO function in Microsoft Excel is:
INFO( type )
The 12 database functions let you find and perform calculations on specific pieces of data in
a database. All of the database functions search a specified database for records that match
specified criteria. Some of the database functions then perform calculations on data in a
specified field of the matching records.
30
DAVERAGE DGET DPRODUCT DSUM
DCOUNT DMAX DSTDEV DVAR
DCOUNTA DMIN DSTDEVP DVARP
/ Division =B3/A2
^ Exponentiation =A2^3
31
, (comma) Union operator that combines multiple references into =SUM(A2,C4:D17,B3)
one
reference
Unit-III: Charts: Different types of charts, Parts of chart, chart creation using wizard, chart
operations, data maps, graphs, data sorting, filtering. Excel sub totals, scenarios, what-if
analysis.
Macro: Meaning and advantages of Macros, creation, editing and deletion of macros - Creating a
macro, how to run, how to delete a macro
32
2Q.Explain parts of chart?
Ans:An excel chart comprises of many parts as shown in the figure
chart area:chart area is an entire area that is reserved for accommodating the chart and other
parts such as legends,title etc.
33
Y-axis:it is a vertical line whose length and segments represent different values.Y-axis used to
show the different variations of different identities.
X-axis:A horizontal line on which you show the variation of another intervals of values.
Y-axis title:Y-axis titles identifies the values that have been shown on y-axis
X- axis title:X-axis titles conveys the full details of the x-axis values
Grid lines:grid lines are the lines that can be thought as an extension of thick marks.
Data series:data series is a collection of related values that are plotted on a chart.
Data label:data label is some piece of text,which is written near data point to highlight some
aspect of it.
Chart title:chart title is the text written in chart area,which identifies the chart.
Legends:legends are some sort of labels that identifies different series that have been plotted in
the chart.
34
4Q.Explain chart operations?
Ans: Create a Chart:
To create a line chart, execute the following steps.
1. Select the range A1:D7.
2. On the Insert tab, in the Charts group, click the Line symbol.
35
3.Click Line with
Markers. Result:
4. Click OK.
36
Switch Row/Column:
If you want to display the animals (instead of the months) on the horizontal axis, execute the following
steps.
1. Select the chart.
2. On the Design tab, in the Data group, click Switch Row/Column.
37
When sorting data, it's important to first decide if you would like the sort to apply to the entire worksheet or just a
cell range.
Sort sheet organizes all of the data in your worksheet by one column.
Sort range sorts the data in a range of cells, which can be helpful when working with
a sheet that contains several tables. Sorting a range will not affect other content on
the worksheet.
To sort a sheet :
In our example, we'll sort a T-shirt order form alphabetically by Last Name (column C).
1. Select a cell in the column you wish to sort by. In our example, we'll select cell C2.
2. Select the Data tab on the Ribbon, then click the Ascending command to Sort A to
Z, or the Descending command to Sort Z to A. In our example, we'll click the
Ascending command.
3. The worksheet will be sorted by the selected column. In our example, the worksheet
is now sorted by last name.
38
7Q.Explain filtering data?
If your worksheet contains a lot of content, it can be difficult to find information quickly. Filters can be used to
narrow down the data in your worksheet, allowing you to view only the information you need.
To filter data :
1. In order for filtering to work correctly, your worksheet should include a header
row, which is used to identify the name of each column.
2. Select the Data tab, then click the Filter command.
3. A drop-down arrow will appear in the header cell for each column.
4. Click the drop-down arrow for the column you wish to filter.
5. The Filter menu will appear.
6. Uncheck the box next to Select All to quickly deselect all data.
7. Check the boxes next to the data you wish to filter, then click OK.
39
To remove all filters from your worksheet, click the Filter command on the Data tab.
Parameters or Arguments
method
The type of subtotal to create, but be careful which method you select. method can be a value ranging
from 1 - 11 that includes hidden values or a value ranging from 101 - 111 that ignores hidden values in
the calculation.
.
Explanation
Value (includes
hidden values)
1 AVERAGE
2 COUNT
3 COUNTA
4 MAX
5 MIN
6 PRODUCT
7 STDEV
8 STDEVP
9 SUM
10 VAR
40
Explanation
Value (includes
hidden values)
11 VARP
Explanation
Value (ignores
hidden values)
101 AVERAGE
102 COUNT
103 COUNTA
104 MAX
105 MIN
106 PRODUCT
107 STDEV
108 STDEVP
109 SUM
110 VAR
111 VARP
Applies To
Excel for Office 365, Excel 2019, Excel 2016, Excel 2013, Excel 2011 for Mac, Excel 2010, Excel 2007,
Excel 2003, Excel XP, Excel 2000
Type of Function
41
Example (as Worksheet Function)
Let's look at some Excel SUBTOTAL function examples and explore how to use the SUBTOTAL function as a
worksheet function in Microsoft Excel:
Based on the Excel spreadsheet above, the following SUBTOTAL examples would return:
=SUBTOTAL(1, D2:D5)
Result: 22.3925
=SUBTOTAL(2, D2:D5)
Result: 4
=SUBTOTAL(3, D2:D5)
Result: 4
=SUBTOTAL(4, D2:D5)
Result: 35.88
=SUBTOTAL(5, D2:D5)
Result: 7
=SUBTOTAL(6, D2:D5)
Result: 136191.51
=SUBTOTAL(7, D2:D5)
Result: 11.91825316
=SUBTOTAL(8, D2:D5)
Result: 10.32151
=SUBTOTAL(9, D2:D5)
Result: 89.57
42
=SUBTOTAL(10, D2:D5)
Result: 142.0447583
=SUBTOTAL(11, D2:D5)
Result: 106.5335688
If you sell 60% for the highest price, cell D10 calculates a total profit of 60 * $50 + 40 * $20 = $3800.
Create Different Scenarios:
But what if you sell 70% for the highest price? And what if you sell 80% for the highest price?
Or 90%, or even 100%? Each different percentage is a different scenario. You can use the
Scenario Manager to create these scenarios.
1. On the Data tab, in the Forecast group, click What-If Analysis.
43
The Scenario Manager dialog box appears.
3. Add a scenario by clicking on Add.
4. Type a name (60% highest), select cell C4 (% sold for the highest price) for the Changing cells and
click on OK.
44
10Q.Explain meaning and advantages of macros?
Meaning and advantages of Macros
A Macro is a series of commands and functions that are stored in a Microsoft Visual Basic
module and can be run whenever you need to perform the task. Regularly repeating
activities can be automated by using macro.
Advantages of Macros:
Macros offer many advantages to those who choose to use them. They reduce the possibility of
human error that increases with many, repetitive keystrokes and tasks. Macros reduce the
amount of time that must be spent performing basic computing tasks, freeing users up for more
complex problem-solving and idea-generating activities. They also make complex computations
easier to perform.
Reduced Typing:The repeated activities can be recorded into a macro and you can play whenever
you want.
Save Time:Macros stores number of activities, by executing a single macro you can perform
complex activities. Reduce Mistakes : It avoids spelling and grammar mistakes, due to less typing
work.
Uniformity:The recorded macro can play whenever you want. It performs the stored activities in
the same stored order. So, it can be used for maintain uniformity.
Productivity:It can be used to increase the productivity.
Edit: If you want, you can edit a macro whenever you want to meet your latest requirements.
Reusability:One macro can be used in another macro.
Simplicity:Number of actions can be executed by pressing single macro.
11Q.CREATING A MACRO?
ANS: Creating a Macro:
1. On the Developer tab, in the Code group, click Record Macro
45
2. Complete the Record Macro dialog box.
i. In the Macro name box, enter a name for the macro.
ii. A short cut key can be assigned to run the macro.
iii. In the Store macro in list, select the workbook where you want to store the macro.
iv. In the Description box, type a description of the macro, if
desired 3.Click OK to start recording and perform the actions that you want to
record.
4. When you are finished recording, on the Developer tab, click Stop Recording. You can
also click the Stop Recording button on the left side of the status bar.
Running Macro
Deleting a Macro
46
Assign a Macro to a Button
47
UNIT-4
Ans:
48
To use a template to create a database:
1. Start Access.
2. Click Blank Database.
3. Type the name you want to give your database in the File Name field. Access
will automatically append .accdb to the name.
4. Click the Browse button. The File New Database window appears.
5. Locate the folder in which you want to store your database. Note that the name of the
file appears in the File Name field.
6. Click OK.
7. Click the Create button. Access creates the database and opens a datasheet with the
Table Tools available to you
49
3Q.Expain parts of MS access?
The title bar starts on the left side with the Office Button . If you position the mouse on it, a tool tip would
appear:
. If you want to hide the Quick Access toolbar, you can right-click it and click Remove Quick
Access Toolbar.
By default the Quick Access toolbar is equipped with three buttons: Save, Undo, and Redo.
Any of these actions would open the Access Options dialog box:
50
To add a command, click it in the middle list and click Add. Once you have selected the desired options, click OK.
The main or middle area of the top section displays the name of the application: Microsoft Access.
On the right side of the title bar, there are three system buttons that allow you to minimize, maximize, restore, or
close Microsoft Access.
Under the title bar, there is another bar with a Help button on the right side.
The middle section itself is made of two sides. The top part allows you to create a database. The bottom section
displays some promotional information from Microsoft.
The right side displays as a column with the top title labeled Open Recent Database with a More button under it. By
default, the area under the More button is empty:
51
The bottom section of the Microsoft Access interface displays a status bar.
The Ribbon
In Access 2007, you use the Ribbon to issue commands. The Ribbon is located near the top of the Access
window, below the Quick Access toolbar. At the top of the Ribbon are several tabs; clicking a tab displaysrelated
command groups.
52
Here are some of the most common data types you will find used in a typical
Microsoft Access database.
Type of Data Description Size
53
Some of the most important field properties to note are:
Field Size:
You encountered the Field Size property before, when working with the Number data type. This
property also exists for the common Text data type.
Format:
This property enables you to set the precise manner in which Access displays or prints the data that is
located in its Tables. As with Field Size, the format available to select depends on the data type of
that column.
Input Mask:
This feature can be useful in data entry situations. Where Format controls how data is displayed,
Input Mask controls how data is entered into a particular field. Input Mask is available for the
following data types: Text, Number, Date/Time, and Currency.
Default Value:
An important database concept, the default value can help save time in the data entry process.
You may need to inspect assets like queries, forms, and other objects to ensure that the name
change has correctly spread throughout the database.
54
Deleting Tables in Microsoft Access
To practice these actions without damaging existing tables, download some sample databases and
experiment until you're comfortable manipulating the tables in a database that's important to you.
55
4.Type the first field name in the Field Name field.
5.Press the Tab key.
6. Click the down-arrow that appears when you click in the Data Type field and then select a
data type.
7. Click Primary Key if the column you created is a primary key. A small key appears next to
57
Highlight the tables that you wish to import. In this example, we have selected the Suppliers table.
When you have finished selecting the tables, click on the OK button.
You have the option now of saving your import steps. Click on the OK button.
Form Wizard you can select the layout style of your form. There are four layouts to choose from:
in the Ribbon. Then click the “Report Design” button in the “Reports” button group. Unlike other report
controls, the chart control uses its own data source to show its data.
“Chart Wizard” lets you type a title for your chart into the box provided. It also lets you select whether
or not to add a legend to the chart. Click the “Finish” button to add the chart control to your report.
Don’t be alarmed if the chart doesn’t display your data in the design view- it won’t. You must switch to
“Layout View” to see the data in the chart and also resize the chart control until it appears the way
you want it to in the report.
59
60
UNIT-5
1Q.Explain creating and using select queries?
You can create a select query by using the Query Wizard or by working in Design view. Some design elements
are not available when you use the wizard, but you can add these elements later by using Design view. Although
the two methods are somewhat different from each other, the basic steps are essentially the same:
1.Choose the tables or queries that you want to use as sources of data.
2.Specify the fields that you want to include from the data sources.
3.Optionally, specify criteria to limit the records that the query returns.
After you have created a select query, you run it to see the results. To run a select query, you open it in
Datasheet view. If you save the query, you can reuse it whenever you need, for example, as a data source for a
form, report, or another query.
2. In the New Query dialog box, click Simple Query Wizard, and then click OK.
3. Next, you add fields. You can add up to 255 fields from as many as 32 tables or query.
When you sort data using the sort dialog box, you get an option to add multiple levels to it.
Here are the steps to do multi-level sorting using the dialog box:
61
2. Click the Data tab.
3. Click on the Sort Icon (the one shown below). This will open the Sort dialog box.
3. Order: Largest to
Smallest 4.Click OK
62
3Q.explain crosstab Queries?
A Microsoft Access crosstab query presents summary information in a compact format that is similar to a spreadsheet.
These types of queries can present a large amount of summary data in a format that is usually simpler to analyse than
viewing the information in a database form. Each attribute (field) in a table typically contains a category of data. A
crosstab query summarizes the data from one or more of these fields that are separated into groups based on one or
more fields.
Which ever way you decide to go, you must specify the following three items:
Row Heading field: The name of the field selected as the row heading begins the first column in the query results
datasheet. Each value in this field is displayed in the first column as a row title.
Column Heading field: The values in the field selected as the column heading are displayed as headings for the
remaining columns in the query results datasheet.
Value field: The values in the selected field are summarized by the values in the rows and columns. You must
designate the summary operation to be performed. For example, you might want to sum or average the values in a field.
1. To use multiple tables for the crosstab query, you will first need to create a separate query that has the tables required
in it. The Crosstab Query Wizard will only allow you to select one table or one query for the row and column headings.
2. You can not specify limiting criteria whilst using the crosstab query wizard.
Ans: In Access, there is another very useful wizard and that is Find Unmatched Query Wizard. The Find
Unmatched Query Wizard creates a query that finds records or rows in one table that have no related records in
another table.
As we have already discussed how data joins together in queries, and how most queries are looking for the
matches between two or more tables.
This is the default join in Access, for example, if we design a query with two
tables, tblCustomers and tblOrders, and join those two tables by the CustomerIDs, this query will return only the
results that match. In other words, the customers who have placed orders.
63
There are times when we don't want to see the matches, for instance, we may not want to see any customer
in our database — the customers who have not placed orders as yet.
64
Click the down-arrow in the first field on the Field row and then select the tablename.* option. The table name appea
Click the Run button. Access retrieves all of the fields and records for the table and displays them in Datasheet view.
Ans: When you want to select specific data from one or more sources, you can use a select query. A select query helps
you retrieve only the data that you want, and also helps you combine data from several data sources.
1.Choose the tables or queries that you want to use as sources of data.
2.Specify the fields that you want to include from the data sources.
3.Optionally, specify criteria to limit the records that the query returns.
After you have created a select query, you run it to see the results.
You can use the Query Wizard to automatically create a select query. When you use the wizard, you have less
control over the details of the query design, but the query is usually created faster than if you did not use the
wizard. Moreover, the wizard can catch some simple design mistakes and prompt you to perform a different
action.
Ans:
When access responds to a query,that response constitutes a dynaset.A dynamic set of data meeting your query
criteria.
Report:reports are paper copies of dynasets.you can also store reports to disk.Access can help create
reports.There are even wizards for complex print outs like crosstab reports.
Print Report: Print report without seeing the report on the Print Preview. The report will be print immediately
after clicking a Print Report button.
3. Change the page format setup or other print options or printer selection as needed, and then click OK to print
Custom Queries : Custom query records contain the SQL statement used to pull information from
the database.
Data Formats : Data format records describe how to format and display the results of the related custom
query. Data formats may also be interrelated to create child/parent combinations of queries.
Advanced Reports : Advanced report records serve as headers for the report and may display one or more
data format. The advanced report record may also be scheduled to be automatically run and emailed to a
user
Creating Advanced Reports:Since a single advanced report consists of records from three different modules, the
following instructions will step through creating a record within each module and relating those records to
generate a report. First, a custom query record will be created, then a data format, and finally an advanced
report record. The fields specific to each module are described prior to each set of creation instructions.
Ans:you can make changes to reports by adding or deleting report sections and controls and by changing their
properties.
66
1.Begin by switching to the database window.click on the reports tab,and then on the design button.
Report header:the report header contains a label with the reports title,and often other controls.
Page header:page headers contain information that will repeat on every page like column headings.
Detail section:the detail section contains labels and field controls that specify which data will be printed.
Page footer:the page footer contains text and expressions that print on each page.
Report footer:the report footer contains items that appear only at the end of a report,like grand totals,or
instructive text like “please report all errors to manager”.
Relational Database
A relational database, on the other hand, incorporates multiple tables with methods for the tables to work
together. The relationships between table data can be collated, merged and displayed in database forms. Most
relational databases offer functionality to share data:
Across networks
Over the Internet
With laptops and other electronic devices, such as palm pilots
With other software systems
One-to-One:A row in table A can have only one matching row in table B, and vice versa.
68
Example of one-to-many relationship.
Many-to-Many:
In a many-to-many relationship, a row in table A can have many matching rows in table B, and vice versa.
This is the Relationships tab that is displayed when you create a relationship Microsoft Access. In this case, a
many-to-many relationship has just been created. The Orders table is a junction table that cross-references the
Customers table with the Products table.
Ans: View table relationships:To view your table relationships, click Relationships on the Database Tools tab.
The Relationships window opens and displays any existing relationships. If no table relationships have been
defined and you are opening the Relationships window for the first time, Access prompts you to add a table or
query to the window.
69
2. Select and open the database.
17Q.Defining Relationships?
The table or query you selected appears in the Relationships window. Repeat steps 5 and 6 for each table you
want to use in a relationship.
Click Close.
Drag the common field in the first table to the common field in the second table. When you release the
mouse button, a line appears between the two tables, signifying that they are related. Also, the Edit Relationships
dialog box opens, in which you can confirm or modify the relationship.
Click the Join Type button if you want to specify the join type. Click OK to return to the Edit Relationships
dialog box.
Click Create to create the relationship.
70
Click to view larger image
Click the Query Design button to create a query in Design view. You could also use the Query Wizard button
next to it to launch the Query Wizard, however, Design view gives you more control over the query.
Tables to Include in the Query
71
The Show Table dialog allows you to choose which tables to include in the query. You can also include other queries
to use within a query.
Query Design View:
72
Query Design View allows you to specify the precise criteria for the query. You can choose which tables are shown
in the results, which fields to use, add filtering criteria, and more.
Creating relationship:
1. Open the Relationship Dialog. Click Relationships from the Database Tools tab on the Ribbon. ...
2. Select the Tables. Select both the Artists and Albums tables from the list and click Add . ...
3. Create the Relationship. ...
4. Edit the Relationship. ...
5. The Relationship.
Deleting relationships:
1.On the Database Tools tab, in the Relationshipsgroup, click Relationships.
2.On the Design tab, in the Relationships group, click All Relationships. ...
3. Click the relationship line for the relationship that you want to delete. ...
4. Press the DELETE key.
73