> For the complete documentation index, see [llms.txt](https://help.besmart.software/erpc/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.besmart.software/erpc/en-consultant-manual/imports/imports-of-entities/importing-a-change-command.md).

# Importing a change command

**Use of numbering schemes**

If EcENTITY.name contains only the beginning of the number for Vault - this determines which numbering scheme to use.

The specific number of the newly created CO is logged in the DI as information

**Routing**

* the EcENTITY.category field can optionally be used to determine the routing (Routing) when importing a change command

**Status**

* supported state changes (EcENTITY . lfcycstate\_name field) are:
* * OPEN (change from CREATE)
  * WORK (change from OPEN or CREATE)
  * APPROVED (change from REVIEW)
  * REJECTED (change from REVIEW)
  * CLOSED (change from APPROVED)
* EcENTITY . lfcycstate\_name - both "SystemName" and "DisplayName" can be used\
  (AWS.WorkflowState.Name or AWS.WorkflowState.DispName)
* EcENTITY.lfcycstate\_id is preferred over EcENTITY.lfcycstate\_name

**Import user roles for change commands**

if it is required to import also the roles (functions) of individual users for a given change command, it is necessary to add additional fields to EcENTITY with fixed names according to the role names - here is the complete list:

* EcENTITY.co\_user\_role\_change\_requestor
* EcENTITY.co\_user\_role\_change\_administrator
* EcENTITY.co\_user\_role\_reviewer (Reviewer)
* EcENTITY.co\_user\_role\_approver (Approving)
* EcENTITY.co\_user\_role\_checker (Verifier)
* EcENTITY.co\_user\_role\_responsible\_engineer
* EcENTITY.co\_user\_role\_notification\_user (Notification user)

Conditions:

* the fields do not have to be all, only the roles to be imported are sufficient
* the array must be of type NVARCHAR(x) - length does not matter
* in the ec configuration, these fields do not need to be mapped to a change statement property (this is ensured by a fixed field name in the exchange interface), it is necessary to verify the direction of the mapping
* value translation (Replace) can be used
* The ERP system writes a user name or a list of users separated by one of the following characters:\
  semicolon, slash, pipe (|), tab
* user names must match the name under which the user logs into the Vault\
  (case is not differentiated)
* if the name is not found in the list of Vault users, the import is not stopped, but a comment is added to the change command that the user could not be identified/assigned to the role

**Import comments**

if import of a comment for a given change command is also required, additional fields with fixed names must be added to EcENTITY:

* EcENTITY.co\_msg\_subject\
  optional field - if it does not exist or has no value, "ERP message"\
  is used
* EcENTITY.co\_msg\_text

<br>
