O'Reilly logo

Agile Database Techniques: Effective Strategies for the Agile Software Developer by Scott Ambler

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 14. Mapping Objects to Relational Databases

You are playing a losing game if you need to "use a stick" to motivate someone to do things your way.

Most modern business application development projects use object technology, such as Java or C#, to build the application software and relational databases to store the data. This isn't to say that you don't have other options; there are many applications built with procedural languages such as COBOL, and many systems will use object databases or XML databases to store data. However, because object and relational technologies are by far the norm that's what I assume you're working with in this chapter. If you're working with different storage technologies then many of the concepts are still applicable, albeit with modification (Chapter 22 provides an overview of mapping issues pertaining to objects and XML).

In Chapter 7, I discussed the impedance mismatch between object and relational technology, both of which are technologies that project teams commonly use to build software-based systems. It is quite easy to overcome this impedance mismatch; the secret to doing so is twofold: you need to understand the process of mapping objects to relational databases, and you need to understand how to implement those mappings. In this chapter, the term mapping will be used to refer to how objects and their relationships are mapped to the tables, and the relationships between them in a database. As you'll soon find out, it isn't quite as straightforward ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required