0
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
1 0 - install pysqlite2
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
2
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
3 On Debian GNU/Linux just do:
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
4
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
5 # apt-get install python-pysqlite2
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
6
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
7 1 - create new time.db
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
8
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
9 To create an empty database you need the 'sqlite3'
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
10 commandline tool. TODO: This will change.
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
11
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
12 # apt-get install sqlite3
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
13
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
14 $ echo '.r schema.sql' | sqlite3 time.db:
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
15
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
16 2 - adding new projects to time.db:
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
17
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
18 $ sqlite3 time.db
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
19 sqlite> INSERT INTO projects (key, description) VALUES ('f', 'FOO');
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
20 sqlite> INSERT INTO projects (key, description) VALUES ('b', 'BAR');
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
21 sqlite> .q
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
22
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
23 3 - starting getan:
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
24
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
25 $ ./getan
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
26
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
27 or
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
28
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
29 $ ./getan mytime.db
|
Sascha L. Teichmann <teichmann@intevation.de>
parents:
diff
changeset
|
30
|