webMethods 10.2 | Service Development Help | Creating Client Code | Building a Browser-Based Client | How Input Values are Passed to the Service the Browser-Based Client Invokes | When Browser-Based Clients Pass Multiple Input Variables with the Same Name
 
When Browser-Based Clients Pass Multiple Input Variables with the Same Name
If the URL that a browser-based client passes to Integration Server contains multiple variables that have the same name, Integration Server determines how to handle the duplicate variables based on the setting of the watt.server.http.listRequestVars server configuration parameter.
To have Integration Server:
*Create list variables for only duplicate variables, set watt.server.http.listRequestVars server to asNeeded. This is the default.
With this setting, Integration Server creates an IData object that contains:
*String variable that contains the first occurrence of each input variable
*String list variable that contains all occurrences of each duplicated variable
For example, this request:
/invoke/sample.webPageDemo/checkYears?year=1998&year=1999&month=June
Integration Server creates the following IData object:
Key
Value
Data Type
year
1998
String
yearList
1998
1999
String list
month
June
String
*Create list variables for all variables, set watt.server.http.listRequestVars server to always.
With this setting, Integration Server creates an IData object that contains:
*String variable that contains the first occurrence of each input variable
*String list variable that contains all occurrences of each input variable
For example, for this request:
/invoke/sample.webPageDemo/checkYears?year=1998&year=1999&month=June
Integration Server creates the following IData object:
Key
Value
Data Type
year
1998
String
yearList
1998
1999
String list
month
June
String
monthList
June
String list
*Create no list variables, set watt.server.http.listRequestVars server to never.
With this setting, Integration Server ignores duplicates of the same variable and creates an IData object that contains only a String variable that contains the first occurrence of each input variable.
For example, for this request:
/invoke/sample.webPageDemo/checkYears?year=1998&year=1999&month=June
Key
Value
Data Type
year
1998
String
month
June
String
*Throw a ServiceException, set watt.server.http.listRequestVars server to error.
With this setting, Integration Server throws a ServiceException if duplicates of the same variable are found.
For more information about this configuration parameter, see webMethods Integration Server Administrator’s Guide.
Building a Browser-Based Client
URL Client Uses to Invoke Services
How Input Values are Passed to the Service the Browser-Based Client Invokes
When Browser-Based Clients Pass Multiple Values for the Same Input Variable

Copyright © 2017-2018 | Software AG, Darmstadt, Germany and/or Software AG USA, Inc., Reston, VA, USA, and/or its subsidiaries and/or its affiliates and/or their licensors.
Innovation Release