Professional Documents
Culture Documents
Arid Agriculture University, Rawalpindi: Final Exam / Fall 2020 (Paper Duration 24 Hours) To Be Filled by Teacher
Arid Agriculture University, Rawalpindi: Final Exam / Fall 2020 (Paper Duration 24 Hours) To Be Filled by Teacher
To be filled by Student
Question No. 1:
Student Table:
Course Table:
Enrollment Table:
Queries
Enrollment enr
Answer: The high level language queries runs on top of the machine language and provides high
level of abstraction.
The low level language queries are machine friendly. It provides no or less abstraction from the
hardware.
Basic operators such as +,-,* are applied on relations for producing required results.
Answer: There are different types of anomalies that can occur in relations. They are:
Insertion anomaly: If a tuple is inserted in referencing relation and referencing attribute value is not
present in referenced attribute, it will not allow inserting in referencing relation.
Deletion and Updation anomaly: If a tuple is deleted or updated from referenced relation and the
referenced attribute value is used by referencing an attribute in referencing relation, it will not allow
deleting the tuple from referenced relation.
Answer: A NATURAL JOIN is a JOIN operation that creates an implicit join clause for you based on
the common columns in the two tables being joined. Common columns are columns that have the
same name in both tables.
A NATURAL JOIN can be an INNER join, a LEFT OUTER join, or a RIGHT OUTER join. The default is
INNER join.
Syntax:
Examples:
Question No. 3: Write SQL statements and relation algebra for following:
Answer:
Question No. 4:
Answer: DBMS (Database Management Systems) refers to the technology approach used to
optimize and handle database data storage and retrieval.
Security of databases requires a number of security controls designed to secure the framework of
database management (DBMS). Protecting the underlying infrastructure that houses the database,
such as the network and servers, safely configuring the DBMS, and accessing the data itself, are the
types of database security measures the company can use.
Protection of databases includes various controls, including device hardening, access, configuration
of DBMS, and monitoring of security. These various security measures assist in monitoring the
circumvention of security protocols.
Extra access to the DBMS is provided by the underlying architecture. It is important that all devices,
including insider threats, are regularly patched, hardened using established security configuration
norms, and monitored for entry.
DBMS configuration
It is important to properly configure and harden the DBMS to take advantage of security features
and restrict privileged access that can cause the intended security settings to be misconfigured.
Monitoring the configuration of the DBMS and maintaining proper procedures of change control
helps ensure the configuration remains consistent.
Authentication
Database security measures include authentication, the process of checking whether user
credentials match those stored in your database, and allowing access to your files, networks, and
database platforms for authenticated users only.
Access
The successful restriction of access to your data is a primary outcome of database security. Access
controls authenticate legitimate users and programs, restricting the database to what they can
access. Access means designing and granting suitable attributes and responsibilities for users and
restricting administrative rights.
Database auditing
Centralized control of the database is established by tracking (or auditing) activities as part of a
database security protocol. Auditing helps to track, prevent, and decrease the cumulative effect of
your DBMS unauthorized access.
Backups
A data backup makes a copy of your data and stores it on a different device as part of your database
security protocol. This backup enables you to recover missing information that can result from
hardware failures, manipulation of data, fraud, hacking, or natural disasters.
Encryption
Database security may include safe encryption key management, encryption device protection,
secure, off-site encryption backup management, and protocols for access restriction.
Application security
Security framework interventions for databases and applications can help defend against common
known intruder vulnerabilities that can bypass access controls, including injection of SQL.
There are 5 key steps to ensuring database security, according to administrative procedure:
Isolate sensitive databases - Keep an accurate list of all enterprise-wide databases and classify all
confidential information residing on those databases.
Eliminate vulnerabilities- Evaluate, locate and remedy bugs that expose the database on a
continuous basis.
Enforce least privileges- Identify user rights and implement restrictions and privileges for user
access to restrict access to only the minimal data necessary for workers to do their jobs.
Monitor for deviations- Enforce appropriate policies and monitor any vulnerabilities that can not be
patched for any and all behavior that deviates from approved activity.
Respond to suspicious behavior- To mitigate the risk of attack, alert and respond in real time to any
abnormal or suspicious activity.