Reputation: 115
Is there a way to force a conditional OR search instead of just defaulting to AND?
ie:
In the CustSrch function:
<ns:ComName JHANull="?" SrchType="" Rstr="?">Luke Skywalker</ns:ComName>
<ns:FirstName JHANull="?" SrchType="Contains" Rstr="?">Luke</ns:FirstName>
<ns:MiddleName JHANull="?" SrchType="?" Rstr="?"></ns:MiddleName>
<ns:LastName JHANull="?" SrchType="Contains" Rstr="?">Skywalker</ns:LastName>
This will send a request to where all 3 conditions are met.
What I'd like to be able to do somehow is in the request, have it return results where (LastName="Skywalker" AND FirstName="Luke") OR (ComName="Luke Skywalker") are true.
Is this possible is some way?
Upvotes: 0
Views: 99
Reputation: 11
The CustSrch operation doesn't have logic that can be used to specify "or" searches, it will always use the "and" logic when using multiple filters.
The Developer Resources page for CustSrch (https://jackhenry.dev/open-enterprise-api-docs/enterprise-soap-api/api-reference/core-services/custsrch/developer-resources/) discusses this in the first entry of the FAQ section. The specific line is "When there is more than one filter on the request, then the selection is based on ~and~ rather than ~or~. "
Upvotes: 0