Computer Knowledge

Database Management Systems

5,543 Questions

Database Management Systems (DBMS) form the core framework for data storage, retrieval, and security in modern software applications. Concepts such as the E-R model, backup planning, SQL integration, and big data architecture are essential for computer knowledge sections. This hub offers a comprehensive set of practice questions to master DBMS fundamentals and advanced database operations.

E-R Model ConceptsBackup and RecoverySQL Server UpgradesJDBC and ODBCBig Data CharacteristicsData VirtualizationOracle Database

Database Management Systems Questions

Multiple choice technology databases
  1. The control file can grow in size.

  2. The control file can store RMAN scripts.

  3. CONTROL_FILE_RECORD_KEEP_TIME determine retention time for RMAN records.

  4. The RMAN catalog can exist solely in the control file of the target database.

Reveal answer Fill a bubble to check yourself
A,C Correct answer
Explanation

The control file can grow in size when new records are added (like RMAN metadata). CONTROL_FILE_RECORD_KEEP_TIME determines how long RMAN records are kept in the control file - it directly controls retention. Option B is false because RMAN scripts are stored in the RMAN catalog or filesystem, not the control file. Option D is false because while RMAN can use a control file catalog, it requires additional configuration and is not automatic.

Multiple choice technology databases
  1. alert.ora

  2. init.ora

  3. tnsname.ora

  4. redolog

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

The alert log (often historically referred to or associated with alert.log or an alert file) contains critical status and error information for the Oracle instance. The init.ora is for parameters, tnsnames.ora is for Net configuration, and redologs store change vectors.

Multiple choice technology databases
  1. SYNC or ASYNC to identify the network transmission mode.

  2. LGWR or ARCH to identify the primary database process responsible for sending redo information to the standby.

  3. AFFIRM or NOAFFIRM to control whether log archiving disk write operations are to be performed synchronously or asynchronously.

  4. PROTECTED or UNPROTECTED to control the degree of divergence and data loss at the standby database.

Reveal answer Fill a bubble to check yourself
A Correct answer
Multiple choice technology databases
  1. Extent

  2. Segement

  3. Oracle block

  4. Operating system block

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

The UNIFORM SIZE 1M clause sets the extent size to 1 MB uniformly across the tablespace. Each extent allocated will be exactly 1 MB, not the segment, block, or OS block. SEGMENT is the collection of extents. Oracle block is the smallest unit of I/O (typically 8KB). OS block is managed by the operating system.

Multiple choice technology databases
  1. V$UNDOSTAT
  2. V$TRANSACTION
  3. V$ROLLSTAT
  4. DBA_UNDO_EXTENTS

  5. DBA_ROLLBACK_SEGS

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

V$UNDOSTAT provides undo statistics including undo blocks written, which can be used to calculate blocks per second. It tracks undo usage over time intervals. V$TRANSACTION shows current transactions but not historical rates. V$ROLLSTAT shows rollback segment statistics but not per-second rates. DBA_UNDO_EXTENTS shows extent allocation, not write rates. DBA_ROLLBACK_SEGS shows rollback segment configuration, not activity.

Multiple choice technology databases
  1. OPEN

  2. IDLE

  3. MOUNT

  4. NOMOUNT

Reveal answer Fill a bubble to check yourself
D Correct answer
Explanation

To restore the control file using RMAN, the target database must be in a NOMOUNT state because the control file itself is required to transition the database to the MOUNT state. OPEN and MOUNT require the control file to already be loaded.

Multiple choice technology databases
  1. PMON

  2. SMON

  3. RECO

  4. ARCn

  5. CKPT

Reveal answer Fill a bubble to check yourself
B Correct answer
Explanation

SMON (System Monitor) performs instance recovery after a crash, including rolling forward uncommitted changes and rolling back uncommitted transactions. PMON (Process Monitor) cleans up failed processes. RECO handles distributed transaction recovery. ARCn archives redo logs. CKPT (Checkpoint) updates file headers to checkpoint position.

Multiple choice technology databases
  1. User the DROP DATAFILE command.

  2. Use the DROP TABLESPACE command.

  3. Ensure that all database files are Oracle Managed Files(OMF) before using the DROP TABLESPACE command.

  4. Ensure that the DB_FILE_CREATE_DEST initialization parameter is set before using the DROP TABLESPACE command.

