Data storage and database structure — MCQs

On this page

8 questions
3 chapters
Q1Medium

A payment may be applied to several invoices, and an invoice may be settled through several payments. The PaymentApplication table contains PaymentID, InvoiceID, and AmountApplied. Which database constraint would best prevent the same payment from being applied twice to the same invoice while permitting both types of multiple relationships?

Q2Medium

An accounting database stores products in a Product table and historical invoice lines in an InvoiceLine table. Management must retain all invoice lines, prevent them from referring to nonexistent products, and stop users from selecting discontinued products on new invoices. Which design best meets these requirements?

Q3Medium

A normalized purchasing database must record that each product may be supplied by several suppliers and each supplier may provide several products. The database must also store the negotiated unit price for each product-supplier combination. Which table design is most appropriate?

Q4Medium

An employee training table stores EmployeeID, CourseID, CourseTitle, CourseInstructor, CompletionDate, and Score. A course's instructor name therefore appears on hundreds of training rows, and recent updates changed only some of those rows. Which redesign would best prevent this update anomaly while preserving the relationship between courses and training records?

Q5Medium

An ERP permits each general ledger account to be assigned to several management-reporting categories, and each reporting category may contain several accounts. Which relational design most appropriately represents these assignments without storing repeating category values in the account table?

Q6Medium

An entity must be able to determine which approved vendor bank account was in effect when each electronic payment was released. The current vendor table overwrites the prior bank account whenever a change is approved. Which database design best supports this requirement?

Q7Medium

A relational accounting database stores an Account table and a JournalEntryLine table whose AccountID field references the Account table. Management wants users to deactivate obsolete accounts while preserving historical journal-entry relationships. Which database design best satisfies this objective?

Q8Hard

An employee-assignment table contains EmployeeID, EmployeeName, ProjectID, ProjectName, and ProjectManager. ProjectName and ProjectManager depend on ProjectID rather than on EmployeeID. If the last employee assigned to a project is removed from the table, all information about that project's name and manager is lost. Which redesign best reduces this deletion-anomaly risk?

Want unlimited practice?

Get full access to all questions, explanations, and performance tracking.

Start For Free
75% OFFLimited time offer
GET 75% OFF