On 09/02/2016 03:08 AM, pyArchInit ArcheoImagineers wrote:
> On spatialite the column type Float remains Float, but in Postgres the > Column becomes Real. Postgresql doesn't use the word "Float" to represent the type. It accepts the word "float" to create the type, but depending on precision will resolve it to REAL or DOUBLE PRECISION. Thanks Mike for your reply. The precision is the same for spatialite and postgres because is the same class that create the table inside Postgres and Spatialite. And anything run properly. So now the problem is: How can I take a number from a spatialite column type float and save it into a Postgres column type real? Do you think is possible? What kind of convertion I need to do? Is these a way to take a float 2,2 type of number from spatialite and reconvert it to real 2,2 for postgres and viceversa?
not at all, in Python the value is a regular Python float for both cases. pass it off to each database driver and it will do whatever is needed to persist the data.
In other case I suppose I need to rebuild my DB structure using numeric type to mapping with only one class the two database (spatialite and postgres) Regards Luca -- You received this message because you are subscribed to the Google Groups "sqlalchemy" group. To unsubscribe from this group and stop receiving emails from it, send an email to sqlalchemy+unsubscr...@googlegroups.com <mailto:sqlalchemy+unsubscr...@googlegroups.com>. To post to this group, send email to sqlalchemy@googlegroups.com <mailto:sqlalchemy@googlegroups.com>. Visit this group at https://groups.google.com/group/sqlalchemy. For more options, visit https://groups.google.com/d/optout.
-- You received this message because you are subscribed to the Google Groups "sqlalchemy" group. To unsubscribe from this group and stop receiving emails from it, send an email to sqlalchemy+unsubscr...@googlegroups.com. To post to this group, send email to sqlalchemy@googlegroups.com. Visit this group at https://groups.google.com/group/sqlalchemy. For more options, visit https://groups.google.com/d/optout.