Computer Knowledge
Database and SQL
4,213 Questions
Master structured query language commands, database joins, table constraints, and alias generation. This section covers relational database management concepts and query outputs essential for technical aptitude. These technical questions feature prominently in banking IT officer exams and computer knowledge sections.
SQL queries and aliasesDatabase table constraintsDatabase joins and transformationsStored procedures and functions
Database and SQL Questions
-
Control
-
Alter
-
Delete
-
Insert
C
Correct answer
Explanation
The French verb 'effacer' means 'to delete' or 'to erase' in English. This is a fundamental computing action for removing files or text. Control, alter, and insert are different computer operations, not the meaning of effacer.
-
Create new records in tables
-
Modify the properties of the database objects
-
Change the appearence of the database objects
-
View records in queries
B,C
Correct answer
Explanation
In Design View, you can modify object properties (like field settings, control properties) and change appearance (fonts, colors, layout). Creating new records happens in Datasheet View, and viewing query records is done in Query View results.
-
Table Wizard
-
Primary Key
-
Design View
-
Datasheet View
D
Correct answer
Explanation
Datasheet View in MS Access allows you to create a table by simply typing data into a spreadsheet-like grid. Access automatically creates the table structure and assigns data types based on what you enter. Table Wizard guides you through table creation but requires more steps. Design View is for manually defining fields and properties before data entry.
-
SQL cannot support object-orientation
-
The same query can be written in many ways, each with vastly different execution plans
-
SQL syntax is too difficult for non-computer professionals to use
-
SQL creates excessive locks within the database
B
Correct answer
Explanation
A major problem with SQL is that the same query can be written in multiple syntactically correct ways, each producing vastly different execution plans and performance characteristics. This makes optimization challenging and query performance unpredictable. SQL does support some object-oriented features, the syntax is designed for professionals, and locking behavior is configurable.
-
ROW_NUMBER
-
RANK
-
ROWNUM
-
FIRST_VALUE
C
Correct answer
Explanation
ROWNUM is a pseudocolumn in Oracle that assigns a sequential number to each row retrieved, but it's not an analytical function. ROW_NUMBER, RANK, and FIRST_VALUE are all window/analytical functions that operate over sets of rows in a specific order.
-
Primary key access
-
Access via unique index
-
Table access by ROWID
-
Full table scan
C
Correct answer
Explanation
Table access by ROWID is the fastest method for Oracle to retrieve a single row because ROWID is the physical address of the row in the database. Accessing directly by physical address avoids the overhead of index traversal or scanning multiple rows. Full table scan is the slowest, while primary key and unique index access are faster than full scans but still require index lookup overhead.
-
TPOL_PREM
-
TPOL_COND
-
TPOLICY
-
TPOL_PREMIUM
-
TPREMIUM
A
Correct answer
Explanation
The table used to store premium details of the policy is TPOL_PREM. This follows standard insurance database naming conventions where TPOL prefix indicates policy-related tables. The naming pattern truncates 'premium' to 'PREM' for brevity, similar to how TPOLICY stores general policy information. Other options like TPOL_PREMIUM or TPREMIUM are not the correct table names.
A
Correct answer
Explanation
In SAP systems, PLAF (Planned Order) table stores all details related to planned orders including the creation date. The other tables listed serve different purposes: PLMZ for planned order milestones, PLPO for planned order operations, and PLKO for planned order headers. PLAF is the primary table for planned order master data.
-
Strongly Agree
-
Strongly Disagree
-
Partially correct
-
Not applicable
A
Correct answer
Explanation
PostgreSQL was originally named Postgres as a successor to the Ingres database at UC Berkeley. The name literally means 'after Ingres' (post = after, Ingres = the earlier database). Later SQL capabilities were added, leading to PostgreSQL.
-
MySQL
-
Postgres
-
Both
-
None of these
A
Correct answer
Explanation
MySQL supports unsigned integer datatypes like INT UNSIGNED, BIGINT UNSIGNED which allow only non-negative values and effectively double the positive range. PostgreSQL does not have native unsigned integer types - it uses signed integers with CHECK constraints for similar functionality.
-
YES
-
NO
-
Cannot predict
-
Not applicable
B
Correct answer
Explanation
MySQL is not 100% ACID compliant because ACID properties depend on the storage engine being used. Only InnoDB provides full ACID compliance with transactions, foreign keys, and crash recovery. Engines like MyISAM lack transaction support entirely.
-
Manually: 1 row at a time
-
Through Test Case Bulk Upload Tab
-
Through Test Case Bulk Update Tab
-
All of the above
-
Both 1 and 3
E
Correct answer
Explanation
After Test Cases are inserted into the database, ETP values can be modified either manually (one row at a time) OR through the Test Case Bulk Update Tab. Option B (Bulk Upload) is typically for initial uploads, not updates. Option D is incomplete, and options A, B, C alone are each insufficient.
-
Values cannot be blank
-
Values cannot be zero
-
Values can be blank or zero
-
1 and 2
C
Correct answer
Explanation
The 'Actual ETP' column in Test Case Bulk Upload/Update can contain blank values (for unknown/unestimated cases) OR zero values (for cases with no ETP allocation). Options A and B are incorrect because both blank AND zero are permitted. Option D is incorrect because it suggests both are forbidden, when both are actually allowed.
-
REMOVE FROM CUSTOMER …
-
DROP FROM CUSTOMER …
-
DELETE FROM CUSTOMER WHERE …
-
UPDATE FROM CUSTOMER …
C
Correct answer
Explanation
DELETE FROM is the correct SQL command to remove rows. The syntax requires specifying the table and optionally a WHERE clause. DROP removes entire tables, UPDATE modifies data, and REMOVE is not a valid SQL command.