[GRASS5] DBMI-ODBC
John Huddleston
jhuddles at rocky.itc.nrcs.usda.gov
Tue May 2 10:30:47 EDT 2000
Markus,
FYI, I have successfully built unixODBC-1.8.7
for Windows NT using the Cygnus Toolset B20.1
John Huddleston
----- Original Message -----
From: Radim Blazek <Radim.Blazek at dhv.cz>
To: <grass5 at geog.uni-hannover.de>
Sent: Tuesday, May 02, 2000 6:43 AM
Subject: [GRASS5] DBMI-ODBC
> Hi,
> (sorry if you received this twice, Markus Neteler recommended me to send
it here too)
>
> I work on ODBC (http://www.unixodbc.org/) driver for DBMI (src/libes/dbmi)
> + some modules based on DBMI.
> Work is not finished but most of old modules (src/libes/dbmi/clients) and
new
> v.db.reclass run.
>
> I want discuss following list of changes before commiting to CVS:
>
> - add to src/include/dbmi.h structures:
>
> typedef struct _db_connection
> {
> char *driverName;
> char *databaseName;
> char *location;
> char *user;
> char *password;
> char *keycol; // name of default key column
> }dbConnection;
>
> typedef struct
> {
> int count; // number of defined rules
> int alloc; // size of allocated array
> char *table; // table name
> char *key; // key column name
> int *cat; // array of new category numbers
> char **where; // array of SQL WHERE conditions
> char **label; // array of new category labels
> }dbRclsRule;
>
>
> - add to DBMILIB functions:
>
> int db_set_connection (dbConnection *connection );
> int db_get_connection (dbConnection *connection );
> void db_rcls_rule_extend (dbRclsRule *rule , int n );
> dbRclsRule * db_rcls_rule_init (int n );
> int db_rcls (dbRclsRule *rule , CatValI
**new );
>
>
> - add to /src/libes/dbmi/lib/start.c reading from dbConnection if driver
> was not specified
>
>
> - modify command parameters in src/libes/dbmi/clients modules
> to not required if defined in dbConnection (use default)
>
>
> - change in src/libes/dbmi/clients/Gmakefile:
> HOME=$(GISBASE)/etc/dbmi/bin
> to
> HOME=$(GISBASE)/etc/bin/main/cmd
> and remove
> if [ ! -d $(GISBASE)/etc/dbmi ]; then mkdir $(GISBASE)/etc/dbmi; fi; \
> if [ ! -d $(HOME) ]; then mkdir $(HOME); fi;
>
>
> - add src/libes/dbmi/drivers/odbc - ODBC driver
>
>
> - add src/libes/dbmi/clients/db.connect - similar as g.select.pg but
> module name db.select is already used, problem: password is saved
> in file
>
>
> - add src/mapdev/v.db.reclass
>
>
> - add to VECTLIB_REAL functions for reclassification - may be used in
future also
> by v.reclass (I am not satisfied with creating reclass file and running
> v.reclass
> from DB reclass modules):
>
> int V_rcls_line (char *in_name, char *out_name, CatValI *new, int ncat,
int
> append);
> int V_rcls_area (char *in_name, char *out_name, CatValI *new, int ncat,
int
> append, int dissolve);
>
>
> - add to src/include/gis.h structures for storing values for cats
> ( new category value, number of elements in cat, area, length, x,y, ...)
>
> typedef struct
> {
> int min,max; // array range
> int *val; // array of integers
> }CatValI;
>
> typedef struct
> {
> int min,max; // array range
> double *val; // array of doubles
> }CatValD;
>
>
> - add to GISLIB functions:
>
> CatValI *G_catvali_init( int min, int max);
> void G_catvali_extend( CatValI *, int max);
>
>
> Radim
>
> ----------------------------------------
> If you want to unsubscribe from GRASS Development
> Team internal mailing list write to:
> minordomo at geog.uni-hannover.de with
> subject 'unsubscribe grass5'
> length: 3835
> max: 0
----------------------------------------
If you want to unsubscribe from GRASS Development
Team internal mailing list write to:
minordomo at geog.uni-hannover.de with
subject 'unsubscribe grass5'
length: 5084
max: 0
More information about the grass-dev
mailing list