Reveal answer Fill a bubble to check yourself
B Correct answer
Explanation

The DROP TABLESPACE command is used to remove a tablespace from the database. To automatically delete the associated data files, you must include the INCLUDING CONTENTS AND DATAFILES clause. Option A mentions a non-existent DROP DATAFILE command, while options C and D describe prerequisites for automatic file deletion in Oracle Managed Files environments.

Multiple choice technology databases
  1. The index need to be dropped, and then re-created.

  2. The resolution of index fragmentation depends on the type of index.

  3. The index can be rebuilt while users continue working on the table.

  4. The fragmented can be ignored because Oracle resolve index fragmentation by means of a freelist.

  5. The index can be rebuilt, but users will not have access to the index during this time.

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

Oracle allows online index rebuilds using the ALTER INDEX ... REBUILD ONLINE command. This operation rebuilds the fragmented index while maintaining DML operations on the underlying table. Dropping and recreating the index (option A) would work but causes more downtime. Option E is incorrect because users can continue working during an online rebuild. The fragmentation type (option B) doesn't determine whether you can rebuild online.

Multiple choice technology databases
  1. The oracle server creates no undo tablespace.

  2. The oracle server creates an undo segment in the system tablespace.

  3. The oracle server cerates one undo tablespace with the name SYS_UNDOTBS.

  4. Database creation fails because you did not specify an undo tablespace on the create database statment.

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

If UNDO_MANAGEMENT is set to AUTO and the UNDO tablespace clause is omitted in the CREATE DATABASE statement, Oracle automatically creates a default undo tablespace named SYS_UNDOTBS. It does not fail, create no tablespace, or put undo in SYSTEM.

Multiple choice technology databases
  1. Only the EMPLOYEES table.

  2. Only the EMPLOYEES table and its corresponding primary key index.

  3. The EMPLOYEES table and partition P1.

  4. The EMPLOYEES table, IPK_EMP index, and the SALES table.

Reveal answer Fill a bubble to check yourself
D Correct answer
Explanation

When you export by tablespace using exp with tablespace=SAMPLE, Oracle exports all database segments stored in that tablespace. This includes tables, indexes, and partitions. The SAMPLE tablespace contains the EMPLOYEES table and its primary key index IPK_EMP (stored separately in INDX but associated with EMPLOYEES). Partition P1 of SALES is also in SAMPLE, so the entire SALES table definition is exported (though only P1's data is in SAMPLE).

Multiple choice technology databases
  1. All of the data files must be from a backup taken prior to the point in time to which you want to recover.

  2. Only the data files belonging from the SYSTEM tablespace must be from a backup taken prior to the point in time to which you want to recover.

  3. Only the data files that need recovery must be from a backup taken prior to the point in time which you want to recover.

  4. Only the data files belonging to the SYSTEM tablespace and the data files that need recovery must be from a backup taken prior to the point in time to which you want to recover.

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

For incomplete recovery, the entire database must be restored to a consistent state prior to the target time. Thus, all restored data files must originate from backups taken before the point-in-time target. Restoring only SYSTEM or a subset of files prevents full consistency.

Multiple choice technology databases
  1. Set the LOG_ARCHIVE_START parameter to TRUE in the initialization parameter file.

  2. Automatic archive is the default when ARCHIVELOG mode is set. No further actions are required.

  3. Set the LOG_ARCHIVE_MAX_PROCESSES parameter to n (where n is the number of Archiver process) in the initialization parameter file.

  4. Immediately after setting the database in ARCHIVELOG mode, in SQL*Plus select automatic archiving using the syntax : ALTER DATABASE SET LOG_ARCHIVE_START=TRUE

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

The LOG_ARCHIVE_START initialization parameter controls automatic archiving of redo log files. Setting it to TRUE in the parameter file enables automatic archiving when the instance starts. Automatic archiving is not the default (option B). LOG_ARCHIVE_MAX_PROCESSES (option C) controls the number of archiver processes, not whether archiving is enabled. Option D incorrectly tries to set LOG_ARCHIVE_START with ALTER DATABASE.