#### 4.3.4 Checking for duplicate IDs

To be absolutely certain there are no duplicate IDs, by default DITA2Go conducts a duplicate-name check, and if any duplicates are found, modifies the IDs involved for uniqueness. To prevent the check for duplicates:

[IDOptions]
; DuplicateNameCheck = Yes (default, check for duplicate topic and
; output file names, and modify IDs for uniqueness) or No (no check)
DuplicateNameCheck=No

When DuplicateNameCheck=Yes, you can specify the format and length of a sequence number to be added to IDs as a suffix:

[IDOptions]
; UniqueNameSuffixFormat = Format string used by sprintf to add a
; unique suffix, where the int argument is a sequence number (1-999)
UniqueNameSuffixFormat = X%0.3d
; UniqueNameSuffixLength = length in bytes of the unique suffix
UniqueNameSuffixLength = 4

Theoretically, just the elements with duplicate IDs get suffixes. In practice, you might see many other elements with (for example) an X001 ID suffix even though no matching ID with an X002 suffix is present. That is because DITA2Go has to distinguish duplicates before determining whether the IDs involved are referenced. If one of them is not referenced, that ID might not be included in output.

Previous Topic: 4.3.3 Specifying a prefix for bookmarks in RTF output

Next Topic: 4.4 Processing graphics

Parent Topic: 4.3 Identifying files and elements

Sibling Topics:

4.3.1 Generating document-wide unique IDs

4.3.2 Specifying building blocks for unique IDs

4.3.3 Specifying a prefix for bookmarks in RTF output

Table of Contents • Index