Using Contexts

4D - Documentation   Français   English   German   English   4D for Oracle, Command Theme List   4D for Oracle, Command Alphabetical List   Back   Previous   Next

version 1.5


The simplest way to use 4D for Oracle to manage the communication of data is to construct contexts. A context is a description in code that defines how the data in 4th Dimension relates to the data in Oracle and that specifies which data should be selected on the Oracle server.

As an example, assume an [Employees] table in 4th Dimension contains the same elements as an EMP table in Oracle. To connect the 4D table and table so data can be transferred between them, you construct a context that binds each field in the [Employees] table with a column in the EMP table.

A bind can be thought of as a link between two related objects.

The following graphic depicts a 4th Dimension table and an Oracle table that are linked by a context. Each column in the EMP table is linked to a field in the [Employees] table through a bind.

When a context is activated, 4D for Oracle generates a SELECT statement that selects a set of rows on the server. If no clauses were added to the context, activating the context selects all of the rows in the table.

These rows can then be loaded into and manipulated in 4th Dimension.


4D - Documentation   Français   English   German   English   4D for Oracle, Command Theme List   4D for Oracle, Command Alphabetical List   Back   Previous   Next