Description | Query Supplier Invoices (Deprecated) |
Name | QuerySupplierInvoiceIn |
Namespace | http://sap.com/xi/A1S/Global |
Product | SAP Business ByDesign |
Process component | Supplier Invoice Processing |
Process component namespace | http://sap.com/xi/AP/SupplierInvoicing/Global |
Deployment unit | Supplier Invoicing |
Endpoint Activation | By Scoping of Process Component | Operations |
|
Release Status | Released |
Deprecation Release | 1811 |
Technical documentation on the SAP API Business Hub | Query Supplier Invoices (Deprecated) |
General web service documentation | A2X Web Services (SOAP) |
An interface to query Supplier Invoices from a source system.
The web service Interface ‘Query Supplier Invoice In’ enables you to connect external applications to your SAP Business By Design system and to query Supplier Invoice in your system. The web service interface ‘Query Supplier Invoice In’ is relevant if your company wants to access Supplier Invoice data from external applications.
The web service ‘Query Supplier Invoice In’ offers the operation QUERY_BY_ELEMENTS. Here is an example of a simple web service request:
<n0:SupplierInvoiceSimpleByElementsQuery_sync xmlns:n0="http://sap.com/xi/SAPGlobal20/Global"> <SupplierInvoiceSimpleSelectionByElements> <SelectionByBusinessTransactionDocumentReferenceID> <InclusionExclusionCode>I</InclusionExclusionCode> <IntervalBoundaryTypeCode>1</IntervalBoundaryTypeCode> <LowerBoundaryBusinessTransactionDocumentReferenceID>4711</LowerBoundaryBusinessTransactionDocumentReferenceID> </SelectionByBusinessTransactionDocumentReferenceID> </SupplierInvoiceSimpleSelectionByElements> <ProcessingConditions> <QueryHitsUnlimitedIndicator>false</QueryHitsUnlimitedIndicator> <QueryHitsMaximumNumberValue>1</QueryHitsMaximumNumberValue> </ProcessingConditions> </n0:SupplierInvoiceSimpleByElementsQuery_sync>
Query selection parameters are mainly exposed as select options or ranges, with an inclusion/exclusion code, interval boundary type code, lower boundary value, and upper boundary value.
The inclusion/exclusion code (element name InclusionExclusionCode) specifies the inclusion or exclusion of a set in a result set.
Inclusion Exclusion Code | Description |
---|---|
E | Excluding |
I | Including |
The interval boundary type code (element name IntervalBoundaryTypeCode) is used to describe intervals by their boundaries. Depending on the operator, the lower boundary value or both boundary values are relevant.
Interval Boundary Type Code | Name | Description | Logical Operator |
---|---|---|---|
1 | Equal to | Single Value | =X |
2 | Between(Excluding upper boundary) | Interval with closed lower and open upper boundary | [X, Y) |
3 | Between | Interval with open lower and open upper boundary | (X, Y) |
4 | Between (excluding both boundaries) | Interval with open lower and open upper boundary | (X, Y) |
5 | Between (excluding lower boundary) | Interval with open lower and closed upper boundary | (X, Y] |
6 | Less than | Interval with unlimited lower and open upper boundary | < X |
7 | Less than or Equal to | Interval with unlimited lower and closed upper boundary | <= X |
8 | Greater than | Interval with open lower and unlimited upper boundary | > X |
9 | Greater than or Equal to | Interval with closed lower and unlimited upper boundary | = X |
Before a query is executed on Supplier Invoices, instances of Supplier Invoices have to be created and maintained first.
Action codes represent an instruction to the recipient of the web service request to process transmitted message node elements.
The action code to be used is ‘QUERY_BY_ELEMENTS’.
Optional leaf elements in request messages that are not transmitted within a web service request are not considered while querying. So any value of missing parameters would meet the comparison.
Query operation is stateless synchronous web service operation. Transferring or requesting amounts of data that are too large causes communication timeouts. The web service consumer is responsible for ensuring reasonable sizes of data for mass operations.
The structure of the request message type consists of two parts:
• Selection parameters for the query
• Processing conditions. This specifies the limit on the output i.e number of records returned. You can also specify if you want unlimited number of records.
Many external applications consuming web services have special requirements and restrictions regarding the format of WSDLs. Some external applications require service definition WSDLs describing the web service signature. This is normally sufficient for the creation of static client-side proxies. Other external applications, normally those that do not create static client-side proxies, require binding WSDLs including the endpoint definition and authentication policy information.
In both cases, it may be the case that the external application imposes special restrictions on the structure or the size of WSDLs.
Microsoft InfoPath requires binding WSDLs and considers elements with the attribute "minOccurs=0" as "mandatory". However "minOccurs=0" means "optional" in SAP web services. In order to circumvent this problem, the WSDL must be saved locally and an additional attribute "nillable=true" must be added to make a query parameter optional for Microsoft InfoPath.
For very small clients such as mobile devices, the size of the WSDL itself may become a problem. In most cases the client only requires a very small part of the signature, but due to the complexity of the WSDL they may end up with long runtime during serialization of the request or deserialization of the response. In order to circumvent this problem, the WSDL must be saved locally and the optional parts of the signature have to be removed before the WSDL is imported or static client-side proxies are generated.
External applications have to take into account that web service request and response message types can be enhanced with additional elements and attributes. Enhancements can be created by SAP, SAP partners, and key users. Enhancements of request message types are always optional elements or attributes. The SAP system does not require the external application to provide values in the request. Enhancements of response message types can contain mandatory elements or attributes. The external application must be able to process the extended response successfully.
XML element and attribute names are always stable. Technical definitions of data types can be enhanced in a compatible way. This may result in changed data type names. External applications can rely on XML element names and attribute names, but should not rely on data type names.
Note: You can download the WSDL file for any web service here:
• Application and User Management work center -> Input Output Management -> Communication Arrangement.
• User Management work center -> Service Explorer view.
You can find the documentation of the global data types in the SAP Community Network: Go to http://scn.sap.com/docs/DOC-17516 and click View Document.
You can find general information about Web services, their structure and consumption in the Web Services documentation. Please open the Web Services document in a new window.
Possible scenarios include the following:
• Find Supplier Invoices based on certain set of information like parties, location etc.
This finds the Supplier Invoice with ID 4711.
<n0:SupplierInvoiceSimpleByElementsQuery_sync xmlns:n0="http://sap.com/xi/SAPGlobal20/Global"> <SupplierInvoiceSimpleSelectionByElements> <SelectionByBusinessTransactionDocumentReferenceID> <InclusionExclusionCode>I</InclusionExclusionCode> <IntervalBoundaryTypeCode>1</IntervalBoundaryTypeCode> <LowerBoundaryBusinessTransactionDocumentReferenceID>4711</LowerBoundaryBusinessTransactionDocumentReferenceID> </SelectionByBusinessTransactionDocumentReferenceID> </SupplierInvoiceSimpleSelectionByElements> <ProcessingConditions> <QueryHitsUnlimitedIndicator>false</QueryHitsUnlimitedIndicator> <QueryHitsMaximumNumberValue>1</QueryHitsMaximumNumberValue> </ProcessingConditions> </n0:SupplierInvoiceSimpleByElementsQuery_sync>
Description | Find supplier invoices (deprecated) |
Name | FindSimpleByElementsDepricated |
Synchronous | yes |
Release Status | Released |
Deprecation Release | 1811 |
QuerySupplierInvoiceIn interface allows to query on existing supplier invoices in the system.
The request message of the QueryByElements contains two parts: Body and Processing Conditions. Body comprises of the various parameters on which Supplier Invoices can be queried. Details on these parameters are discussed in the following sub-sections. Processing conditions controls the execution of query. For example you can specify if you want a certain number of records as output or unlimited records should be shown.
The response message contain the header level relevant attributes of Supplier Invoice along with the Processing conditions. The processing condition here indicates that how many records are returned and are there any more records existing which meet the criteria but not fetched.
The search can contain complex criteria instead of having simple equation. You can get results based on ‘equal to’ or a Range or Less than or greater than logical operations. These type codes should be specified in the request message.
Structure of the request message has the following parameters based on which supplier invoices can be searched:
Element | Remark |
---|---|
SearchText | You can specify anything in this text and if this text exists for any Supplier Invoice it will show up in result |
ID | ID of the Supplier Invoice |
SystemAdministrativeDataCreationDateTime | Creation date of Supplier Invoice |
SystemAdministrativeDataLastChangedDateTime | Last changed date of Supplier Invoice |
CreationBusinessPartnerCommonPerson*Name | Name of the employee who created the Supplier Invoice |
LastChangeBusinessPartnerCommonPerson*Name | Name of the employee who updated the Supplier Invoice last |
Date | Document date of Supplier Invoice |
ItemAccountingCodingBlockTYpe | The type of accounting object of Supplier Invoice item |
TypeCode | TypeCode of Supplier Invoice |
TransactionDate | Transaction date of Supplier Invoice |
TemplateIndicator | Template indicator date of Supplier Invoice |
Name | Supplier Invoice description |
TotalGrossAmount | Total gross amount of Supplier Invoice |
TotalNetAmount | Total net amount of Supplier Invoice |
BusinessTransactionDocumentReferenceID | Reference document ID used in Supplier Invoice |
BusinessTransactionDocumentTypeCode | Reference document type code used in Supplier Invoice |
BusinessTransactionDocumentReferenceConfirmedInboundDeliveryID | Inbound Delivery ID referenced in Supplier Invoice |
BusinessTransactionDocumentReferenceCustomsDutyInvoiceID | Customs Duty Invoice ID referenced in Supplier Invoice |
BusinessTransactionDocumentReferenceGoodsAndServiceAcknowledgementID | Goods And Service Acknowledgment ID referenced in Supplier Invoice |
BusinessTransactionDocumentReferencePurchasingContractID | in Supplier Invoice |
BusinessTransactionDocumentReferenceOriginSupplierInvoiceID | Origin Supplier Invoice ID referenced in Supplier Invoice |
BusinessTransactionDocumentReferenceOutboundDeliveryID | Outbound Delivery ID referenced in Supplier Invoice |
BusinessTransactionDocumentReferenceProcurementReleaseOrderID | Drop-ship Order ID referenced in Supplier Invoice |
BusinessTransactionDocumentReferencePurchaseOrderID | Purchase order ID referenced in Supplier Invoice |
BusinessTransactionDocumentReferenceRequestForQuoteID | RFQ ID referenced in Supplier Invoice |
BusinessTransactionDocumentReferenceSupplierInvoiceID | Supplier Invoice ID referenced in Supplier Invoice |
BusinessTransactionDocumentReferenceCustomerInvoiceID | Customer Invoice ID referenced in Supplier Invoice |
ItemDescription | Description of Supplier Invoice Item |
ItemAccountingCodingBlockDistributionItemCostCentreID | Cost Center ID used in Supplier |
ItemAccountingCodingBlockDistributionItemSalesOrderReferenceID | Sales Order Reference ID used in Supplier Invoice |
ItemLocationShipToLocationID | Ship To Location ID used in Supplier Invoice |
ItemLocationShipFromLocationID | Ship From Location ID used in Supplier Invoice |
ItemProductProductSellerID | Product Seller ID used In Supplier Invoice |
ItemAccountingCodingBlockDistributionItemProjectReferenceProject* | Project Reference used In Supplier Invoice |
ItemAccountingCodingBlockDistributionItemAccountingDeterminationExpenseGroupCode | Determination Expense Group Code used In Supplier Invoice |
CashDiscountTermsFullPaymentEndDate | Due date of Supplier Invoice |
ReceiptDate | Receipt Date of Supplier Invoice |
DataOriginTypeCode | Data Entry Type Code of Supplier Invoice |
CancellationDocumentIndicator | Cancellation Indicator of Supplier Invoice |
GrossAmount | Gross Amount of Supplier Invoice |
StatusSupplierInvoiceLifeCycleStatusCode | Life Cycle Status Code of Supplier Invoice |
StatusApprovalStatusCode | Approval Status Code of Supplier Invoice |
StatusBlockingStatusCode | Blocking Status Code of Supplier Invoice |
StatusCancellationStatusCode | Cancellation Status Code of Supplier Invoice |
StatusConsistencyStatusCode | Consistency Status Code of Supplier Invoice |
StatusDataEntryProcessingStatusCode | Data Entry Processing Status Code of Supplier Invoice |
StatusPostingStatusCode | Posting Status Code of Supplier Invoice |
StatusInvoicingClearingStatusCode | Invoicing Clearing Status Code of Supplier Invoice |
StatusDueItemClearingStatusCode | Due Item Clearing Status Code of Supplier Invoice |
Supplier_CommonBusinessPartnerFormattedName | Suppler Name of Supplier Invoice |
SupplierInvoiceVerificationException_ProcessingTypeCode | Supplier Invoice Exception Type code used in Supplier Invoice |
SupplierInvoiceVerificationException_LifeCycleStatusCode | Supplier Invoice Exception Status of Supplier Invoice |
ItemAccountingCodingBlockDistributionItemIndividualMaterialKeyProductTypeCode | Individual Material Type Code used in Supplier Invoice |
ItemAccountingCodingBlockDistributionItemIndividualMaterialKeyProductIdentifierTypeCode | Individual Material ID Type Code used in Supplier Invoice |
ItemAccountingCodingBlockDistributionItemIndividualMaterialKeyProductID | Individual Material ID used in Supplier Invoice |
ItemPartyProductRecipientPartyKeyPartyTypeCode | Product Recipient Party Type Code used in Supplier Invoice |
ItemPartyProductRecipientPartyKeyPartyID | Product Recipient Party ID used in Supplier Invoice |
ItemPartyRequestorPartyKeyPartyTypeCode | Requester Party Type Code used in Supplier Invoice |
ItemPartyRequestorPartyKeyPartyID | Requester Party ID used in Supplier Invoice |
ItemPartyServicePerformerPartyKeyPartyTypeCode | Service Performer Party Type Code used in Supplier Invoice |
ItemPartyServicePerformerPartyKeyPartyID | Service Performer Party ID used in Supplier Invoice |
ItemPartyTaxReportingUnitPartyKeyPartyTypeCode | Tax Reporting Unit Party Type Code used in Supplier Invoice |
ItemPartyTaxReportingUnitPartyKeyPartyID | Tax Reporting Unit Party ID used in Supplier Invoice |
ItemProductProductCategoryIDKeyProductCategoryInternalID | Product Category ID used in Supplier Invoice |
ItemProductProductKeyProductTypeCode | Product Type Code used in Supplier Invoice |
ItemProductProductKeyProductIdentifierTypeCode | Product ID Type Code used in Supplier Invoice |
ItemProductProductKeyProductID | Product ID used in Supplier Invoice |
PartyBillFromPartyKeyPartyTypeCode | Bill From Party Type Code of Supplier Invoice |
PartyBillFromPartyKeyPartyID | Bill From Party ID of Supplier Invoice |
PartyBillToPartyKeyPartyTypeCode | Bill To Party Type Code of Supplier Invoice |
PartyBillToPartyKeyPartyID | Bill To Party ID of Supplier Invoice |
PartyBuyerPartyKeyPartyTypeCode | Buying Company Type Code of Supplier Invoice |
PartyBuyerPartyKeyPartyID | Buying Company ID of Supplier Invoice |
PartyEmployeeResponsiblePartyKeyPartyTypeCode | Employee Responsible Type Code of Supplier Invoice |
PartyEmployeeResponsiblePartyKeyPartyID | Employee Responsible ID of Supplier Invoice |
PartyResponsibleInvoicerPartyKeyPartyTypeCode | Responsible Invoicing Party Type Code of Supplier Invoice |
PartyResponsibleInvoicerPartyKeyPartyID | Responsible Invoicing Party ID of Supplier Invoice |
PartyResponsibleSupplierInvoicingUnitPartyKeyPartyTypeCode | Supplier Invoicing Unit Party Type Code of Supplier Invoice |
PartyResponsibleSupplierInvoicingUnitPartyKeyPartyID | Supplier Invoicing Unit Party ID of Supplier Invoice |
PartySellerPartyKeyPartyTypeCode | Supplier Party Type Code used in Supplier Invoice |
PartySellerPartyKeyPartyID | Supplier Party ID used in Supplier Invoice |
The response consists of root level element of Supplier Invoice. Following are the major attributes in result
ID
SystemAdministrativeData
Date
ReceiptDate
TransactionDate
TypeCode
TypeName
DataOriginTypeCode
DataOriginTypeName
TemplateIndicator
CancellationDocumentIndicator
DocumentItemsGrossAmountIndicator
Name
GrossAmount
TaxAmount
TotalDownPaymentAmount
TotalDueAmount
TotalGrossAmount
TotalNetAmount
TotalTaxAmount
BalanceAmount
SupplierInvoiceLifeCycleStatusCode
SupplierInvoiceLifeCycleStatusName