Question:
How to Locate Zip To Terr, Brick To Terr, Account Territory Loader Records Which do not Have Closing Semi-Colon Characters in their Territory_vod__c Fields in Veeva CRM?
Answer:
Consider the Territory_vod__c field value of the following Brick to Terr record:
terr1;terr2;terr3
This value is incorrect, as it is missing the closing semi-colons at the beginning and the end.
The following value is in the correct format:
;terr1;terr2;terr3;
Note #1: This situation is considered a misconfiguration for Zip To Terr and Account Territory Loader records as well. This misconfiguration is required to be resolved, as it may lead to unexpected behavior in the Territory Management features.
The purpose of the article is to provide guidance as to how to retrieve all of the records being in this state. This applies to all three objects.
Follow these steps:
- Using Salesforce Object Query Language (SOQL), retrieve and extract all records containing the id, name, and Territory_vod__c values:
select id, name, Territory_vod__c from Brick_to_Terr_vod__c
- Open the extracted records in Microsoft Excel. Ensure that the formatting of the data is correct. Field names must be in the first columns. In the following example, the Territory_vod__c field is in the D column.
- In an empty column next to the first record, copy and paste the following formula.
=IF((LEFT(D2)=";") * (RIGHT(D2)=";"),"Valid data","Invalid data: List of territories must start and end with ';'")
- Once the records have been retrieved, using concatenation in Microsoft Excel, and Salesforce Data Loading options, the records may be adjusted in CRM.
Note #2: Empty Territory_vod__c values are listed as incorrect records, as it is not recommended to leave Brick to Terr, Zip to Terr, or Account Territory Loader records with empty Territory_vod__c values.
Related Documentation:
CRM Help Documentation:
Knowledge Article: