Qore SalesforceRestDataProvider Module Reference  1.0.1
SOQL Operator Functions

Functions

hash< SoqlOperatorInfoSalesforceRestDataProvider::soql_make_op (string op, auto arg)
 returns an SoqlOperatorInfo hash
 
hash< SoqlOperatorInfoSalesforceRestDataProvider::soql_op_eq (auto arg)
 returns an SoqlOperatorInfo hash for the "=" operator with the given argument for use in salesforce where clauses when comparing column values to immediate values More...
 
hash< SoqlOperatorInfoSalesforceRestDataProvider::soql_op_ge (auto arg)
 returns an SoqlOperatorInfo hash for the ">=" operator with the given argument for use in salesforce where clauses when comparing column values to immediate values More...
 
hash< SoqlOperatorInfoSalesforceRestDataProvider::soql_op_gt (auto arg)
 returns an SoqlOperatorInfo hash for the ">" operator with the given argument for use in salesforce where clauses when comparing column values to immediate values More...
 
hash< SoqlOperatorInfoSalesforceRestDataProvider::soql_op_in ()
 returns an SoqlOperatorInfo hash for the "in" operator with all arguments passed to the function; for use in salesforce where clauses More...
 
hash< SoqlOperatorInfoSalesforceRestDataProvider::soql_op_in (list< auto > args)
 returns an SoqlOperatorInfo hash for the "in" operator with the given argument list as the first argument; for use in salesforce where clauses More...
 
hash< SoqlOperatorInfoSalesforceRestDataProvider::soql_op_le (auto arg)
 returns an SoqlOperatorInfo hash for the "<=" operator with the given argument for use in salesforce where clauses when comparing column values to immediate values More...
 
hash< SoqlOperatorInfoSalesforceRestDataProvider::soql_op_like (string str)
 returns an SoqlOperatorInfo hash for the "like" operator with the given argument for use in salesforce where clauses More...
 
hash< SoqlOperatorInfoSalesforceRestDataProvider::soql_op_lt (auto arg)
 returns an SoqlOperatorInfo hash for the "<" operator with the given argument for use in salesforce where clauses when comparing column values to immediate values More...
 
hash< SoqlOperatorInfoSalesforceRestDataProvider::soql_op_ne (auto arg)
 returns an SoqlOperatorInfo hash for the "!=" or "<>" operator with the given argument for use in salesforce where clauses when comparing column values to immediate values More...
 
hash< SoqlOperatorInfoSalesforceRestDataProvider::soql_op_not (hash arg)
 returns an SoqlOperatorInfo hash for the "not" operator; for use in salesforce where clauses More...
 
hash< SoqlOperatorInfoSalesforceRestDataProvider::soql_op_not_in ()
 returns an SoqlOperatorInfo hash for the "not in" operator with all arguments passed to the function; for use in salesforce where clauses More...
 
hash< SoqlOperatorInfoSalesforceRestDataProvider::soql_op_not_in (list< auto > args)
 returns an SoqlOperatorInfo hash for the "not in" operator with the given argument list as the first argument; for use in salesforce where clauses More...
 
hash< string, hash< SoqlOperatorInfo > > SalesforceRestDataProvider::soql_wop_or (hash< auto > h1, hash< auto > h2)
 returns an SoqlOperatorInfo hash with a fake "_OR_" column name; the list of arguments to the function is combined such that each hash in the list generates SQL expressions combined with "and" logic, and each of those clauses is combined with "or" logic; this is for use in salesforce where clauses More...
 

Detailed Description

These are the operators that can be used in Salesforce where clauses

Function Documentation

◆ soql_op_eq()

hash<SoqlOperatorInfo> SalesforceRestDataProvider::soql_op_eq ( auto  arg)

returns an SoqlOperatorInfo hash for the "=" operator with the given argument for use in salesforce where clauses when comparing column values to immediate values

Example:
AbstractDataProviderRecordIterator i = provider.searchRecords({"Name": soql_op_eq("Smith")});
Parameters
argthe argument for the operator
Returns
an SoqlOperatorInfo hash for use in salesforce where clauses

◆ soql_op_ge()

hash<SoqlOperatorInfo> SalesforceRestDataProvider::soql_op_ge ( auto  arg)

returns an SoqlOperatorInfo hash for the ">=" operator with the given argument for use in salesforce where clauses when comparing column values to immediate values

Example:
AbstractDataProviderRecordIterator i = provider.searchRecords({"Name": soql_op_ge("Apple")});
Parameters
argthe argument for the operator
Returns
an SoqlOperatorInfo hash for use in salesforce where clauses

◆ soql_op_gt()

hash<SoqlOperatorInfo> SalesforceRestDataProvider::soql_op_gt ( auto  arg)

returns an SoqlOperatorInfo hash for the ">" operator with the given argument for use in salesforce where clauses when comparing column values to immediate values

Example:
AbstractDataProviderRecordIterator i = provider.searchRecords({"Name": soql_op_gt("Apple")});
Parameters
argthe argument for the operator
Returns
an SoqlOperatorInfo hash for use in salesforce where clauses

◆ soql_op_in() [1/2]

hash<SoqlOperatorInfo> SalesforceRestDataProvider::soql_op_in ( )

returns an SoqlOperatorInfo hash for the "in" operator with all arguments passed to the function; for use in salesforce where clauses

Example:
AbstractDataProviderRecordIterator i = provider.searchRecords({"Name": soql_op_in(200, 300, 500, 9)});
Returns
an SoqlOperatorInfo hash for use in salesforce where clauses
Note
The argument list size may be constrained depending on the database server / driver used; passing a large number of arguments to this function may be a sign of an improper application or query design

