Skip to content

Excluding Fields From Replication

Steve Ives edited this page Dec 2, 2019 · 2 revisions

If there are fields in a replicated record that you do not wish to include as columns in the database then you can mark those fields to be excluded from processing by adding the special text REPLICATOR_EXCLUDE in the fields user-defined text or long description in the repository, and then re-generating the code. Note that this special token is case sensitive, it must be declared exactly as shown, in upper case.

There are several reasons to exclude fields from replication, including but not limited to:

  1. Excluding sensitive or unreadable information from the database.
  2. Improving the performance of the replication environment (fewer columns results in improved performance).

IMPORTANT: It is not possible to exclude any field that is used as a segment in any access key. Attempting to do so will cause warning messages to be output to the generated code, which will in turn cause the code to fail to compile. These warning messages appear at the top of the generated source file and look like this:

*****************************************************************************
CODE GENERATION EXCEPTIONS:

Field EMP_ADDRESS_STATE may not be excluded via REPLICATOR_EXCLUDE because it is a key segment!
Clone this wiki locally