company logo

Database access

Database access works like accessing object instances in an object-oriented environment. The database appears like a huge storage area, which allows accessing data in different ways.

  • typed access - allows referring to property and type names as being defined in the database model. Typed access is supported for OSI and C++.
  • generic access - allows accessing data via property and value handle, which may form hierarchies. Generic access is supported for C#, C++ and OSI.
  • view access - allows accessing (usually derived) data via view definitions and aggregation schemata (C#, C++ and OSI).

C++ and C# APIs provide traditional access interfaces to the database, but there is also a scripting language (OSI), that provides direct access to database. OSI is, syntactically, similar to Java or C++ and nearly as powerful.

Access interfaces

ODABA supports several language interfaces in order to access database content in different ways. Access interfaces are provided for C++ (typed and generic access), C# (generic access) and ODABA Script Interface OSI (typed and generic access).

ODABA also supports mixed implementation classes (C# and OSI or C++ and OSI).


Access handles

Database access functionality is provided via handle classes on different access layers.

  • Dictionary - The dictionary or resource database contains database model definitions, but also GUI design resources and application methods.
  • Database - The data base contains application data. With one dictionary, one may run any number of databases.
  • ObjectSpace - An object space is a well-defined area (scope) within the database, which may contain data for a specific application area (geographical area, client, ...). Object spaces may form hierarchies. The database is the root object space,
  • Property - Properties refer to collections or instances and provide a wide area of access functionality.
  • Value - is, typically, an elementary data item, but may also refer to complex attributes or arrays.

All access layers are supported by appropriate handle classes with the same name. Access handle are the base for generic data access, which is supported in C++, .net and OSI.

Typed access

Typed access allows accessing properties and values by name as being defined in the database model. OSI supports typed access by nature. In order to support typed access in C++, C++ header files may be generated using ODE development tools. C# does not support typed access.

Views and aggregation schemata

Similar to traditional databases, ODABA provides View definitions as well as ad-hoc views (SELECT statement). In contrast to traditional view definitions, elements of the SELECT statements (FROM, WHERE etc.) may also be referenced as operations in an operation path, which allows more flexible view definitions.

Since views support basic aggregation by the GROUP BY operation, only, defining aggregation schemata has been introduced in ODABA just setting an aggregation option in the View definition. Complex aggregation schemata allow providing aggregated data on different aggregation levels.