Read Methods
The following table lists the supported methods for reading objects using the XML API or SOAP API. For each supported read method, the table includes a description of the API response.
Most available business object types support the all, equal to and not equal to methods except where otherwise noted in the reference material for each business object type. See XML and SOAP API Business Object Reference.
|
Method |
Response |
|---|---|
|
|
Returns all objects. Sample codes: |
|
|
Returns objects that are matching the search query object specified as argument in the read command. The read command must include a search query object as argument. The search query object must be of the same type as the objects you want to retrieve. Include all the standard object property values and custom field values that the returned objects must match. When using the XML API, set the attribute
Important:
Calculated fields are not supported. You cannot include properties corresponding to calculated fields in your search query object. The SOAP API lets you specify multiple Sample codes: |
|
|
Returns objects that are not matching the search query object specified as argument in the read command. The read command must include a search query object as argument. The search query object must be of the same type as the objects you want to retrieve. Include all the standard object property values and custom field values that the returned objects must not match.
Important:
Calculated fields are not supported. You cannot include properties corresponding to calculated fields in your search query object. The SOAP API lets you specify multiple Sample codes: |
|
|
Returns the custom field values for the object with the internal ID in the search query object. Custom field values are returned as The read command must include a search query object as argument. The search query object must be of the same type as the objects you want to retrieve and must include the internal ID [
Note:
All business object types that support custom fields support the Returned objects include custom field values along with standard object properties by default when using the SOAP API. When using the XML API, you can set the Sample codes: |
|
|
Note:
All business objects with a Returns objects associated with the user matching the internal ID specified in the |
|
|
Note:
All business objects with a Returns objects associated with the project matching the internal ID specified in the |
Combining Relational Methods Using Logical Operators (SOAP API)
The SOAP API lets you combine equal to or not equal to methods using and or or logical operators.
To do so:
-
Set the
methodparameter to a list ofequal toandnot equal torelational operator methods, each separated by a comma followed by anandororlogical operator. Anandlogical operator is used by default if not specified. The use of grouping or parentheses to modify precedence is not supported. -
Pass the same number of search query objects as arguments. There must be one search query object for each listed method.
Examples:
-
If
methodis set toequal to,not equal to, which is the same asequal to,and not equal to, the response returns object that match the first search query object but do not match the second search query object. -
If
methodis set toequal to,or equal to,and not equal to, the response returns object that do not match the third search query object and match either the first search query object or the second search query object.
Sample code: Read with Multiple equal to Methods Combined with Explicit OR Condition — C#.