Behavior Driven Database Development
12 October 2009
When Behavior Driven Development (BDD) was introduced, some of the key principles were
* Requirements are behavior,
* Provides "ubiquitous language" for analysis,
* Acceptance criteria should be executable.
* Design constraints should be made into executable tests.
* Requirements are behavior,
* Provides "ubiquitous language" for analysis,
* Acceptance criteria should be executable.
* Design constraints should be made into executable tests.
All of these principles can be applied to database development. When interacting with the database, we tend to assume certain behavior of the database. Some of this is universal, like when a row is inserted in a table, the same row can later be retrieved. There are other behaviors of the database on every project that are not that universal, like Person table should have at least firstname or lastname. This behavior changes based on the functionality being developed and thus needs to be properly specified and executed. The database lends itself very well to the new way of thinking in the BDD space, where the behavior of the objects is considered. BDD is similar to describing requirements in code.
I am going show how the BDD technique can be applied to database development and how this technique can be used to develop and design databases in an iterative and incremental way.
While designing database objects, we are expecting these objects to behave in a certain fashion and we tend to rely on this behavior. Let's say we make a column NOT NULLABLE. We assume that the database server will throw an exception when a NULL value in inserted in this column. Making the column NULLABLE can alter this behavior of the database. When the behavior of the database is changed this way, all the assumptions that the application made about the database NOT allowing NULL values in the column are no longer true. To avoid these kinds of mistake, we can test the database behavior to assert that the database does throw an exception when NULL values are put in column. In this article I will talk about
* Design a Table
* Design a Primary Key
* Design a Not Null Column
* Design a Constraint on a Column
* Design a Foreign Key Constraint
* Design a Sequence for Object ID
* Design a Unique Index
About the author
Article written by Vimal.
View Company Profile
Articles by this company:
- Free autoresponder services- Why, how and where can you
- Plugin Giving You System Information
- Web Programming Projects
- Web Programming Basics
- 40 Simple Ways to Build Trust in Your Website Visitors
- How To Get Quality Web Content
- Implementing New Technology
- Web 2.0 Concepts to Keep Your Members Coming Back Again
- Behavior Driven Database Development
- Software Development Utilities
- Principles for Usable Design
- How to find Internet Marketing Consultant
- New Product Development
- Best Employment Background Check
- Simple Steps to Safety and Security
- Resolving domain name disputes
- Understanding Cyberstalking
- Resolving domain name disputes
- Web Content, Writing for Web Sites
- Cyber Terrorism & Various Legal Compliances
- Copyright in judgments - Present judicial standing in India
- Data Protection Law In India-Needs And Position
- customer relation
Articles within category
- Advanced Ruby on Rails Development for Web 2.0
- All About The Android app developer
- Tips to Make a Successful App
- The Importance of Hiring a Software Development Company
- The Advantages Of Seeking An Open Source Solution Provider
- Best 5 WordPress Plugins Used in 2011
- Canonical rewrite
- Ecommerce Website Design
- Want to make a web developer cringe ? Say TEMPLATE
- Shopping Cart with Magento Web Development
- Bespoke vs OpenSource & Paid Development Software
- Magento – Best platform for your online Ecommerce store
- HTML5
- Select the right CMS
- Industry trends: Responsive design
- Which CMS? WordPress or Joomla!
- Advantages of Php scripting language
- Comparison between Magento and Zen-Cart Ecommerce System
- Capturing the Manufacturing Industry through Mobile Apps
- Unified v/s Native App Development

