This documentation is for WSO2 Data Services Server 3.1.0. View the home page of the latest release.

Unknown macro: {next_previous_link3}
Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 4 Next »

Output mappings allow you to <text>

The Output Mappings section appears as follows in the Queries page:

It provides the following options:

Output type

Use column numbers

Escape non printable charachters

Group by element

Row name

Row namespace

See Defining Namespaces.

XSLT path


Query Result Export

When editing an output mapping, you can define query result export options. Query Request Export feature must be used in conjunction with boxcarring. It allows individual queries executed in a boxcarring session to communicate with each other. The concept is 'exporting' a specific result element so that the next calling query will get that result element as a query parameter. So, if you've two queries, namely, 'query1' and 'query2' that's executed sequentially in a boxcarring session, and if 'query1' has a specific result element and that element is exported with the name 'foo', then 'query2' also gets a query param named 'foo'. So when this boxcarring session is executed, the query1's exported value will be passed into query2 as an input parameter.

This feature is very useful in situations where the result of an earlier-executed query is required for the execution of a subsequent query (e.g. a newly created primay key).

The following figure shows how a result element can be declared to be exported with a given name when defining a query in a data service.

There are two export types that can be used.

  • SCALAR : The single element value is exported. If there are multiple instances of this value, the last one will be exported.
  • ARRAY : An array of values will be exported. Each occurrence of the value is added to an array and exported.

For a demonstration on the usage of export options, refer to Boxcarring Demo. 

  • No labels