DigiTransact · Vibe Coding Academy

DEVELOPMENT WORKBOOK

Database development prompts

Work through 14 database development tasks. Open a brief to see its worked example, customise the variables and copy the completed prompt.

← All categories
Version a school marking rubric Advanced

Preserve the grading criteria used for each submission.

Recommended tools: OpenAI Codex or Claude Code

Complete prompt

Model the records and integrity rules for {{project}}. Preserve the grading criteria used for each submission.

Use this case: {{scenario}}. Clarify any missing policy before choosing defaults. Deliver a schema sketch, constraints and synthetic sample rows. Explain transaction boundaries and demonstrate one rejected invalid change.

Acceptance criterion: {{criterion}} Explain how a reviewer can independently check it.

Expected output

A schema sketch, constraints and synthetic sample rows. Paper A still resolves to rubric v1.

Worked example

Input: rubric v2 introduced after paper A was graded.
Passing result: Paper A still resolves to rubric v1.

Common mistakes

Follow-up prompts

Link to this prompt
Represent overlapping room bookings Advanced

Prevent conflicting confirmed appointments for one room.

Recommended tools: OpenAI Codex or Claude Code

Complete prompt

Model the records and integrity rules for {{project}}. Prevent conflicting confirmed appointments for one room.

Use this case: {{scenario}}. Clarify any missing policy before choosing defaults. Deliver a schema sketch, constraints and synthetic sample rows. Explain transaction boundaries and demonstrate one rejected invalid change.

Acceptance criterion: {{criterion}} Explain how a reviewer can independently check it.

Expected output

A schema sketch, constraints and synthetic sample rows. A second confirmed booking starting 09:30 is rejected.

Worked example

Input: Room 3 already booked 09:00–10:00.
Passing result: A second confirmed booking starting 09:30 is rejected.

Common mistakes

Follow-up prompts

Link to this prompt
Keep double-entry journals balanced Advanced

Require each posted journal to sum to zero in one currency.

Recommended tools: OpenAI Codex or Claude Code

Complete prompt

Model the records and integrity rules for {{project}}. Require each posted journal to sum to zero in one currency.

Use this case: {{scenario}}. Clarify any missing policy before choosing defaults. Deliver a schema sketch, constraints and synthetic sample rows. Explain transaction boundaries and demonstrate one rejected invalid change.

Acceptance criterion: {{criterion}} Explain how a reviewer can independently check it.

Expected output

A schema sketch, constraints and synthetic sample rows. The incomplete journal cannot be posted.

Worked example

Input: debit 40 GHS and credit 35 GHS.
Passing result: The incomplete journal cannot be posted.

Common mistakes

Follow-up prompts

Link to this prompt
Record produce in mixed units Advanced

Store canonical quantities and explicit conversion factors.

Recommended tools: OpenAI Codex or Claude Code

Complete prompt

Model the records and integrity rules for {{project}}. Store canonical quantities and explicit conversion factors.

Use this case: {{scenario}}. Clarify any missing policy before choosing defaults. Deliver a schema sketch, constraints and synthetic sample rows. Explain transaction boundaries and demonstrate one rejected invalid change.

Acceptance criterion: {{criterion}} Explain how a reviewer can independently check it.

Expected output

A schema sketch, constraints and synthetic sample rows. The canonical stock increment is 50 kg with the source unit retained.

Worked example

Input: two sacks of 25 kg.
Passing result: The canonical stock increment is 50 kg with the source unit retained.

Common mistakes

Follow-up prompts

Link to this prompt
Retire a catalogue item Advanced

Keep historical order lines readable after product withdrawal.

Recommended tools: OpenAI Codex or Claude Code

Complete prompt

Model the records and integrity rules for {{project}}. Keep historical order lines readable after product withdrawal.

Use this case: {{scenario}}. Clarify any missing policy before choosing defaults. Deliver a schema sketch, constraints and synthetic sample rows. Explain transaction boundaries and demonstrate one rejected invalid change.

Acceptance criterion: {{criterion}} Explain how a reviewer can independently check it.

Expected output

A schema sketch, constraints and synthetic sample rows. An earlier order still displays its purchased description.

Worked example

Input: item K removed from sale.
Passing result: An earlier order still displays its purchased description.

Common mistakes

Follow-up prompts

Link to this prompt
Store effective-dated fares Advanced

Select the fare that applied on the travel date.

Recommended tools: OpenAI Codex or Claude Code

Complete prompt

Model the records and integrity rules for {{project}}. Select the fare that applied on the travel date.

Use this case: {{scenario}}. Clarify any missing policy before choosing defaults. Deliver a schema sketch, constraints and synthetic sample rows. Explain transaction boundaries and demonstrate one rejected invalid change.

Acceptance criterion: {{criterion}} Explain how a reviewer can independently check it.

Expected output

A schema sketch, constraints and synthetic sample rows. A Sunday trip still prices at GHS 4.

Worked example

Input: fare changes from GHS 4 to GHS 5 on Monday.
Passing result: A Sunday trip still prices at GHS 4.

Common mistakes

Follow-up prompts

Link to this prompt
Track partial deliveries Advanced

Distinguish ordered, received and outstanding quantities.

Recommended tools: OpenAI Codex or Claude Code

Complete prompt

Model the records and integrity rules for {{project}}. Distinguish ordered, received and outstanding quantities.

