Data Dictionaries

Data Dictionaries

Image courtesy of Infocux Technologies

The Data Dictionary concept employed by DataFlex is an outstanding contribution to application development and maintenance, and one that is not often found unless developed as part of a particular project or by an individual development house for their own purposes.

In DataFlex, an application’s business rules are defined in and managed by “Data Dictionaries”.
A data dictionary is defined as – the business layer that stands between your table on disk and the requested operation at runtime. It handles the find, clear, save, validate, and delete requests from either the programmer or the user. Data Dictionaries are defined as DataFlex classes. You create a Data Dictionary class for each table in your database. These classes will be used while you build your application and when you run your application.

Data Dictionaries are a middle tier between your application’s user interfaces. Advantages:

•    Efficient database interaction – Data Dictionaries provide your application with a wealth of application-related information about your database that is not part of your physical database
•    Protected data – Data Dictionaries validate all database updates to make sure that only the correct information is created, changed or deleted
•    Centralised application logic to reduce application maintenance and programming errors
•    Data Dictionary defined application logic is available to DF Windows applications, DF Web Applications, and via Web services to any applications regardless of development language or operating system

Using Data Dictionaries while Building a DataFlex Application – Windows or Web based
During development, the DataFlex Studio will automatically use the information in your Data Dictionary classes to assist in the development process. This is used when you build Windows entry views, Reports, Web application views presented via web pages, and as functions passed via Web Services messages. The Studio and its wizards will use the Data Dictionaries to determine:

•    What tables should be opened and how they should be connected
•    What kinds of controls should be used for a particular field (e.g., form, checkbox)
•    What the labels and context help text should be used for your controls
•    When lookup lists should be used, how they should be used, and how they will look (In web applications, they manage the efficient population of these to provide lookup features usually available in a Windows desktop application).

Properly defined Data Dictionaries make it easy to rapidly create good looking, consistent, reliable and maintainable Windows applications, Web Applications and Web Services.