in reply to Handling large numbers

As others have mentioned, Math::BigInt would do the trick, if you're doing everything in Perl. However, you've also used the words "SQL" and "Sybase" in your note, which makes me think otherwise....

Before anyone can render any kind of answer, you need to provide more information:

As you can see, there's a lot of variability possible. I'd be glad to help -- I work with Perl and Sybase on a daily basis -- but I really don't have enough to go on....