KBA-01530: Overview of DocCopyConfig Rule Group

Overview:

The DocCopyConfig rules control various optional behaviors when one document is copied to create another document.

The DocCopyConfig rule group is found in the Rules Maintenance tool on the System Admin Dashboard. Each rule in the rule group consists of a rule name, a filter value (which can be blank) and a result value.


Filter Values:

Any Doc type

The DocCopyConfig rules accept any Doc type (as defined in the Doc Types tool and appearing on the filter drop-down) as the filter value.


Result Values:

Varies

Result values for the DocCopyConfig rules depend on the rule and are indicated within the description of each rule.  Several result values are filters that use .NET Data Column expression syntax. Some rules are enabled and disabled through a checkbox in the result value, for example:

Rule showing checkbox result value


Rules:

AddrFilter

Specifies (in the result value) a Boolean expression that references fields in the xsfDocAddr table. For example,

  • AddrType in (‘S’,’V’) = copy only the specified address types, if present.
  • False = do not copy any address rows (default).
  • True = copy all Address rows to the new document. Note: if the address type already exists on the new document, the source address is not copied.

AllItemFolders

Specifies (in the result value checkbox) if all item folder should be copied, even when empty.  The default is to copy only folders that have items.

  • unchecked = do not copy empty folders (default)
  • checked = copy all folders, even if empty

AttachedTemplates

Specifies (in the result value) how attached templates are copied (if that the file passes the AttachmentFilter rule below)

  • Auto = clone the template; bookmarks now refer to the new document (default).
  • 0 = do not copy a bookmark-based document. (This is the best choice for Auto-Attach scenarios that start with a fresh copy from the template library).
  • 1 = copy the link to the same attached file.  Bookmarks will not be refreshed from the new document.

AttachmentCloning

Specifies (in the result value) a list of file types separated by semicolons that should be cloned when copied.  A cloned file starts with the same content as its source, but has its own version and access history.  Future changes made to the original source will not be reflected in the clone and changes to the clone will not be reflected in the original. Note that templates with bookmarks are handled by the AttachedTemplates rule (above) even if this is set to disabled, and that only files passing the AttachmentFilter rule (below) are subject to cloning by this rule.

  • 0 = disabled (default).
  • docx = clone all Microsoft Word .docx files.
  • xlsx;xlsm = clone all Microsoft Excel .xlsx and .xlsm workbooks.
  • docx;xlsx = clone all Microsoft Word and Excel .docx and .xlsx files.

AttachmentFilter

Specifies (in the result value) a boolean expression that references fields in the xsfFileAttach table, for example,

  • True = include all (default).
  • False = exclude all.
  • MailRoute=’P’  = include only attachments that are PDF files.
  • DocKey IS NOT NULL = include only files (by excluding attached documents).

AttendeeDupCheck

Specifies (in the result value) a .NET Data Table filter expression that references fields in the xsfMeetingAttendee table used to determine if there is a duplicate attendee in the target document. To totally disable duplicate checking, use FALSE as the result value. The default is ((UserKey is NULL and AttendeeName = {2}) or UserKey='{0}’) AND LinkedItemKey IS {1} NULL where

  • {0} represents the user key of the candidate row.
  • {1} represents the word NOT if the candidate row is not linked to an item.
  • {2} represents the freeform name of the candidate row.

AttendeeFilter

Specifies (in the result value) a Boolean expression that references fields in the xsfMeetingAttendee table. For example,

  • False = do not copy any attendee rows to the new document.
  • IsRegular = copy only attendees marked as Regular to the new document (default).
  • True = copy all attendee rows to the new document.

AttributeFilter

Specifies (in the result value) a Boolean expression that references fields in the xsfAttribute table. For example,

  • AttrType in (‘OK’,’VV’) = copy only rows with the indicated Attribute types.
  • False = do not copy any attributes (default).
  • True = copy all attribute rows to the document.

CommentFilter 

[V2019+] Specifies (in the result value) a Boolean expression that references fields in the xsfComment table. For example,

  • ISNULL(Note,’Reviewed’) <> ‘Reviewed’ and ISNULL(Cost,0) <> 0  = copy only rows with a note and cost.
  • False = do not copy any comments (default).
  • True = copy all comment rows to the new document.

DateFilter

Specifies (in the result value) a boolean expression that references fields in the xsfDocDate table, for example,

  • True = include all .
  • False = exclude all (default).

FieldList

Specifies (in the result value) the semicolon-separated list of field names to be processed from the source document to the target document in a manner that differs from the default. By default, all fields are copied to the target document from the same fields in the source document. This rule allows you to blank out (not copy) specific fields and to copy the contents of a source field to a different field on the target document. The syntax is targettable.field = sourcetable.field (so, for example, DocRevision.NoteB=DocRevision.NoteA would copy NoteA from the source document to NoteB in the target document). When sourcetable is omitted, DocMasterDetail is assumed. When targettable is omitted, the source table is assumed.  Other possible tables are DocRevision and DocRoute (for first route only).
Note: Because the Docno, Due, Closed, Title, and Status fields are further processed by sfPMS after a document copy, we recommend these fields not be included in the FieldList rule.

  • targettable.field = sourcetable.field = copy the field in the source document to the specified field in the target document.
  • targettable.field = NULL = make the field blank in the target document.

ItemStatusReset

Specifies (in the result value checkbox) if the Item status should be reset on the copied items.

  • unchecked = No, do not reset Item statuses.
  • checked = Yes, reset Item statuses (default).
    • Status is set to O by default, or value from DocItemConfig | ResetItemStatusTo
    • Due is set to null if it is in the past
    • Quanity is reset to zero [v2018]

IXFilter

Specifies (in the result value) a Boolean expression that references fields in the xsfInclusion table. For example,

  • False = do not copy any rows in the Incl/Excl tab (default).
  • ItemType in (‘E’,’A’) = copy only exclusions and legal attachments, if present.
  • ItemType = ‘I’ and Paragraph LIKE ‘T%’ = copy inclusion lines with any paragraph starting with T.
  • Paragraph in (‘aaa’,’222′) = copy only paragraphs aaa and 222.
  • True = copy all rows in the Incl/Excl tab.

Additional Comments:

See also the DocItemConfig and DocTypeConfig rule groups.  Over time, copy-related rules are migrating from various legacy rule groups into this rule group.

See also the NextDocFlow rule group.


KBA-01530; Last updated: November 23, 2020 at 21:23 pm green text = new