1grass-sqlite(1) GRASS GIS User's Manual grass-sqlite(1)
2
3
4
6 The SQLite driver is the default DBMI backend.
7
9 GRASS is automatically creating the SQLite database if it is not yet
10 existing when the first table is created in the SQLite database. It is
11 sufficient to define the connection (see next step).
12
14 The database name ’sqlite.db’ is at user’s choice. Also the file stor‐
15 age location can be freely chosen. If the database does not exist, it
16 will be automatically created when database content is created:
17 # example for storing DB in mapset directory (keep single quotes):
18 db.connect driver=sqlite database=’$GISDBASE/$LOCATION_NAME/$MAPSET/sqlite/sqlite.db’
19 db.connect -p
20
22 All SQL commands supported by SQLite (for limitations, see SQLite help
23 page: SQL As Understood By SQLite and Unsupported SQL).
24
26 All SQL operators supported by SQLite.
27
29 A convenient SQLite front-end is sqlitebrowser. To open a DB file
30 stored within the current mapset, the following way is suggested (cor‐
31 responds to above database connection):
32 # fetch GRASS variables as shell environment variables:
33 eval `g.gisenv`
34 # use double quotes:
35 sqlitebrowser "$GISDBASE/$LOCATION_NAME/$MAPSET"/sqlite/sqlite.db
36
38 db.connect, db.execute, db.select
39 SQL support in GRASS GIS
40 SQLite web site, SQLite manual, sqlite - Management Tools
41
42 Main index | Topics index | Keywords index | Graphical index | Full in‐
43 dex
44
45 © 2003-2023 GRASS Development Team, GRASS GIS 8.2.1 Reference Manual
46
47
48
49GRASS 8.2.1 grass-sqlite(1)