Hi All, I am very new to proclaim and would greatly appreciate some help with the following:
I want to export an array of data from proclaim via a webservice request. My wsdl file looks like below:
<s:element name="SendQuestionnaireRequest">
<s:complexType>
<s:sequence>
<s:element minOccurs="0" name="QuestionAnswerDataArray" nillable="true" type="tns:QuestionAnswerDataArray"/>
</s:sequence>
</s:complexType>
</s:element>
<!-- Questionnaire Pre-Population -->
<s:complexType name="QuestionAnswerDataArray">
<s:sequence>
<s:element minOccurs="0" maxOccurs="unbounded" name="QuestionAnswerData" nillable="true"
type="tns:QuestionAnswerData"/>
</s:sequence>
</s:complexType>
<s:complexType name="QuestionAnswerData">
<s:sequence>
<s:element minOccurs="0" name="key" type="s:string"/>
<s:element minOccurs="0" name="value" type="s:string"/>
</s:sequence>
</s:complexType>
After we load the wsdl file onto proclaim Web Services Admin, the QuestionAnswerData field has a (Record Level)
My question is how to re-write the wsdl file in such a way that when it's imported onto Web Services Admin, it will show a single field for QuestionAnswerData? This is so that we can then right-click on it and choose the ‘Select a Generate XML Task Mode’ option?
please note QuestionAnswerData is an array of object (with key/value fields)
webservice array xml export
Re: webservice array xml export
not tested but remove </s:sequence> from QuestionAnswerData block?
Code: Select all
<s:complexType name="QuestionAnswerData">
<s:element minOccurs="0" name="key" type="s:string"/>
<s:element minOccurs="0" name="value" type="s:string"/>
</s:complexType>
-
- Posts: 3
- Joined: Thu Jan 21, 2021 2:13 pm
Re: webservice array xml export
Thanks for you response Danny but unfortunately that didnt work 
I have made so many different tweaks and still showing it as Record Level....

I have made so many different tweaks and still showing it as Record Level....
Re: webservice array xml export
ok keep the sequence,
canu post the whole wsdl? u can remove the endpoint url for privacy
have a look at this basic wsdl and compare
https://www.dataaccess.com/webservicess ... n.wso?WSDL
a simple input element that allows for generate sml task is defined like this
if u are reusing a webservice definition in proclaim then sometimes it gets confused if you are updating the same webservice definition over and over
u might want to create from new each time u change the wsdl
canu post the whole wsdl? u can remove the endpoint url for privacy
have a look at this basic wsdl and compare
https://www.dataaccess.com/webservicess ... n.wso?WSDL
a simple input element that allows for generate sml task is defined like this
Code: Select all
<xs:element name="NumberToDollars">
<xs:complexType>
<xs:sequence>
<xs:element name="dNum" type="xs:decimal"/>
</xs:sequence>
</xs:complexType>
</xs:element>
u might want to create from new each time u change the wsdl
-
- Posts: 3
- Joined: Thu Jan 21, 2021 2:13 pm
Re: webservice array xml export
Hey thanks I sorted it out. all I need to do was to add another element with the same name
<!-- Questionnaire Pre-Population -->
<s:element name="QuestionAnswerDataArray" nillable="true" type="QuestionAnswerDataArray" />
<s:complexType name="QuestionAnswerDataArray">
<s:sequence>
<s:element minOccurs="1" maxOccurs="unbounded" name="QuestionAnswerData" nillable="true"
type="QuestionAnswerData"/>
</s:sequence>
</s:complexType>
<!-- Questionnaire Pre-Population -->
<s:element name="QuestionAnswerDataArray" nillable="true" type="QuestionAnswerDataArray" />
<s:complexType name="QuestionAnswerDataArray">
<s:sequence>
<s:element minOccurs="1" maxOccurs="unbounded" name="QuestionAnswerData" nillable="true"
type="QuestionAnswerData"/>
</s:sequence>
</s:complexType>