Refactoring Databases: Evolutionary Database Design

A collection of database refactoring patterns and database development practices to enable evolutionary database development & Continuous Delivery
  • About Author
  • Praise
  • Book Reviews
  • Amazon Reviews
  • Code Examples
  • Conference Talks
  • Erratum

Architecture Refactoring

  • Add CRUD Methods
  • Add Mirror Table
  • Add Read Method
  • Encapsulate Table With View
  • Introduce Calculation Method
  • Introduce Index
  • Introduce Read Only Table
  • Migrate Method From Database
  • Migrate Method To Database
  • Replace Method(s) With View
  • Replace View With Methods(s)
  • Use Official Data Source

Structural Refactoring

  • Drop Column
  • Drop Table
  • Drop View
  • Introduce Calculated Column
  • Introduce Surrogate Key
  • Merge Columns
  • Merge Tables
  • Move Column
  • Rename Column
  • Rename Table
  • Rename View
  • Replace LOB With Table
  • Replace Column
  • Replace One-To-Many With Associative Tables
  • Replace Surrogate Key With Natural Key
  • Split Column
  • Split Table

Data Quality Refactoring

  • Add Lookup Table
  • Apply Standard Codes
  • Apply Standard Type
  • Consolidate Key Strategy
  • Drop Column Constraint
  • Drop Default Value
  • Drop Non Nullable
  • Introduce Column Constraint
  • Introduce Common Format
  • Introduce Default Value
  • Make Column Non Nullable
  • Move Data
  • Replace Type Code With Property Flags

Referential Integrity Refactoring

  • Add Foreign Key Constraint
  • Add Trigger for Calculated Column
  • Drop Foreign Key Constraint
  • Introduce Cascading Delete
  • Introduce Hard Delete
  • Introduce Soft Delete
  • Introduce Trigger for History

Transformation

  • Insert Data
  • Introduce New Column
  • Introduce New Table
  • Introduce View
  • Update Data

Method Refactoring

  • Parameterize Methods
  • Remove Parameter
  • Rename Method
  • Reorder Parameters
  • Replace Parameter with Explicit Methods
  • Consolidate Conditional Expression
  • Decompose Conditional
  • Extract Method
  • Introduce Variable
  • Remove Control Flag
  • Remove Middle Man
  • Replace Literal with Table Lookup
  • Replace Nested Conditional with Guard Clauses
  • Split Temporary Variable
  • Substitute Algorithm

Talks at conferences

Practices for Agile Database Development at Agile India 2012

Evolutionary Database Design at QCon SF 2011

Database Refactoring at QCon SF 2009

  • © Pramod Sadalage. All rights reserved.
  • Last updated: July 27 2016
  • Design: HTML5 UP