Hi all,
Have been playing about with web services but unable to achieve what I am
wanting and in attempts finding strange problems.
I have created a web service for retrieving customer data and for updating
the data using datasets. I have created a XML schema.
I decided to use InfoPath for testing things out. Works great for getting
the data.
The data table on SQL Server 2000 allows nulls. If I was to change this I
would have to split my customers into 2 tables.
The table allows customer details to be stored as an individual or
organisation. As a result some fields don't require any values so I have
allowed nulls. When I come to update the data on InfoPath I can't edit the
fields that contain nulls and the update fails because InfoPath only sends
fields in the XML that do not contain null values.
My thought of the way round this was to set minOccurs and maxOccurs to 1, I
have also marked the elements with default values and set nill to true.
When I test the web service method on the server minOccurs is set at 0 but
the XML schema shows as 1. The Schema file is publicly available and this
shows correct.
Any ideas folks?