I have a CGI file that dispatches requests to a PERL module using SOAP::Lite. I read (http://cookbook.soaplite.com/#soap%20faults) that if I use "die" from the PERL module, SOAP::Lite will package the string given to "die" as the SOAP faultstring and return it to the client. I know that my PERL module is returning the string because I have tested the module on the server side. However, something goes wrong after the module returns its output such that my client gets the following error message (if I add print "Content-type..." in the CGI file) minus the delimiting "**********":
**********
not well-formed (invalid token) at line 1, column 581, byte 581 at /us +r/lib/perl5/vendor_perl/5.8.0/i386-linux-thread-multi/XML/Parser.pm l +ine 185 Status: 500 Internal Server Error Content-Length: 747 Content-Type: text/xml; charset=utf-8 SOAPServer: SOAP::Lite/Perl/0.60 <?xml version="1.0" encoding="UTF-8"?> <SOAP-ENV:Envelope xmlns:xsi="http://www.w3.org/1999/XMLSchema-instanc +e" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:S +OAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http:/ +/www.w3.org/1999/XMLSchema" SOAP-ENV:encodingStyle="http://schemas.xm +lsoap.org/soap/encoding/"> <SOAP-ENV:Body> <SOAP-ENV:Fault> <faultcode>SOAP-ENV:Server</faultcode> <faultstring>ghrccatsvcs.cgi:GhrcCatSvcs:GhrcCatTableFields: ***Failed + to prepare SQL statement: ORA-00942: table or view does not exist ( +DBD ERROR: error possibly near <*> indicator at char 14 in 'SELECT * +FROM <*>amsu_sub_in WHERE 1 = 0') at GhrcCatSvcs.pm line 216. </faultstring> </SOAP-ENV:Fault></SOAP-ENV:Body></SOAP-ENV:Envelope> at dbq_client_fi +elds line 51
You can clearly see the "Failed to prepare SQL statement" faultstring embedded in the SOAP response, but all my client usually returns is "500 Internal Server Error at dbq_client_fields line 51. What am I doing wrong? Many thanks!
In reply to Client-side error Handling (SOAP,CGI) by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |