MAX value of a contact information custom property
SOLVE
Hello,
I am a newbie.
I have a custom property "ID" of contact information group filled with an integer from an external source.
How to calculate the MAX of ID?
When I create a custom property MAX_ID type calculation in the group list Contact Information group is missing (I see company,deal ect) so I cannot select ID because is missing
An alternative is to get the first 5 contacts in descending order, so the ID of the first contact is the max ... but I don't know to get contacts in descending order.....
Hope that I am interpretting this correctly, if you want to sort your contacts by this property, I would suggest employing the CRM search endpoint
You could send a post request with a filter polling if your custom property has a value in each record. You would then apply the sort rule sort by that property to the request as well. In the end, the post request json body would look something like this assuming that MAX_ID is the internal name of the property
Hope that I am interpretting this correctly, if you want to sort your contacts by this property, I would suggest employing the CRM search endpoint
You could send a post request with a filter polling if your custom property has a value in each record. You would then apply the sort rule sort by that property to the request as well. In the end, the post request json body would look something like this assuming that MAX_ID is the internal name of the property
If I understood correctly, you have created a custom property, where you wish to save an external contact ID.
If you don't have any filters in place, you should be able to see the property under Settings > Data managememt > Properties:
Please make sure that you've selected Contact properties in the object picker above.
If you're not able to see this section, please make sure you have the right user permissions to edit settings. Additionally, please try to access this area in a different browser (preferably Google Chrome or Mozilla Firefox).
If your custom property type is a Number field, you should be able to arrange the contacts in a descending order by clicking on the arrow next to the property in your contact overview:
MAX value of a contact information custom property
SOLVE
Hi,
thank you for your answer...
but I am working with the REST API not with GUI so ..how to select by REST API the max value of a numeric custom property? in pseudo SQL : select max (numeric_custom_property) from contacts?
as alternative I tried to do this but is not working:
I added a custom property to company object (crm_max_id)
In the contact object I added a calculated field so that
crm_max_id is the MAX of a custom property of contacts
I unfortunately don't have enough experience with the REST API to be able to help here, but I wanted to tag in a couple of subject matter experts to see if they can share their expertise: