Question
Depending on the Address Line, Loqate will cleanse the address and in the Delivery Address attribute, it concatenates Address Line 1 and Address Line 2. In some cases, a <BR> is placed between those address lines in the concatenation..
Address Line 1 = '600 Site' Address Line 2 = 'Gd 157 Stn Main' and
Delivery Address = '600 Site<BR>Gd 157 Stn Main'
Answer
When Loqate processes address data, it formats the delivery address according to the postal standards of the relevant country. In some cases, the concatenation of AddressLine1 and AddressLine2 includes a <BR>
tag, which represents a line break in HTML. The server option influences this behavior.
By default, the AddressLineSeparator
is set to <BR>
, resulting in line breaks between address components when rendered in HTML. However, this separator can be customized to use different characters or strings, depending on the desired format for the address output.
For example, if you prefer a comma and space (,
) instead of <BR>
, you can configure the AddressLineSeparator
option accordingly. This customization ensures that the formatted address aligns with your specific requirements.
Example:
"4399 Shawnee Ste 1200<BR>MSC 6002"
This format is consistent with:
- Loqate's default multi-line formatting behavior.
- How CombinedAddressLines is generated when AddressLine1, AddressLine2, etc., are concatenated after cleansing.
If you look at your cleanser configuration using the following API endpoint.
GET https://<environment>.reltio.com/reltio/tenants/<tenantId>/cleanse
[ { "cleanseFunction": "Loqate", "options": { "process": "v+g", "ovOnly": "true", "returnUnverifiedStatus": "true", "loqateDefaultCountry": "US", "returnDataByStatus": "Partially Verified;Ambiguous;Unverified;Partially verified;Verified", "opts": { "PreferPrimaryValidAlias": "Yes" }, "ignoreUnverifiedResults": "false" } }, { "cleanseFunction": "PhoneCleanserFn" }, { "cleanseFunction": "EmailCleanserFn", "options": { "casing": "lower" } } ]
You can explicitly set a cleaner output using the AddressLineSeparator option.
[ { "cleanseFunction": "Loqate", "options": { "process": "v+g", "ovOnly": "true", "returnUnverifiedStatus": "true", "loqateDefaultCountry": "US", "returnDataByStatus": "Partially Verified;Ambiguous;Unverified;Partially verified;Verified", "opts": { "PreferPrimaryValidAlias": "Yes", "AddressLineSeparator": "," }, "ignoreUnverifiedResults": "false" } }, { "cleanseFunction": "PhoneCleanserFn" }, { "cleanseFunction": "EmailCleanserFn", "options": { "casing": "lower" } } ]
This would change CombinedAddressLines to:
"4399 Shawnee Ste 1200, MSC 6002"
You can apply this change to your cleanser configuration using the following API endpoint, using the above revisions as the payload.
POST https://test.reltio.com/reltio/tenants/ronn2c4653UsJkA/cleanse
References:
Comments
Please sign in to leave a comment.