4D v16

Introduction

Home

 
4D v16
Introduction

Introduction  


 

 

This manual serves as a reference guide for designers, administrators, and users of integrated 4D ODBC PRO. This manual assumes that you are familiar with the overall architecture and capabilities of your ODBC data source and know 4D's procedural language and the functions available in your ODBC driver.

4D is a powerful data management tool for the Macintosh and Windows. Applications developed with 4D ODBC PRO combine the ease-of-use of a graphical interface with the power of a relational database on a microcomputer.

4D ODBC PRO makes it possible to develop applications that take advantage of the strengths of both 4D and the ODBC data source. Using 4D ODBC PRO, data stored in an SQL database can be accessed from 4D.

Open Database Connectivity (ODBC) defines a library of functions that allows an application, such as 4D, to access a Database Management System (DBMS) using Structured Query Language (SQL). The ODBC interface offers vendor-neutral access to different database management system.

The ODBC architecture has four components:
1. the application
2. a driver manager
3. the driver
4. the data source

The main functionalities provided by any ODBC driver include the following:

  • Connecting to and detaching from a DBMS
  • Performing queries and providing storage areas and data formats for query results
  • Allowing for online transaction processing
  • Features external to the ODBC interface (DBMS specific features)
  • The driver manager is a dynamically linked library (DLL) that loads drivers, providing a single entry point to ODBC functions for different drivers.

Note for Macintosh users: Since the Mac OS built-in ODBC library is not fully operational, it is necessary to install a third-party ODBC framework on this platform. Such a framework can be acquired, for example, from Openlink (http://www.openlinksw.com).

This manual reviews the important aspects of accessing a data source using the low level and control commands in 4D ODBC PRO. These closely resemble native Microsoft ODBC API calls in name, syntax and function. More information regarding the MS ODBC API you can find at the following address:

http://msdn.microsoft.com/en-us/library/ms714562(VS.85).aspx

This manual is not intended to provide a detailed analysis of ODBC operations and functionality.

The first step when designing any 4D ODBC PRO application is deciding on what database to connect with. ODBC provides many functions that tell what databases are available, describe what type of databases they are, and establish a connection with them.

An application can be designed with a specific target database in mind. For example, an accounting department might have records stored in an ORACLE database. When designing a purchase order system, they know ORACLE drivers are needed. They also know what types of database this is and what attributes are needed to connect to this database. When an application is designed for a target data source, it is possible to take advantage of specific features offered by the DBMS and driver.

Alternatively, an application might need to be designed to work with any database. It will not know beforehand what driver will be used nor which database to connect with. In this case, developers must use caution to only use those features common to all ODBC data sources.

4D ODBC PRO allows developers to develop applications for either of these two scenarios.

The high-level ODBC commands integrated into the “External Data Source” theme in 4D allow you to implement simple solutions to make your 4D applications communicate with ODBC data sources. For more information regarding the high-level ODBC commands category, please refer to the 4D Language Reference manual.

If your applications require more advanced ODBC features, you should use the “low-level” and control commands located in the 4D ODBC PRO plug-in and described in this documentation.

The various ODBC functions can be broken down into eleven distinct groups. These following groups of routines allow you to interact with a data source at different stages of communication:

  • Connecting to a data source
  • Obtaining information about a driver and data source
  • Setting and retrieving driver attributes
  • Preparing SQL requests
  • Submitting requests
  • Retrieving results and information about results
  • Catalogue functions
  • Terminating a statement
  • Terminating a connection
  • Macro
  • Error handling

 
PROPERTIES 

Product: 4D
Theme: Introduction

 
HISTORY 

 
ARTICLE USAGE

4D ODBC Pro ( 4D v16)