Yes, you can run prodict/dump_inc.p which calls into the "Create Incremental DF" Utility from either the command line or from within a procedure. This procedure uses environmental variables to answer questions that are asked during the execution of the regular utility.
This is a batch incremental .df utility. The databases that it uses have the following aliases defined:
DICTDB - current database (first connected database, "master")
DICTDB2 - database chosen to compare against (second connected database, "slave")
Environment Variables:
DUMP_INC_DFFILE : name of file to dump to
DUMP_INC_CODEPAGE : output codepage
DUMP_INC_INDEXMODE : index-mode for newly created indexes allowed values are: "active", "inactive"
DUMP_INC_RENAMEFILE : name of the file with rename definitions
DUMP_INC_DEBUG :debug-level:
0 = debug off (only errors and important warnings)
1 = all the above plus all warnings
2 = all the above plus config info
Code-page - support:
code-page = ? :cpstream = UNDEFINED*
code-page = "" : cpstream = (SESSION:STREAM)
code-page = "<code-page>" : cpstream will either be SESSION:STREAM or UNDEFINED (*)
(*) Undefined code page is a special code page which tells Progress not to do any conversion when reading or writing data. As long as there are only ASCII characters this is not a problem but if there are any non-ASCII characters, you run the risk of corrupting them.
Rename object support.The rename file environmental variable is used to identify tables, database fields and sequences that have changed names.
The format of the file is a comma separated list that identifies the renamed object, its old name and the new name.
When an object is found missing, this file is checked to determine if it was renamed.
If a matching entry is found, then the object is renamed.
If rename file is “?” Or "" or object not in the file, the missing object is deleted.
The rename file has the following format:
T,<old-table-name>,<new-table-name>
F,<table-name>,<old-field-name>,<new-field-name>
S,<old-sequence-name>,<new-sequence-name>
Example of a UNIX script setting up the environment and running the utility:
#!/bin/sh
DUMP_INC_DFFILE=/tmp/delta.df
DUMP_INC_CODEPAGE=iso8859-2
DUMP_INC_INDEXMODE=active
DUMP_INC_RENAMEFILE=/tmp/master.rf
DUMP_INC_DEBUG=2
export DUMP_INC_DFFILE DUMP_INC_CODEPAGE
DUMP_INC_INDEXMODE \
DUMP_INC_RENAMEFILE DUMP_INC_DEBUG
$DLC/bin/_progres -b -db master \
-db slave \
-p prodict/dump_inc.p > /tmp/dump_inc.log.Example of a WINDOWS batch setting up the environment and running the utility:@echo off
set DUMP_INC_DFFILE=D:\wrk\delta.df
set DUMP_INC_CODEPAGE=1252
set DUMP_INC_INDEXMODE=active
set DUMP_INC_RENAMEFILE=D:\wrk\renamefile.rf
set DUMP_INC_DEBUG=0
%DLC%/bin/_progres -b -db master -1 -db slave -1 -p prodict/dump_inc.p > D:\wrk\dump_inc.log.
echo End Of Dump Delta Definition File Note: In the above scripts, the database connection parameters can be any valid connection string. This includes specifying
-H -S if either (or both) databases are running on other hosts than the machine where the
prodict/dump_inc.p runs, and using
-ld to specify a logical name if the databases have the same physical name.