Hi Keith,
So whats the difference between not present and null? If these are on an object... I pass my object to the routine it has the properties fx.. Item.ItemCode (String) Item.effEndDate (Date) I don't set these properties because I don't need them...And pass the object to the web method..Then I get the errors that effEndDate cannot be null since it has as you say minOccurs="0" and nillable ommited...So how would I "not provide" this element since its part of an object.... How should the wsdl look to allow that? Thanks Tim ________________________________ From: keith chapman [mailto:[EMAIL PROTECTED] Sent: Tuesday, June 17, 2008 11:25 PM To: [email protected] Subject: Re: Axis Generates All Fields Not Nullable According to your WSDL it has minOccurs="0" which means that this element is optional. But it does not state that nillable="true" which means that if this element is present its value cannot be null. I'm not an ADB expert but this is how it should be according to your WSDL. Thanks, Keith. On Wed, Jun 18, 2008 at 1:04 AM, Tim James McConechy <[EMAIL PROTECTED]> wrote: Hi, When I run wsdl2java from a .NET 1.1 web service axis adds code such as: if (localitemCode ==null){ // write the nil attribute throw new org.apache.axis2.databinding.ADBException("itemCode cannot be null!!"); The WSDL looks like: <s:element minOccurs="0" maxOccurs="1" name="itemCode" type="s:string"/> Why does it generate the field as required? Can I make it not do this? Previously on axis 1.4 I would change setNillable(false) to setNillable(true). Thanks in advance Tim McConechy | Principal Software Engineer | Infor | Office: 610.407.8191 | Mobile: 610.306.6603 | [EMAIL PROTECTED] -- Keith Chapman Senior Software Engineer WSO2 Inc. Oxygenating the Web Service Platform. http://wso2.org/ blog: http://www.keith-chapman.org
