Compare date using whereClause

Hi guys,

I have a stream of photos. I would like to refresh data in the stream using “created” property of the Photo object.
So, I would like to get photos created after the last photo that I can see in the stream…something like
[query whereClause:“created” greaterThan:“lastPhoto.created”]
Is there something about it or I need to get string from date and compare them?

Get the timestamp of the last photo in the stream, convert it to milliseconds. Suppose that value is ‘lastPhotoCreatedTime’. Then run a query with the following whereClause:

created > [lastPhotoCreatedTime]

For example:

created > 1454617993219