AnsweredAssumed Answered

REST Filtering Records in Sugar 6.7.x

Question asked by John Defour on Aug 12, 2015
Latest reply on Aug 12, 2015 by Chris Raffle
Hi Sugar community,

I am developing an iOS application that utilizes SugarCRM v10 REST calls to retrieve data from my company's Sugar On-Demand data source. Our version is 6.7.x and edition is Professional. Thus far, I have been able to successfully utilize REST calls like the following to retrieve information from my data source:
https://{site}/rest/v10/oauth2/token?    https://{site}/rest/v10/Opportunities?  
https://{site}/rest/v10/me
Now, I would like to use the parameter 'filter' to filter out opportunities based on their data. I have seen the filter parameter used in the REST cookbook on the developer blog on example #4 http://developer.sugarcrm.com/2014/02/28/sugarcrm-cookbook1/. I have constructed a similar REST URL like so:
https://{site}/rest/v10/Opportunities?filter[0][assigned_user_id]={ID found in my application}

And this did not end up working. Neither did it work when I tried using the example Accounts call used in cookbook #1 using our own account data instead.

I have tried all different calls and test parameters to get the filter to work, but, in the end, Sugar will keep returning Opportunities that do not fit my filter. 

I'm wondering if this means our Sugar version is not compatible to use filters or is there another way to filter out opportunities other than parsing the data in our application? Should I be using REST v4_1? I would prefer not to use v4_1 if I must use PHP because the v10 calls were easier to use and are actually returning information. 

Thanks.

Outcomes