Use this case: {{scenario}}. Clarify any missing policy before choosing defaults. Deliver a schema sketch, constraints and synthetic sample rows. Explain transaction boundaries and demonstrate one rejected invalid change.

Acceptance criterion: {{criterion}} Explain how a reviewer can independently check it.

Expected output

A schema sketch, constraints and synthetic sample rows. The outstanding delivery query returns four cartons.

Worked example

Input: ordered 12 cartons; received 8.
Passing result: The outstanding delivery query returns four cartons.

Common mistakes

Follow-up prompts

Link to this prompt
Prevent cycles in reporting lines Advanced

Reject managerial assignments that loop back to the employee.

Recommended tools: OpenAI Codex or Claude Code

Complete prompt

Model the records and integrity rules for {{project}}. Reject managerial assignments that loop back to the employee.

Use this case: {{scenario}}. Clarify any missing policy before choosing defaults. Deliver a schema sketch, constraints and synthetic sample rows. Explain transaction boundaries and demonstrate one rejected invalid change.

Acceptance criterion: {{criterion}} Explain how a reviewer can independently check it.

Expected output

A schema sketch, constraints and synthetic sample rows. The proposed link is rejected without changing the existing reporting line.

Worked example

Input: A reports to B; assign B to A.
Passing result: The proposed link is rejected without changing the existing reporting line.

Common mistakes

Follow-up prompts

Link to this prompt
Assign unique library copies Advanced

Separate the bibliographic title from physical copy identifiers.

Recommended tools: OpenAI Codex or Claude Code

Complete prompt

Model the records and integrity rules for {{project}}. Separate the bibliographic title from physical copy identifiers.

Use this case: {{scenario}}. Clarify any missing policy before choosing defaults. Deliver a schema sketch, constraints and synthetic sample rows. Explain transaction boundaries and demonstrate one rejected invalid change.

Acceptance criterion: {{criterion}} Explain how a reviewer can independently check it.

Expected output

A schema sketch, constraints and synthetic sample rows. Borrowing copy C2 leaves C1 and C3 available.

Worked example

Input: three copies share one ISBN.
Passing result: Borrowing copy C2 leaves C1 and C3 available.

Common mistakes

Follow-up prompts

Link to this prompt
Preserve an address snapshot Advanced

Decouple delivery history from profile edits.

Recommended tools: OpenAI Codex or Claude Code

Complete prompt

Model the records and integrity rules for {{project}}. Decouple delivery history from profile edits.

Use this case: {{scenario}}. Clarify any missing policy before choosing defaults. Deliver a schema sketch, constraints and synthetic sample rows. Explain transaction boundaries and demonstrate one rejected invalid change.

Acceptance criterion: {{criterion}} Explain how a reviewer can independently check it.

Expected output

A schema sketch, constraints and synthetic sample rows. The dispatched order keeps the former delivery address.

Worked example

Input: customer moves after order dispatch.
Passing result: The dispatched order keeps the former delivery address.

Common mistakes

Follow-up prompts

Link to this prompt
Build a priority waitlist Advanced

Resolve tied application timestamps with deterministic ordering.

Recommended tools: OpenAI Codex or Claude Code

Complete prompt

Model the records and integrity rules for {{project}}. Resolve tied application timestamps with deterministic ordering.

Use this case: {{scenario}}. Clarify any missing policy before choosing defaults. Deliver a schema sketch, constraints and synthetic sample rows. Explain transaction boundaries and demonstrate one rejected invalid change.

Acceptance criterion: {{criterion}} Explain how a reviewer can independently check it.

Expected output

A schema sketch, constraints and synthetic sample rows. Repeated queries return the same documented tie order.

Worked example

Input: applications K and M arrive simultaneously.
Passing result: Repeated queries return the same documented tie order.

Common mistakes

Follow-up prompts

Link to this prompt
Merge duplicate supplier records Advanced

Redirect references while preserving invoice lineage.

Recommended tools: OpenAI Codex or Claude Code

Complete prompt

Model the records and integrity rules for {{project}}. Redirect references while preserving invoice lineage.

Use this case: {{scenario}}. Clarify any missing policy before choosing defaults. Deliver a schema sketch, constraints and synthetic sample rows. Explain transaction boundaries and demonstrate one rejected invalid change.

Acceptance criterion: {{criterion}} Explain how a reviewer can independently check it.

Expected output

A schema sketch, constraints and synthetic sample rows. Both historic invoices resolve to one supplier without losing original references.

Worked example

Input: supplier A and A Ltd are confirmed identical.
Passing result: Both historic invoices resolve to one supplier without losing original references.

Common mistakes

Follow-up prompts

Link to this prompt
Represent missing sensor readings Advanced

Keep zero separate from unavailable measurements.

Recommended tools: OpenAI Codex or Claude Code

Complete prompt

Model the records and integrity rules for {{project}}. Keep zero separate from unavailable measurements.

Use this case: {{scenario}}. Clarify any missing policy before choosing defaults. Deliver a schema sketch, constraints and synthetic sample rows. Explain transaction boundaries and demonstrate one rejected invalid change.

Acceptance criterion: {{criterion}} Explain how a reviewer can independently check it.

Expected output

A schema sketch, constraints and synthetic sample rows. The average includes noon but excludes the missing observation.

Worked example

Input: meter reads zero at noon; missing at one.
Passing result: The average includes noon but excludes the missing observation.

Common mistakes

Follow-up prompts

Link to this prompt