0% found this document useful (0 votes)
34 views17 pages

CS403 IMP Notes For Final

CS403 IMP Notes
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
34 views17 pages

CS403 IMP Notes For Final

CS403 IMP Notes
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 17

CS403 Paper and Final Term Notes

Short Notes and Important Topics Answer by VUAnswer.com

Atomicity:
Atomicity states that database modifications must follow an "all or nothing" rule.
Each transaction is said to be "atomic". If one part of the transaction fails, the entire
transaction fails. It is critical that the database management system maintain the
atomic nature of transactions in spite of any DBMS, operating system or hardware
failure.
Attribute:
An attribute is a named column of a relation.
Business Logic:
The sequence of events that take place behind any business
process Candidate Key:
A candidate key is a combination of attributes that can be uniquely used to identify
a database record without any extraneous data. Each table may have one or more
candidate keys. One of these candidate keys is selected as the table primary key.
Cardinality:
The cardinality of a relation is the number of tuples it contains.
Conceptual Level:
The community view of the database. This level describes what data is stored in the
database and the relationship among the data.
Consistency:
Consistency states that only valid data will be written to the database. If, for some
reason, a transaction is executed that violates the database’s consistency rules, the
entire transaction will be rolled back and the database will be restored to a state

1|Page
consistent with those rules. On the other hand, if a transaction successfully
executes, it will take the database from one state that is consistent with the rules to
another state that is also consistent with the rules.
Cursor:
Cursors are database objects used to traverse the results of an SQL query. They
point to a certain location within a record set and allow the operator to move
forward (and sometimes backward, depending upon the cursor type) through the
results one record at a time.
Data:
Data can be described as "Collection of raw facts and figures".
Data Manipulation Language (DML):
A language that provide a set of operations that support the basic data manipulation
operations on the data held in the database.
Data Definition Language (DDL):
A descriptive language that allows the DBA or user to describe and name the
entities required for the application and the relationships that may exist between the
different entities.
Data dictionary:
The description of data is known as data dictionary. “Centralized repository of
information about data such as meaning, relationships to other data, origin, usage,
and format” Data Independence:
Data Independence means that upper levels are unaffected by changes to lower
levels.
Data Model:
An integrated collection of concepts for describing data, relationships between
data and constraints on the data in an organization Data warehouse:

2|Page
A repository where data from multiple databases is brought together for more
complex analysis Database:
A shared collection of logically related data (and a description of this data),
designed to meet the information needs of an organization Database
Schema:
The overall description of the database is called database schema.
DBMS:
A software system that enables users to define, create and maintain the database
and provides controlled access to this database.
Degree:
The Degree of a relation is the number of attributes it contains.
Domain:
A domain is the set of allowable values for one or more attributes.
Durability:
Durability ensures that any transaction committed to the database will not be
lost. Durability is ensured through the use of database backups and transaction
logs that facilitate the restoration of committed transactions in spite of any
subsequent software or hardware failures Enterprise:
An enterprise is an organization that utilizes computers and applications. In general
use, enterprises refer to businesses/organizations that operate on a large scale.
Applications that are designed for these organizations are often referred to as
enterprise applications.
Enterprise constraints:
Additional rules specified by the the users or database administrators of a database.
Entity:

3|Page
An entity is a single object about which data can be stored. It is the "subject" of a
table. Entities and their interrelationships are modeled through the use of entity-
relationship diagrams.
Entity integrity:
in base relation, no attribute of a primary key can be null.
Entity-Relationship Diagram:
An entity-relationship diagram is a specialized graphic that illustrates the
interrelationships between entities in a database. External View:
The User's view of the database. This level describes that part of the database that
is relevant to particular user.
File-based System:
A collection of application programs that perform services for the end users such as
the production of reports. Each program defines and manages its own data.
Foreign Key:
An attribute or set of attributes within one relation that matches the candidate key
of some (possibly the same) relation.
Functional Dependency:
A functional dependency occurs when one attribute in a relation uniquely
determines another attribute. This can be written A -> B which would be the same
as stating "B is functionally dependent upon A." Internal View:
The physical representation of the database on the computer. This level describes
how the data is stored in the database.
Logical Data Independence:
Logical Data Independence refers to immunity of external schema to changes in the
conceptual schema.
Metadata:
The description of data is known as Metadata.
4|Page
Non-procedural DML:
A language that allows the user to state what data is needed rather than how it is to
be retrieved.
Null:
Represents a value for an attribute that is currently unknown or is not
applicable for this tuple
ODBC:
A standard that allows a database to be exchanged and opened by other compliant
database software, independent of the database's file format or what program was
originally used to create it.
Physical Data Independence:
Physical Data Independence refers to immunity of the conceptual schema to
changes in the internal schema
. Primary Key:
The candidate key that is selected to identify tuples uniquely within the
relation Procedural DML:
A language that allows the user to tell the system exactly how to
manipulate the data Query:

