Switch to: V10V9V8V7V6V5

Valentina Data Model

World Concepts in RDBMS

In the relational model, you can operate ONLY by tables that usually are the reflection of OBJECTs of the real world. But there are also properties of objects in the real world, links between objects, actions/events, properties of actions, and so on. RDBMS developers are forced to describe all these concepts using flat tables.

Extending Relational Model

Valentina database is designed to support Relational Model, which is a standard one for the last 10-15 years for DBMS world, and smoothly and naturally extend it to Object-Relational model with the powerful addition of Navigational Model elements! You can read the details at this article.

A key advantage of an object-relational model of Valentina is that it allows you to build databases using the relational model, then add object features when you are ready, much like the migration from programming in C to C++ (or C#).

The main ideas behind Valentina database model are:

  • Data Model should reflect real world concepts as much as possible.
  • The more concepts a DBMS knows and understands the better.

RDBMS:

  • Table with Fields
  • Views
  • Triggers
  • Stored Procedures
  • Indexes as optimization structures

ValentinaDB adds to that:

  • RecID/OID Fields - the base IDs of records to be used on all Valentina DB levels.
  • “Link” abstraction of few kinds:
    • ForeigkKey as the link, instead of as constraint.
    • ObjectPtr link
    • BinaryLink
  • KeyValue Store - as a universal store of Key-Value pairs. It can be integrated to Tables and Links.
  • Properties for Tables, Fields, Links, KeyValues, i.e. to any DB Schema object.

RecID and OID

Each Valentina table has hidden RecID and OID fields. RecID gives a unique identifier of a record in the scope of a table, OID - in the scope of the database.

Mature RDBMS sometimes has an analog of RecID names usually as “rowid”. OO DBMS following ODMG standard does have OID field for objects. But Valentina beat them both in the implementation of this feature!

Let you have a table with million records. RDBMS will eat for rowid 4MB of data + about 12MB of the index. Valentina for RecID eats ZERO Disk/Ram space! For OID field others use 8Mb + about 18MB index, Valentina still uses ZERO Disk/Ram space.

New Abstraction "Link"

Valentina model adds a new revolutionary concept/abstraction the Link. A new Valentina developer couldn`t stay indifferent about that: “How easy! How powerful!”

Links are implemented as on the low level of the engine, so expressed in the public API and, of course, in the SQL. You can find the details about links here.

Another Valentina User has point: Currently, we have in the database (Oracle/Postgre) about 800 tables. Porting them to Valentina we reduce the number of tables to 500.