Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
The moose likes Web Services and the fly likes a strange param of a WS Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Web Services
Bookmark "a strange param of a WS" Watch "a strange param of a WS" New topic

a strange param of a WS

yaoheng zhang

Joined: Jun 04, 2004
Posts: 3
I am writing a client of this service:

This .Net site provides a test page of the operation:

totally confused by the first parameter "xml", type String.
Using this test page, I don't have to input anything and it works fine. But in my code, I tried new String() and null, axis throws exception.

Anyone get clue on this? Many thanks

faultCode: {}Server.userException
faultString: java.lang.NumberFormatException: Invalid positiveInteger: 0
{}stackTrace:java.lang.NumberFormatException: Invalid positiveInteger: 0
at org.apache.axis.encoding.ser.SimpleDeserializer.onEndElement(
at org.apache.axis.encoding.DeserializerImpl.endElement(
at org.apache.axis.encoding.DeserializationContextImpl.endElement(
at org.apache.axis.message.SAX2EventRecorder.replay(
at org.apache.axis.message.MessageElement.publishToHandler(
at org.apache.axis.message.RPCElement.deserialize(
at org.apache.axis.message.RPCElement.getParams(
at org.apache.axis.client.Call.invoke(
at org.apache.axis.client.Call.invoke(
at org.apache.axis.client.Call.invoke(
at pt.viatecla.k4t.k4t.AirFares.K4TAirFaresWSSoapStub.getFares(
at pt.viatecla.k4t.k4t.AirFares.K4TAirFaresWSTestCase.test1K4TAirFaresWSSoapGetFares(
Ulf Dittmer

Joined: Mar 22, 2005
Posts: 42965
Hello "yaoheng"-

Welcome to JavaRanch.

On your way in you may have missed that JavaRanch has a policy on display names, and yours does not comply with it - please adjust it accordingly, which you can do right here. Thanks for your prompt attention to this matter.

Enyoy your time here.
yaoheng zhang

Joined: Jun 04, 2004
Posts: 3
seems the date params cause the exception, but still don't know how to deal with it.

i send the data format like 01/10, the client works and web services return a error message said the invalid data. But if i send 2006/02/01, axis throws exceptions as it in the previous post.
I agree. Here's the link:
subject: a strange param of a WS
jQuery in Action, 3rd edition