On Nov 4, 2005, at 9:27 AM, Paul McNett wrote:

Everything in sqlite storage is a string, but it doesn't get exposed to Python that way does it? IOW, if I do a:

CREATE TABLE customers (id int, companyname char(64), creditlimit decimal(10,2))

...The fact that those "types" get stored in the db as strings doesn't get in the way of the fact that in Python they come from the dbapi as int, string, and decimal. At least that's the way I understand it - I haven't actually tried it.

Seems like based on my first few tests, PySQLite doesn't handle Decimal at all; I get the error: "pysqlite2.dbapi2.InterfaceError: Error binding parameter 1 - probably unsupported type.". If I change that value to a float, it works, but I get back a float. It also totally hoses dates, but I saw on the pysqlite website that there are converter routines for datetimes, so maybe there are some for date values, too.

Sure, we may have to create/remove temp files, but that is no big deal. There's a whole python module for managing such things for you.

That requirement just disappeared. I learned that you can do conn=dbapi.connect(":memory:") to create an in-memory database. No disk presence required, and perfect for what we would need.

Regarding the installation requirement, that's just par for the course. Things are required. When we package Dabo, we can package sqlite with it. We just haven't gotten to the point yet of thinking about packaging issues.

I'll look into this further, then. The stuff I created works great for what I had in mind, but I agree that trying to make a full SQL implementation is a waste of time, and once you let people do simple stuff with DataSets, they'll want to do more!


-- Ed Leafe
-- http://leafe.com
-- http://dabodev.com




_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-dev

Reply via email to