O'Reilly logo

NHibernate 3 Beginner's Guide by Gabriel N. Schenker

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

Relations, constraints, and indices

So far, we have seen that a relational database allows us to organize our data into different tables. To bring even more structure to how the data is stored and what data is stored, relational databases use constraints and relations. Furthermore, we can define indexes to optimize the access of the data.

Relations

Relations are used to associate data in different tables. Only through these relations, data stored in a database has some business-relevant meaning. Otherwise, the data would just be a bunch of unrelated sets of facts. Relational databases are called relational due to this fact that the data is related among different tables.

As an example, let's look at the connection between the data of a customer and ...

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