cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Did you get an answer that solved your problem? Please mark it as an Accepted Solution so others with the same problem can find the answer easily. X

need to have 2 different outputs in a service

Irfan_Pasha
8-Gravel

need to have 2 different outputs in a service

Hi All,

I have an service,

in which i need 2 different kinds of outputs,

1 is infotable and another 1 is string types.

How can i do this ,

Please help.

ACCEPTED SOLUTION

Accepted Solutions

Create a new result as InfoTable with a Data Shape like

 

  • output_one = InfoTable (with the Data Shape you already have, i.e.)
    • myNumber
    • myString
    • myBoolean
  • output_two = String

The InfoTables are nested.

It works the same way as giving back i.e. a multi-dimensional array.

View solution in original post

3 REPLIES 3

Hi @Irfan_Pasha 

Services can only deliver one result (like any JavaScript function).

However you can pack it into an InfoTable, which will hold the two values you have (InfoTable + String)

 

Best Regards,
Michael

How can i pack,

can u pls give an example

Create a new result as InfoTable with a Data Shape like

 

  • output_one = InfoTable (with the Data Shape you already have, i.e.)
    • myNumber
    • myString
    • myBoolean
  • output_two = String

The InfoTables are nested.

It works the same way as giving back i.e. a multi-dimensional array.

Announcements


Top Tags