External_id what is it used for?

Could someone please give me an example of how external_id is used or what it is used for. So far i can only see it being used for imports with parent and child data.

Is there a possibility of using it as a way to uniquely identify records so that you can look them up in the reporting section?

I see it referenced here, but not sure how it should or does work.

Hi Calvin,

‘external_id’ is a bit of a “soft” special field within CommCare.

It behaves identically to any other field you’ve set on a case, but is indexed such that it is faster for direct key queries on mobile and is available through HQ’s API’s as part of a case’s high level metadata.

The only internally unique ID that CommCare assigns automatically is the GUID that is reflected as case_id, but using external_id for your own generated identifiers will work a bit better than using another named case property for the reasons I mentioned above.


Thanks so much for the reply on this one Clayton. Was busy at the time and forgot to respond when I read your response.