You need to sign in to do that
Don't have an account?
Peter Kemp
PHP SOAP search function
Hi,
I'm trying perform a search on Salesforce using the PHP SOAP search function. I have the ID of an object and would like to check that the user owns that object before allowing them access to it. I'm read the documentation on SOSL and have come up with this. Where they find all the careers matching the one chosen, then check that the Contact is the owner of that career
$allowed = "FIND {\"$careerid\"}
IN ALL FIELDS
RETURNING
Participant_Career__c(ID, Name WHERE Contact__c = \"$contactid\")";
$allowed = $mySforceConnection->search($allowed);
However, this returns an empty object. I know the $careerid exists in Salesforce but FINDing on the $careerid returns an empty object as well. Any ideas where I can going wrong?
Thanks
Pete
I'm trying perform a search on Salesforce using the PHP SOAP search function. I have the ID of an object and would like to check that the user owns that object before allowing them access to it. I'm read the documentation on SOSL and have come up with this. Where they find all the careers matching the one chosen, then check that the Contact is the owner of that career
$allowed = "FIND {\"$careerid\"}
IN ALL FIELDS
RETURNING
Participant_Career__c(ID, Name WHERE Contact__c = \"$contactid\")";
$allowed = $mySforceConnection->search($allowed);
However, this returns an empty object. I know the $careerid exists in Salesforce but FINDing on the $careerid returns an empty object as well. Any ideas where I can going wrong?
Thanks
Pete