Deep analysis is carried out by performing multilayer queries. Because all the
databases are linked, you can search for what products a store has too much of.
You can then determine which of these products commonly sell with popular
items, based on previous sales. After planning a promotion to move stock, you can
dig deeper to see where this promotion would be most popular (and most
profitable).
Referential integrity:

5|Page
If foreign key exists in a relation, either the foreign key value must match a
candidate key value of some tuple in its home relation or the foreign key value
must be wholly null.
Relation:
A relation is a table with columns and rows.
Relational database:
A collection of normalized relations.
Relational Schema:
A relation name followed by a set of attributes and domain name pairs.
Super key:
An attribute or set of attributes that uniquely identifies a tuple within a relation.
System Catalog:
The description of data is known as system catalog.
Tuple:
A tuple is a row of a relation.

6|Page
QUESTION What are major differences between traditional file processing
system and database?

Answer: The main differences are of data sharing, data independence, data
integrity and controlled redundancy.

Question: What is the difference between data and information?

Answer: Data is raw collection of facts and figures collected from a specific
environment. Once we process the data using different methods the data is
converted into useful information.

Question: What is data consistency?

7|Page
c

Answer: Data consistency means that the changes made to different occurrence
of data should be controlled and managed in such a way that all the occurrences
have same value for any specific data item.

Lab 15

EMPLOYEE:
EmpName Designation Age Salary
Akhtar Zaman Deputy Director 38 65000
Tariq Khan Supervisor 27 16000
Farman Ullah Account Officer 28 28000
Shabir Hussain Account 35 40000
Manager
Sajid Iqbal Admin Officer 30 30000
Farooq Awan Clerk 25 14000
Abdullah Khan Accountant 27 17000
Rana Tahir Office Boy 20 12000
Perveez Arshad HR Manager 45 42000

You are required to write an SQL query to create a “View” on this table having
Emp_Name, Designation and Salary columns. Furthermore, the view would have
information for only those employees having salaries greater than 25000.

Solution:

8|Page
c

CREATE VIEW Employee_View AS


SELECT Emp_Name, Designation, Salary
FROM EMPLOYEE
WHERE Salary > 25000 ;

Mechanism to Conduct Lab:


Lab will be conducted via Adobe Connect.

What are major differences between traditional file processing


system and database?

Answer: The main differences are of data sharing, data independence,


data integrity and controlled redundancy.

Question: What is the difference between data and information?

Answer: Data is raw collection of facts and figures collected from a


specific environment. Once we process the data using different methods
the data is converted into useful information.

Question: What is data consistency?

9|Page
c

Answer: Data consistency means that the changes made to different


occurrence of data should be controlled and managed in such a way that
all the occurrences have same value for any specific data item.

Data: Data can be described as "Collection of raw facts and


figures".

Data Definition Language (DDL): A descriptive language that allows


the DBA or user to describe and name the entities required for the
application and the relationships that may exist between the different
entities.

Data dictionary: The description of data is known as data dictionary.


“Centralized repository of information about data such as meaning,
relationships to other data, origin, usage, and format".

Data Independence: Data Independence means that upper levels are


unaffected by changes to lower levels.

Data Model: An integrated collection of concepts for describing


data, relationships between data and constraints on the data in an
organization.

Data warehouse: A repository where data from multiple databases is


brought together for more complex analysis.

Database: A shared collection of logically related data (and a


description of this data), designed to meet the information needs of an
organization.

Database Schema: The overall description of the database is called


database schema.

10 | P a g e
c

DBMS: A software system that enables users to define, create and


maintain the database and provides controlled access to this database.

Degree: The Degree of a relation is the number of attributes it contains.

Domain: A domain is the set of allowable values for one or more


attributes.

Durability: Durability ensures that any transaction committed to the


database will not be lost. Durability is ensured through the use of database
backups and transaction logs that facilitate the restoration of committed
transactions in spite of any subsequent software or hardware failures

Enterprise: An enterprise is an organization that utilizes computers and


applications. In general use, enterprises refer to businesses/organizations
that operate on a large scale. Applications that are designed for these
organizations are often referred to as enterprise applications.

Enterprise constraints: Additional rules specified by the the users or


database administrators of a database.

Entity: An entity is a single object about which data can be stored. It


is the "subject" of a table. Entities and their interrelationships are modeled
through the use of entity-relationship diagrams.

Entity integrity: in base relation, no attribute of a primary key can be


null.

Entity-Relationship Diagram: An entity-relationship diagram is a


specialized graphic that illustrates the interrelationships between entities
in a database.

External View: The User's view of the database. This level describes that
part of the database that is relevant to particular user.

11 | P a g e
c

File-based System: A collection of application programs that perform


services for the end users such as the production of reports. Each program
defines and manages its own data.

Foreign Key: An attribute or set of attributes within one relation that


matches the candidate key of some (possibly the same) relation.

Functional Dependency: A functional dependency occurs when one


attribute in a relation uniquely determines another attribute. This can be
written A -> B which would be the same as stating "B is functionally
dependent upon A.

