On Mon, Dec 06, 2010 at 05:25:43PM -0700, Tom Krehbiel scratched on the wall:
> The documentation for the analyze
> command says they can do a *select *on table *sqlite_stat1 *but when I do a
> select I get an error with 'no such table: sqlite_stat1'.
Like the table sqlite_sequence (used for AUTOINCREMENT), the
sqlite_statN tables are not created until they're needed. You need to
actually run the ANALYZE command at least once to create the
sqlite_statN tables.
Also, there can be more than one. If SQLite is compiled with the
SQLITE_ENABLE_STAT2 option, there will also be an sqlite_stat2 table,
to go along with the sqlite_stat1 table. In the future there may be
more.
> I haven't been able to find anything in the documentation that
> indicates how to get at the trigger definition.
They are in the sqlite_master table, just like everything else. As
far as I know, there is no trigger equivilant of PRAGMA table_info()
or PRAGMA index_info().
-j
--
Jay A. Kreibich < J A Y @ K R E I B I.C H >
"Intelligence is like underwear: it is important that you have it,
but showing it to the wrong people has the tendency to make them
feel uncomfortable." -- Angela Johnson
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users