You need to sign in to do that
Don't have an account?
michael.vo
Dynamic datetime in streaming push topic
I need to get records between a specific time period in a push topic. For example all records between 6pm and 2am.
Select Id from Opportunity where dateTime >= {Today's Date @ 6pm} and dateTime <= Tomorrow's Date @ 2am}
Is this possible?
I have one solution which is to just pull all today's and tomorrow's records and then filter on the client side by the right time.
http://www.salesforce.com/us/developer/docs/officetoolkit/Content/sforce_api_calls_soql_select_dateformats.htm
Anyone else have a solution to this?
Select Id from Opportunity where dateTime >= {Today's Date @ 6pm} and dateTime <= Tomorrow's Date @ 2am}
Is this possible?
I have one solution which is to just pull all today's and tomorrow's records and then filter on the client side by the right time.
http://www.salesforce.com/us/developer/docs/officetoolkit/Content/sforce_api_calls_soql_select_dateformats.htm
Anyone else have a solution to this?
There is no direct way to do this,
You have to use a schedule apex class which will run at the mentioned time and have your Streaming API as a Inner class.
https://www.salesforce.com/us/developer/docs/apexcode/Content/apex_scheduler.htm
Regards,
Ashish