◆ soql_op_in() [2/2]

hash<SoqlOperatorInfo> SalesforceRestDataProvider::soql_op_in ( list< auto >  args)

returns an SoqlOperatorInfo hash for the "in" operator with the given argument list as the first argument; for use in salesforce where clauses

Example:
AbstractDataProviderRecordIterator i = provider.searchRecords({"name": soql_op_in(idlist)});
Parameters
argsa list of values for the "in" operator
Returns
an SoqlOperatorInfo hash for use in salesforce where clauses
Note
The argument list size may be constrained depending on the database server / driver used; passing a large number of arguments to this function may be a sign of an improper application or query design

◆ soql_op_le()

hash<SoqlOperatorInfo> SalesforceRestDataProvider::soql_op_le ( auto  arg)

returns an SoqlOperatorInfo hash for the "<=" operator with the given argument for use in salesforce where clauses when comparing column values to immediate values

Example:
AbstractDataProviderRecordIterator i = provider.searchRecords({"Name": soql_op_le("Zebra")});
Parameters
argthe argument for the operator
Returns
an SoqlOperatorInfo hash for use in salesforce where clauses

◆ soql_op_like()

hash<SoqlOperatorInfo> SalesforceRestDataProvider::soql_op_like ( string  str)

returns an SoqlOperatorInfo hash for the "like" operator with the given argument for use in salesforce where clauses

Example:
AbstractDataProviderRecordIterator i = provider.searchRecords({"Name": soql_op_like("%smith%")});
Parameters
strthe argument for the operator
Returns
an SoqlOperatorInfo hash for use in salesforce where clauses

◆ soql_op_lt()

hash<SoqlOperatorInfo> SalesforceRestDataProvider::soql_op_lt ( auto  arg)

returns an SoqlOperatorInfo hash for the "<" operator with the given argument for use in salesforce where clauses when comparing column values to immediate values

Example:
AbstractDataProviderRecordIterator i = provider.searchRecords({"Name": soql_op_lt("Zebra")});
Parameters
argthe argument for the operator
Returns
an SoqlOperatorInfo hash for use in salesforce where clauses

◆ soql_op_ne()

hash<SoqlOperatorInfo> SalesforceRestDataProvider::soql_op_ne ( auto  arg)

returns an SoqlOperatorInfo hash for the "!=" or "<>" operator with the given argument for use in salesforce where clauses when comparing column values to immediate values

Example:
AbstractDataProviderRecordIterator i = provider.searchRecords({"Name": soql_op_ne("Smith")});
Parameters
argthe argument for the operator

◆ soql_op_not()

hash<SoqlOperatorInfo> SalesforceRestDataProvider::soql_op_not ( hash  arg)

returns an SoqlOperatorInfo hash for the "not" operator; for use in salesforce where clauses

Example:
AbstractDataProviderRecordIterator i = provider.searchRecords({"name": soql_op_not(soql_op_in(200, 300, 500, 9))))_;
Returns
an SoqlOperatorInfo hash for use in salesforce where clauses

◆ soql_op_not_in() [1/2]

hash<SoqlOperatorInfo> SalesforceRestDataProvider::soql_op_not_in ( )

returns an SoqlOperatorInfo hash for the "not in" operator with all arguments passed to the function; for use in salesforce where clauses

Example:
AbstractDataProviderRecordIterator i = provider.searchRecords({"Name": soql_op_not_in(200, 300, 500, 9)});
Returns
an SoqlOperatorInfo hash for use in salesforce where clauses
Note
The argument list size may be constrained depending on the database server / driver used; passing a large number of arguments to this function may be a sign of an improper application or query design

◆ soql_op_not_in() [2/2]

hash<SoqlOperatorInfo> SalesforceRestDataProvider::soql_op_not_in ( list< auto >  args)

returns an SoqlOperatorInfo hash for the "not in" operator with the given argument list as the first argument; for use in salesforce where clauses

Example:
AbstractDataProviderRecordIterator i = provider.searchRecords({"name": soql_op_not_in(idlist)});
Parameters
argsa list of values for the "not in" operator
Returns
an SoqlOperatorInfo hash for use in salesforce where clauses
Note
The argument list size may be constrained depending on the database server / driver used; passing a large number of arguments to this function may be a sign of an improper application or query design

◆ soql_wop_or()

hash<string, hash<SoqlOperatorInfo> > SalesforceRestDataProvider::soql_wop_or ( hash< auto >  h1,
hash< auto >  h2 
)

returns an SoqlOperatorInfo hash with a fake "_OR_" column name; the list of arguments to the function is combined such that each hash in the list generates SQL expressions combined with "and" logic, and each of those clauses is combined with "or" logic; this is for use in salesforce where clauses

Example:
AbstractDataProviderRecordIterator i = provider.searchRecords({"Id": id} + soql_wop_or({"Type": "C", "ValidationFlag": soql_op_ne("Y")}, {"ExpirationFlag": 'Y'}));
Generates:
select ... from Account where Id = '0012A000022K3zxQAC' and ((type = 'C' and ValidationFlag != 'Y') or (ExpirationFlag = 'Y'))
Parameters
h1the first hash of expressions to combine with "or" logic
h2the second hash of expressions to combine with "or" logic
...remaining expressions to combine with "or" logic
Returns
a hash with an SoqlOperatorInfo hash value keyed by a fake column name ("_OR_" with a numeric prefix for uniqueness) for use in a where operation description hash for use in salesforce where clauses
Note
a random prefix is used so that multiple uses of the function can be used to generate a single where clause hash