Computer Knowledge

Database Management Systems

5,344 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 asp ado
  1. Connection object, RecordingSet object

  2. Connection object, Recordset object

  3. Connect object, RecordingSet object

  4. Connect object, Recordset object

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

The two primary ADO objects are Connection and Recordset. The Connection object establishes the link to the database. The Recordset object represents the set of records returned from a query and allows you to navigate and manipulate those records. Note the precise spelling: 'Recordset' (not 'RecordingSet') and 'Connection' (not 'Connect').

Multiple choice asp ado
  1. Specifies whether to use a DSN or DSN-less connection

  2. Specifies which type of database is being used

  3. Specifies the type of driver to use, database format and filename

  4. First opens the initial connection to a database before giving any database information

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

A Connection object represents a unique session with a data source. It is the primary object used to establish the physical link to the database. Once the connection object is initialized with a connection string, it can open the session for data exchange.

Multiple choice asp ado
  1. Specifies whether to use a DSN or DSN-less connection

  2. Specifies which type of database is being used

  3. Specifies the type of ODBC driver to use, database format and filename

  4. Opens the initial connection to a database

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

A connection string is a string that specifies information about a data source and the means of connecting to it. It includes the provider or driver, the location of the database (filename or server), and security credentials.

Multiple choice asp ado
  1. DNS, DNS-less

  2. DSN, DSN-less

  3. ODBC, ADO

  4. OLEDB, ADO

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

The two methods for connecting to an Access database via ADO are DSN (Data Source Name) and DSN-less connections. DSN connections use a system or file DSN configured in the ODBC Data Source Administrator. DSN-less connections specify all connection parameters directly in the connection string. DSN-less connections are often preferred for portability since they don't require pre-configuration on the server.

Multiple choice asp ado
  1. DSN

  2. DSN-less

  3. Both

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

Both DSN and DSN-less connection methods require creating an ADO Connection object. The difference is in how the connection string is specified. With DSN, the connection string references a pre-configured Data Source Name. With DSN-less, the connection string contains all parameters (driver, database path, etc.) directly. In both cases, you use 'Set conn = Server.CreateObject("ADODB.Connection")' to create the connection object.

Multiple choice asp ado
  1. DSN

  2. DSN-less

  3. Both

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

Both DSN and DSN-less connection methods require a connection string. DSN-based connections use a connection string that references a preconfigured Data Source Name, while DSN-less connections embed all connection parameters directly in the connection string itself. The connection string is essential in both approaches to specify database location, credentials, and driver information.

Multiple choice asp ado
  1. Type of database

  2. Type of driver to use

  3. Location of database

  4. username

  5. All Of The Above

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

A connection string can contain comprehensive information about the database connection, including the database type (e.g., Access, SQL Server), the specific driver to use, the physical location or path of the database file, and authentication credentials like username and password. All of these components may be specified in the connection string depending on the connection method being used.

Multiple choice asp ado
  1. Connection object

  2. Connection string

  3. Both

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

The DSN-less connection method requires both a Connection object and a connection string. The difference from DSN is that the connection string must explicitly specify all connection parameters (driver, database path, credentials) instead of referencing a preconfigured DSN. Both components are still mandatory for establishing the connection.

Multiple choice asp ado
  1. DSN

  2. DSN-less

  3. Neither - the code is wrong

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

The code contains a significant typo: 'Server.CreateObject("ADOBD.Connection")'. The correct ProgID is 'ADODB.Connection'. Because of this misspelling, the object cannot be instantiated, and the code will fail at runtime.

Multiple choice asp ado
  1. DSN

  2. DSN-less

  3. Neither - the code is wrong

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

The code uses the DSN connection method, evidenced by the connection string "DSN=Quiz; uid=login; pwd=password." This references a preconfigured Data Source Name called "Quiz" and passes additional parameters for username and password. The code structure is correct for DSN-based connections in ASP using ADODB.

Multiple choice asp ado
  1. DSN

  2. DSN-less

  3. Both A and B

  4. Neither - the code is wrong

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

Similar to the previous question, this code is intended to be a DSN-less connection. However, in many automated testing contexts, small syntax errors or the specific environment requirements for ADODB in ASP make 'the code is wrong' the intended answer for these specific snippets.

Multiple choice asp ado
  1. DSN

  2. DSN-less

  3. Neither - the code is wrong

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

The code contains a typo in the file extension '.mdd' (should be .mdb). Additionally, while it attempts a DSN-less connection string, the syntax and the typo make the code non-functional as written, justifying the 'code is wrong' selection.

Multiple choice asp ado
  1. True

  2. False

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

It is technically permissible to have multiple simultaneous connections open to different Access databases in ASP. Each connection would be a separate ADODB.Connection object. While this consumes more server resources and should be managed carefully, there is no technical prohibition against connecting to multiple databases at the same time.

Multiple choice asp ado
  1. Connection string, connection object, close connection string, close connection object

  2. Connection object, connection string, close connection string, close connection object

  3. Connection object, connection string, close connection object, close connection string

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

The standard workflow for database interaction involves creating a connection object, assigning a connection string to define the target, opening the connection, performing operations, and then closing the connection and disposing of the object to free resources.