I have an object I'm tracking in keen-io that has several date fields. I'd like Keen to preserve these as DateTime fields. This way I can do filtering and sorting.
I'm using a map add adding the dates formated as ISO-8601.
Map<String, Object> o = new HashMap<String, Object>();
o.put("deliveryDate", formatDate(deliveryDate));
o.put("completionDate", formatDate(completionDate));
o.put("assignedDate", formatDate(assignedDate));
Where formatDate looks like:
private SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSS'Z'");
protected String formatDate(Calendar date) {
return dateFormat.format(date.getTime());
}
When the events get to my keen dashboard the field is always treated as a string not a datetime.
Am I missing some step I can not find in the documentation? Are datetime fields available on fields other than keen.timestamp
and keen.created_at
?