Opened 6 years ago
Closed 6 years ago
#3601 closed defect (fixed)
db.connect: default answers depend on current DB settings
Reported by: | mmetz | Owned by: | |
---|---|---|---|
Priority: | normal | Milestone: | 7.4.2 |
Component: | Database | Version: | svn-trunk |
Keywords: | database, connection | Cc: | |
CPU: | All | Platform: | All |
Description
The default answers depend on current DB connection settings.
Using GRASS defaults:
$ db.connect --help [...] Parameters: driver Name of database driver options: dbf,ogr,pg,sqlite default: sqlite database Name of database default: $GISDBASE/$LOCATION_NAME/$MAPSET/sqlite/sqlite.db schema Database schema group Default group of database users to which select privilege is granted
Now modify the default DB connection for the current mapset:
db.connect driver=pg database=mydb schema=grass_schema group=grass_group
New default answers:
$ db.connect --help [...] Parameters: driver Name of database driver options: dbf,ogr,pg,sqlite default: pg <-- !!! database Name of database default: mydb <-- !!! schema Database schema default: grass_schema <-- !!! group Default group of database users to which select privilege is granted default: grass_group <-- !!!
Consequently, resetting to GRASS default does not work:
$ db.connect -d Default driver / database set to: driver: sqlite database: /media/storage/GRASSsample_data/nc_spm_08/user1/sqlite/sqlite.db
followed by
$ db.connect -g driver=sqlite database=$GISDBASE/$LOCATION_NAME/$MAPSET/sqlite/sqlite.db schema=grass_schema <-- !!! group=grass_group <-- !!!
The confusion probably arises because there are two different default settings: the default settings as defined for the current mapset, and the GRASS default settings.
- the default answers for
db.connect
should always be the GRASS defaults - resetting to GRASS default connection settings with
db.connect -d
must work
Change History (5)
comment:1 by , 6 years ago
comment:5 by , 6 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Note:
See TracTickets
for help on using tickets.
In 72942: