1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58
|
Using Gaby as a frontend to SQL servers
=======================================
[note: this currently only works with PostgreSQL but the plan is to extend
the support to other servers as well (perhaps through libgda)]
[note2: this is a planned feature for Gaby 2.2; it won't be further developed
in this stable serie]
Why ?
-----
- ...
Why not ?
---------
- not finished, not tested
- ...
How ?
-----
Compiling
---------
./configure --enable-postgresql
(packages needed: (Debian) libpgsql2, postgresql-dev)
Using
-----
The database name should be the same as your descfile name. Example:
desc.gabysql -> database: gabysql
Create a SQL database with the same fields as your descfile (+ one primary key
as first field (named 'id')). Example:
gabysql=> \d zip
Table "zip"
Attribute | Type | Modifier
-----------+-------------+----------
id | integer | not null
zip | varchar(10) |
city | varchar(50) |
Index: zip_pkey
Every fields should be varchar() (no support for dates, integer, ...).
[UPDATE (20001118): some new support has been added and dates seems to be
supported]
There is a script in ../misc/ (create_sql_from_desc.py) that tries to
generate proper CREATE SQL instructions but there are no warranties...
(as if there were any warranties in general...)
Random comments
---------------
- starting with a usual descfile will core dump. (ie gaby won't work, you have
to run gaby --as gabysql (or whatever)). It would be cool to be able to use
normal desc files and gaby would see no sql database exists and create it
automatically...
- ...
--
Frederic Peters - Sun, 19 Nov 2000 00:02:00 +0100
|