January 2000
Intermediate to advanced
672 pages
21h 46m
English
Like many SQL databases, Gadfly maintains metadata in tables, and you can query the structure of a Gadfly database:
>>> cursor = connection.cursor() >>> cursor.execute('SELECT * FROM __table_names__') >>> print cursor.pp() IS_VIEW | TABLE_NAME ========================= 0 | EMPTY 1 | NONDRINKERS 1 | ALLDRINKERS 1 | __INDICES__ 1 | DUAL 0 | LIKES 0 | FREQUENTS 0 | ACCESSES 0 | WORK 1 | __TABLE_NAMES__ 0 | SERVES 1 | __DATADEFS__ 1 | __COLUMNS__ 1 | __INDEXCOLS__ >>>
Apart from the data tables, you can inspect metatables of tables, indexes, and columns in this manner.