[Qgis-developer] Strange integer column value within SpatiaLite database
Rui Pedro Henriques
henriques.rui at gmail.com
Tue Dec 11 06:05:09 PST 2012
Hi,
the same thing happens here. Using Sqliteman the value looks OK but when
using QGis Attribute table it turns into the strange value.
Is suspected it had to do with an int (32) conversion and so made a
small C test to confirm. If you run the C test in the linked ZIP you'll
get the following result when trying to pass 9100100101 as an integer:
(Sorry it's in Portuguese but it asks for an integer number and then
prints it)
Digite um número: 9100100101
O int é 510165509
I've also made another test in python to read the table, but python
automatically uses long when the value is unsuitable for int. That was
the result I got: the value looks OK but it's type is long, not integer.
In the link: the C test, the python test and the error print.
Tests: http://ubuntuone.com/4eQMOLf4KvlAbYHKxkqBIY
Cheers,
Rui.
More information about the Qgis-developer
mailing list