|
__init__(filename,
dbhome,
create=0,
truncate=0,
mode=0600)
Open database name in the dbhome BerkeleyDB directory. |
|
|
|
|
|
|
|
|
|
|
|
_db_print(self)
Print the database to stdout for debugging |
|
|
|
CreateTable(self,
table,
columns)
CreateTable(table, columns) - Create a new table in the database. |
|
|
|
|
|
ListTables(self)
Return a list of tables in this database. |
|
|
|
|
|
__load_column_info(self,
table)
initialize the self.__tablecolumns dict |
|
|
|
__new_rowid(self,
table,
txn)
Create a new unique row identifier |
|
|
|
Insert(self,
table,
rowdict)
Insert(table, datadict) - Insert a new row into the table using the
keys+values from rowdict as the column values. |
|
|
|
Modify(self,
table,
conditions={ } ,
mappings={ } )
Modify(table, conditions={}, mappings={}) - Modify items in rows matching 'conditions' using mapping functions in 'mappings' |
|
|
|
Delete(self,
table,
conditions={ } )
Delete(table, conditions) - Delete items matching the given
conditions from the table. |
|
|
|
Select(self,
table,
columns,
conditions={ } )
Select(table, columns, conditions) - retrieve specific row data
Returns a list of row column->value mapping dictionaries. |
|
|
|
__Select(self,
table,
columns,
conditions)
__Select() - Used to implement Select and Delete (above) Returns a
dictionary keyed on rowids containing dicts holding the row data for
columns listed in the columns param that match the given conditions. |
|
|
|
Drop(self,
table)
Remove an entire table from the database |
|
|