Re: PHP SOAP, ADODB, MySQL and BigInt problem

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 29 Jul 2008, Peter Beckman wrote:

I have bigints in my MySQL DB (full international-style phone numbers, such
as 12125004000).  I want to return these via a SOAP API I'm working on.

 I was able to solve the problem.  Turns out there were two issues.

 1. Caching was turned on, so the WSDL was cached, which meant that on-disk
    changes were not reflected after the first WSDL read, and thus changes to
    variable types were not being recached.  One (I) would think that the
    caching mechanism would be intelligent enough to at least do a check of
    the last_modified time on the WSDL and the cached file, and if the
    original file was greater, recache.  Oh well.

 2. After googling some more on xsd:int and other variable types, I tried
    what I thought would be correct, xsd:long.  But again, same problem.  I
    finally found enlightenment after reading the soap.constants.php page,
    and clicking on the hyperlinked "integer" which showed that numbers
    larger than 2147483647 resulted in PHP outputting the correct number,
    but typecasted as a float, not an int.

 When I changed my WSDL element type to xsd:float, all was well with the
 world again.

---------------------------------------------------------------------------
Peter Beckman                                                  Internet Guy
beckman@angryox.com                                 http://www.angryox.com/
---------------------------------------------------------------------------

--
PHP Soap Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [PHP Users]     [Kernel Newbies]     [PHP Database]     [Yosemite]

  Powered by Linux