USE FULL LINKS

http://www.oracle.com/index.html
Description:

URL: http://www.sitepoint.com/article/sql-server-2000-database
Description: A stepwise approach of using SQL server 2000. Good site of

URL: http://www.sqlcourse.com/
Description: Interactive Online SQL Training for Beginners

12 | P a g e
c

The tools that we will be studying are a manipulation


language (SQL) and a DBMS (SQL Server).

SQL (Structured Query Language)

What is SQL?

SQL (pronounced "less-que-el") stands for Structured Query Language.


SQL is used to communicate with a database. According to ANSI
(American National Standards Institute), it is the standard language for
relational database management systems. SQL statements are used to
perform tasks such as update data on a database, or retrieve data from a
database. Some common relational database management systems that use
SQL are: Oracle, Sybase, Microsoft SQL Server, Access, Ingres, etc.
Although most database systems use SQL, most of them also have their
own additional proprietary extensions that are usually only used on their
system. However, the standard SQL commands such as "Select", "Insert",
"Update", "Delete", "Create", and "Drop" can be used to accomplish
almost everything that one needs to do with a database. This tutorial will
provide you with the instruction on the basics of each of these commands
as well as allow you to put them to practice using the SQL Interpreter.

DEFINITION

WHAT IS DATA BASE?

data base is a shared collection of logically related data that is stored to


meet the requirements of different user of an organization.

Def 1: A shared collection of logically related data, designed to meet the


information needs of multiple users in an organization. The term database
is often erroneously referred to as a synonym for a “database management

13 | P a g e
c

system (DBMS)”. They are not equivalent and it will be explained in the
next section.
A collection of related information about a subject organized in a useful
manner that provides a base or foundation for procedures such as
retrieving information, drawing conclusions, and making decisions.
A Computerized representation of any organizations flow of information
and storage of data.
What is database management system explain?

A database management system (DBMS) is system software for creating


and managing databases. The DBMS provides users and programmers
with a systematic way to create, retrieve, update and manage data

What is a database management system and give examples?

Some DBMS examples include MySQL, PostgreSQL, Microsoft Access,


SQL Server, FileMaker, Oracle, RDBMS, dBase, Clipper, and FoxPro.
Since there are so many database management systems available, it is
important for there to be a way for them to communicate with each other.

What is difference between DBMS and Drums?

Key Difference between DBMS and RDBMS: The key difference is that
RDBMS (relational database management system) applications store data
in a tabular form, while DBMS applications store data as files ...... In a
RDBMS, the tables will have an identifier called primary key. Data
values will be stored in the form of tables.

What are DBMS advantages and disadvantages?

14 | P a g e
c

Although the database system yields considerable advantages over


previous data management approaches, database systems do carry
significant disadvantages. For example: 1. Increased costs. one of the
disadvantages of dams is Database systems require sophisticated
hardware and software and highly skilled personnel.

Is SQL a DBMS?

DBMS means Database Management System, which is a concept and a


set of rules that all or major Database Systems follows.
... DBMS products like SQL Server, Oracle, MySQL, IBM DB2, etc.
uses SQL as a standard language. SQL language used in these tools is
very common and have similar syntaxes.

What is difference of data and information?

Data are simply facts or figures — bits of information, but not


information itself. When data are processed, interpreted, organized,
structured or presented so as to make them meaningful or useful, they are
called information. Information provides context for data.

What is difference between data and information in DBMS?

Data vs. Information - Differences in Meaning. Data are simply facts or


figures — bits of information, but not information itself.

15 | P a g e
c

When data are processed, interpreted, organized, structured or presented


so as to make them meaningful or useful, they are called information.
Information provides context for data.

What is the importance of database?

A database management system is important because it manages data


efficiently and allows users to perform multiple tasks with ease. A
database management system stores, organizes and manages a large
amount of information within a single software application

Database: A database management system (DBMS) is a collection of


programs that manages the database structure and controls access to the
data stored in the database.
The DBMS serves as the intermediary between the user and the database.
The database structure itself is stored as a collection of files, So, we can
access the data in those files through the DBMS.
The DBMS receives all application requests and translates them into the
complex operations required to fulfill those requests. The DBMS hides
much of the database’s internal complexity from the application programs
and users.
Advantages:

1. Improved data sharing


2. Improved data security
3. Better data integration
4. Minimized data inconsistency
5. Improved data access

16 | P a g e
c

6. Improved decision making


7. Increased end-user productivity
The advantage of data base is: -
• Reduced data redundancy
• Reduced updating errors and increased consistency
• Greater data integrity and independence from applications programs
• Improved data access to users through use of host and query
languages
• Improved data security
• Reduced data entry, storage, and retrieval costs
• Facilitated development of new applications program

Disadvantages:

1. Increased costs
2. Management complexity
3. Maintaining currency
4. Frequent upgrade/replacement cycles.

17 | P a g e

You might also like