The good news...

I have finished the new DAL for RDBMs. If you now replace gluon/sql.py
with gluon/dal.py as long as you do not use GAE, everything should
work fine. All tests pass.

The new dal should have all the features as the old dal but no more.
It just comes with a better more modular design that will allow adding
new features.

It defines the following classes:

class ConnectionPool(object):
class BaseAdapter(ConnectionPool):

# adapters
class SQLiteAdapter(BaseAdapter):
class JDBCSQLiteAdapter(SQLiteAdapter):
class MySQLAdapter(BaseAdapter):
class PostgreSQLAdapter(BaseAdapter):
class JDBCPostgreSQLAdapter(PostgreSQLAdapter):
class OracleAdapter(BaseAdapter):
class MSSQLAdapter(BaseAdapter):
class MSSQLAdapter2(MSSQLAdapter):
class FireBirdAdapter(BaseAdapter):
class FireBirdEmbeddedAdapter(FireBirdAdapter):
class InformixAdapter(BaseAdapter):
class DB2Adapter(BaseAdapter):
class IngresAdapter(BaseAdapter):
class IngresUnicodeAdapter(IngresAdapter):

# exposed by DAL
class Row(dict):
class SQLCallableList(list):
class DAL(dict):
class SQLALL(object):
class Reference(int):
class Table(dict):
class Expression(object):
class SQLCustomType:
class Field(Expression):
class Query(object):
class Set(object):
class Rows(object):

TODO:

1)
test dal.py
test dal.py
test dal.py

2)
break gluon/dal.py into
   gluon/dal/__init__.py
   gluon/dal/pooling.py
   gluon/dal/adapter_base.py
   gluon/dal/adapter_*.py

3)
reimplement gluon/contrib/gql.py as
   gluon/dal/adapter_nosql.py
   gluon/dal/adapter_gae.py

4)
implement
   gluon/dal/adapter_mongodb.py
   etc.

Can you help with 1) and 2)?

Massimo

Reply via email to