_$updatedAt in query only in date?

0 votes

Hi,

 

Is it posible to query documents not only on date but also on time like :

$fiterdate = date('Y-m-d H:i:s', strtotime('-2 minute'));

$queryBuilder->build('_$updatedAt', $fiterdate , Operator::GREATER_THAN); 

 

For this project I am unsing php, but same question applies on as3 library.

asked Dec 23, 2014 in App42 Cloud API-BaaS by wouter (34 points)

1 Answer

0 votes
Hello Wouter,
 
You can make a query on updatedAt by using UPDATED_ON_KEY as "_$updatedAt" .For this you need to follow the code snippet given below :-
 
$queryBuilder->build('_$updatedAt', "2014-12-15" , Operator::GREATER_THAN); 
 
Let us know if you have more questions for us.
Himanshu Sharma
answered Dec 24, 2014 by hs00105 (2,005 points)
Hello Himanshu,

OK, this means I can not filter on 2014-12-15 7:59:03, like so: $queryBuilder->build('_$updatedAt', "2014-12-15 7:59:03" , Operator::GREATER_THAN);

Thank you.
Hello Wouter,

You can query on (2014-12-15 7:59:03) exact time as well. Let us know if you have more questions for us.
Himanshu Sharma
Download Widgets
Welcome to ShepHertz Product line forum, where you can ask questions and receive answers from the community. You can also reach out to us on support@shephertz.com
...