Due to mathematica constraints I've to use the BigInteger class to represent values.
After some calculations I would like to store the result (given by 2x BigInteger instances) into Mysql...
What is the best datatype to store such object ?
I was thinking about using a Blob to store the binary format of those results (128 bits) ? But I would like to avoid unnecessary type conversions.
I would recommend using a Blob and then the BigInteger(byte[] val)
constructor to go from byte array to BigInteger, and the BigInteger#toByteArray()
method for the other way.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With