BolEnglishLearn · Play · Win
Login

⚖️ Software Design & Architecture · Architecture Evaluation Factors

⚖️

Data Integrity

Quality AttributeCoreModule 1

Keeping data accurate, consistent, valid, and complete.

The system should prevent impossible or contradictory data states.

💡 In practice

An order cannot be marked Paid unless a valid payment transaction exists.

🖼️ CONCEPT PICTURE
A picture to help remember Data Integrity
An order cannot be marked Paid unless a valid payment transaction exists.

💡 Like a ledger that must always balance — the system refuses entries that don't add up.

💡 Learn🛠️ Apply🎯 Check

💡 Why it matters

Data is the business's memory. If it becomes wrong or contradictory, reports lie, decisions go bad, and trust is lost. Integrity keeps data accurate, consistent and valid.

🛠️ How to achieve it

1
Enforce rules at the data layer
Use constraints, required fields and foreign keys so bad data can't be saved.
2
Use transactions
Group related changes so you never get a half-updated state.
3
Validate before writing
Check that values make sense (ranges, formats, relationships) before persisting.

⚠️ Signs of trouble

  • •Reports don't reconcile or contradict each other.
  • •Records exist in impossible states (e.g., Paid with no payment).
  • •Orphaned or duplicate records pile up.
⚠️ Common mistake: Enforcing rules only in the UI or one screen, so another path (import, API, job) quietly writes invalid data.

🎯 Quick check

Score: 0/2

Three questions to test the idea.

  1. 1. Data integrity mainly keeps data…

    Answer: Accurate, consistent, valid and complete

    Integrity is about correctness and consistency of the data itself.

  2. 2. The safest place to stop an order being 'Paid' without a payment is…

    Answer: At the data layer, so every path obeys it

    Rules at the data layer apply to every path — UI, API, imports and jobs alike.

🔑 Key terms

Constraint
A rule the data must obey.
Transaction
An all-or-nothing change.
Validation
Checking values before saving.
Referential integrity
Links between records stay valid.

✅ Review checklist

📊 Your progress

0%
Mark this topic learned to track it.
Saved in this browser.
🚀 Got it?
Mark it learned and move to the next topic.
Next topic →