I want to assign unique ids to events so I can query them (for example to avoid re-insert the event if it's already inserted). I can't see any event property for this use (calendar_id
is setted automatically). I would like to avoid the use of a calendar_id <=> my_id
relation of my own, using my api or whatever.
So, the question is: can I assign an unique identifier to an event so I can query for it later?
Yes you can. There is a field called
UID_2445
. According to documentation:However you can use this column to assign a unique identifier. Also you can use other sync columns listed in
CalendarContract.EventsColumns
.