Using the DDF Builder Tutorials
This chapter provides you with two tutorials for using DDF Builder. Each tutorial provides you with basic information as to the structure of the data, a sample scenario in which the file is used, the goal of the tutorial, and the general steps needed to achieve the goals for each exercise.
*Note: Whether you are creating or modifying table definitions with DDF Builder, you must have some knowledge about the structure of your data. It is helpful if you know the column definitions, as well as the offsets and sizes of the fields in the Btrieve file. DDF Builder attempts to guide you with the construction of column definitions, but there are limitations as to how much guidance it can provide.
Tutorial 1 Overview
The first tutorial addresses the situation where you have a Btrieve file without the necessary table definitions needed to provide relational access. Since there are no DDFs for the Btrieve file, you first need to create DDFs. This tutorial steps you through creating a new database with empty DDFs and adding a table definition to them for the Btrieve file.
Working through this tutorial also provides you with some fundamental knowledge for working with the DDF Builder interface. If this is your first time to work with DDF Builder you may want to first become familiar with the interface and where components are located by reviewing Chapter 2, Using DDF Builder.
Tutorial 2 Overview
The second tutorial addresses a bit more complex situation where you modify existing table definitions because they contain outdated or incorrect table definition information. This tutorial steps you through reviewing the existing table definitions and making necessary changes to the DDFs associated with a set of Btrieve files.
The second tutorial is made up of several files and lessons, each focusing on a different issue that you may encounter when trying to modify DDFs using DDF Builder. Some of the issues are automatically addressed by DDF Builder; some require you to make the modifications manually.
Before You Begin
There are only a few things you need to do to start using these tutorials. This section reviews what you need to do to begin using the tutorials in this chapter.
Backup Your Files
Creating or modifying table definitions with DDF Builder alters the structure of your database. As a precaution, you should always back up any files with which you intend to work. This includes both data files and any existing dictionary files.
Although opening your Btrieve files with DDF Builder only makes modifications to your DDFs and not your existing Btrieve files, it is still a good idea to backup all of your files or work from a copy of them. Existing table definitions could potentially be corrupted by a partial edit of the DDFs, leaving your definitions broken and unusable.
*Note: If you intend to make modifications to existing Btrieve files and your DDFs that provide relational access, DDF Builder is not the utility to use. PSQL Control Center allows you to change your DDFs and Btrieve files.

DDF Builder uses IN DICTIONARY calls to write table definitions to the DDFs. The Btrieve file is never written to when using DDF Builder.
Once you have backed up your data files or created a copy from which to work, you are ready to proceed with locating the files used by the tutorials.
Locate the Tutorial Files
The DDF Builder installation created the folders and files on your system for using the tutorials included in this chapter. The tutorial files are installed in the following locations from the default Application Data directory.
<Application Data>\DDFBUILDER\TUTORIALS\TUTORIAL1
<Application Data>\DDFBUILDER\TUTORIALS\TUTORIAL2\V3
<Application Data>\DDFBUILDER\TUTORIALS\TUTORIAL2
*Note: For more information on the default PSQL v12 installation directories, see Where are the PSQL files installed? of Getting Started With PSQL.
Create Data Source Names (DSN)
In order to access the tutorial databases within DDF Builder, you will need to make certain that each database has an associated Data Source Name (DSN) created.
Tutorial 1 walks you through creating a DSN at the time you create the database. This is because in Tutorial 1, you only have a Btrieve file with which to begin, so the database, DDFs and DSN all have to be created from scratch.
Tutorial 2 requires that you create two DSNs in order to see the files and folders within the DDF Builder interface. One DSN points to the Tutorial 2 database and the other points to the V3 database located in the Tutorial2 folder.
The following table lists the options for creating the Tutorial 2 and V3 database DSNs in ODBC Data Source Administrator.
*Tip: If you need help creating a DSN using the ODBC Data Source Administrator, see the PSQL User's Guide for assistance.
Now that you have backed up your files, located the tutorial files, and created your DSNs, you are ready to start Tutorial 1.