Complete use of relational databases

Referential integrity and foreign keys

All the tables are linked with referential integrity (foreign keys).
In this way the data integrity is guaranteed by the database itself, ensuring the most reliable data consistency.

ID primary keys

Some old projects still rely, to connect one table to another, on the use of the code columns. For example, the stock item code may be used to connect document lines, stock transactions and so on.

In X-Cross, all the primary keys are automatically generated integer ID columns (4 or 8 bytes). In this way, the explicit codes inserted by the user can be changed (if permitted) at any time, and the reading speed of complex views is maximized.

Calculations and procedures in the database

In X-Cross, the operations to update the database (for example the recalculation of the stock inserting a transaction) are executed using the native language of the database (SQL), and are linked to the occurrence of certain events (insert, update or delete of records), through database triggers and stored procedures.
This, compared to the indirect execution of procedures (i.e. by the client computer connected to the database), is 100-200 times faster, and gives a much better data security.

Benefits for the users:

Insert and update with procedures

The inserts and updates in the database tables are performed with stored procedures.

In this way the calculations that are required writing the data (remove nulls, checking foreign keys, etc.) are performed directly in the database server, with maximum efficiency and operations speed, and this also allows to insert and update in the complex views.

These procedures are created automatically, but they can be integrated with custom programming lines to perform specific tasks.

Transactional database updates

Complex database updates, even if they involve multiple tables, are contained in a single transaction.

This means that if something goes wrong, the whole operation is canceled, as if it had never been executed.

If for any reason the connection is interrupted during a complex operation, or even in the case that the database server itself crashes, the data structure does not suffer any damage and is also internally consistent. In fact the updates performed are “all or nothing”, that is, either everything is successful or the database is not modified at all, however reporting the error.

Cross SQL

CrossModel includes its own proprietary SQL code editor, that drastically reduces development times over the traditional text-based SQL editors.

Multi-level object data structure

The “operational objects” on which the user really works often do not refer to a single database table, but have a much more complex data structure, which includes multiple tables related to each other (“relational database”).

For example, an accounting entry is constituted of several tables linked together, of which this is a simplified representation.

Similarly to the accounting entry, an invoice is composed of at least one header and one or more lines; in practice, the tables involved are many more; for example we can have expenses, subtotals, commissions, lots, etc.

The same is true for many other structures of a management software.

A peerless data structure

The data structure, the base of every ERP, thanks to CrossModel and its advanced data modeling features is extremely complete, to store all the information that a company may need.

For example, a quotation line is made of 227 editable columns in the table (in reality it is a complex view), and 523 columns including the read-only columns (belonging to 70 different connected tables) of the line view.

Complete but lightning fast

Even with this incredibly complete data structure (automatically generated by CrossModel), the read-write times are extremely low: for example, a whole quotation with 86 lines is read (on the Internet) in about 0.3 seconds. It must be considered that, in these times, not only the header and the lines of the quotation are read, but a total of 26 tables in addition to the header.