Integer question

This is a discussion on Integer question within the PHP General forums, part of the PHP Programming Forums category; When dealing with large numbers inside of php, I know at the int limit, a variable is recast into float. ...


Go Back   Usenet Forums > PHP Programming Forums > PHP General

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 03-22-2007
Matt Carlson
 
Posts: n/a
Default Integer question

When dealing with large numbers inside of php, I know at the int limit, a variable is recast into float.



1). How do you return the true number of the float when it reaches the upper limits of mysql's bigint (9223372036854775807).

2). How do you handle numbers that large, while maintaining precision.
3). Is there a php equivalent of unsigned?

Thanks all




Reply With Quote
  #2 (permalink)  
Old 03-22-2007
Tijnema !
 
Posts: n/a
Default Re: [PHP] Integer question

On 3/22/07, Matt Carlson <saryon@swbell.net> wrote:
> When dealing with large numbers inside of php, I know at the int limit, a variable is recast into float.
>
>
>
> 1). How do you return the true number of the float when it reaches the upper limits of mysql's bigint (9223372036854775807).
>
> 2). How do you handle numbers that large, while maintaining precision.
> 3). Is there a php equivalent of unsigned?
>
> Thanks all
>


Hmm, better have a look at the gmp functions : www.php.net/gmp
if you don't have the gmp math library installed, you might want to
look at the worses alternative bcmath, which is automatically build
into php: www.php.net/bc

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

Reply With Quote
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 06:49 AM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0