mirror of
https://github.com/optim-enterprises-bv/databunker.git
synced 2025-10-28 16:42:30 +00:00
fix query to load list of tables and added init scrips for postgresql
This commit is contained in:
@@ -123,8 +123,8 @@ func (dbobj *PGSQLDB) OpenDB(dbname *string) error {
|
||||
}
|
||||
dbobj.db = db
|
||||
// load all table names
|
||||
q := "show tables"
|
||||
tx, err := dbobj.db.Begin()
|
||||
q := "SELECT table_name FROM information_schema.tables where table_schema NOT IN ('pg_catalog', 'information_schema');"
|
||||
tx, err := dbobj.db.Begin()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user