Forum BigDB Change type from Double to Int/Int to Double

Discussion and help relating to the PlayerIO database solution, BigDB.

Change type from Double to Int/Int to Double

Postby wbsaputra » August 21st, 2011, 11:33 am

Need a little help to change player object type from Int to Number(As3) and Int to Double (c#).
also how can i create default player object with Number type(as3) or double type(c#).
I dont know why some times some other object has int type and double type.
How can i change all player object that has int type to double type in code and make sure all have the same type,
do i have to do it manually? oh no i got around 300k player. Anyone help me :cry:
wbsaputra
Paid Member
 
Posts: 150
Joined: June 29th, 2010, 4:38 pm

Re: Change type from Double to Int/Int to Double

Postby Oliver » August 29th, 2011, 9:48 pm

There is no way to:
- change existing properties on all objects at once
- setup up default properties for bigdb objects (however, you can use the default-argument for most of the getxxx() methods to specify a default value returned if the property does not exist)

You have to work with the data that is written to the objects.
If you write an integer to a BigDB objects, you have to read it out as an integer.

As far as i know, the AS3 client will write whole numbers as integers and decimal numbers as Number, which is probably why you´re seeing the issue.

Best way to move forward is to add some code that handles the differences.

Oliver
User avatar
Oliver
.IO
 
Posts: 1159
Joined: January 12th, 2010, 8:29 am


Return to BigDB



cron