Thread: ODBC include files
Can someone explain the status of the include files that we currently install with the ODBC driver: iodbc.h, isql.h, isqlext.h? Currently, these clash with the include files that the actual iodbc package installs. Their isql.h also contains the note /* * This file is deprecated in favor of sql.h and will be removed * sometime in the future. Please recode your applications to use * the standard names sql.h, sqlext.h and sqltypes.h. */ I also see that our isqlext.h includes isql.h without an iodbc/ path prefix, which seems incorrect. Is there something that might need updating here? If I were to write an ODBC application, which package's files should I include? -- Peter Eisentraut peter_e@gmx.net http://funkturm.homeip.net/~peter
Peter Eisentraut wrote: > > Can someone explain the status of the include files that we currently > install with the ODBC driver: iodbc.h, isql.h, isqlext.h? Currently, > these clash with the include files that the actual iodbc package installs. > Their isql.h also contains the note > > /* > * This file is deprecated in favor of sql.h and will be removed > * sometime in the future. Please recode your applications to use > * the standard names sql.h, sqlext.h and sqltypes.h. > */ I've also noticed it. Probably we had better use sql.h and sqlext.h but I'm suspicious if it's worth maintaining. > > I also see that our isqlext.h includes isql.h without an iodbc/ path > prefix, which seems incorrect. Sorry where's iodbc/ ? > > Is there something that might need updating here? If I were to write an > ODBC application, which package's files should I include? IMHO you should include iodbc package's files. regards, Hiroshi Inoue
Hiroshi Inoue writes: > > I also see that our isqlext.h includes isql.h without an iodbc/ path > > prefix, which seems incorrect. > > Sorry where's iodbc/ ? If you install the odbc driver from the source distribution then the said headers are installed into /usr/local/pgsql/include/iodbc/*.h. So if you blindly do -I/usr/local/pgsql/include and #include "iodbc/isqlext.h" you won't find isql.h (or worse, the wrong one). I think this is the remnant of an improper import of the odbc driver into out our source tree way back when. > > Is there something that might need updating here? If I were to write an > > ODBC application, which package's files should I include? > > IMHO you should include iodbc package's files. Perhaps we should not install ours at all in that case? The iodbc ones seem better maintained and you need to have iodbc anyway. -- Peter Eisentraut peter_e@gmx.net http://funkturm.homeip.net/~peter
> -----Original Message----- > From: Peter Eisentraut [mailto:peter_e@gmx.net] > > Hiroshi Inoue writes: > > > > I also see that our isqlext.h includes isql.h without an iodbc/ path > > > prefix, which seems incorrect. > > > > Sorry where's iodbc/ ? > > If you install the odbc driver from the source distribution then the said > headers are installed into /usr/local/pgsql/include/iodbc/*.h. Oh I see. Hmm for what are these files installed ? Direct call for psqlodbc driver ? Is it really needed ? > So if you > blindly do -I/usr/local/pgsql/include and #include "iodbc/isqlext.h" you > won't find isql.h (or worse, the wrong one). I think this is the remnant > of an improper import of the odbc driver into out our source tree way back > when. > > > > Is there something that might need updating here? If I were > to write an > > > ODBC application, which package's files should I include? > > > > IMHO you should include iodbc package's files. > > Perhaps we should not install ours at all in that case? Yes I think so. Driver manager isn't only for PostgreSQL. > The iodbc ones > seem better maintained and you need to have iodbc anyway. I'm happy if someone(you ?) maintains psqlodbc on unix. I got few replies from PG community about psqlodbc on unix. I've been wondering how many people are using psqlodbc driver on unix in reality. Switching to unixODBC is worth considering as an alternative. regards, Hiroshi Inoue
Hiroshi Inoue writes: > > Perhaps we should not install ours at all in that case? > > Yes I think so. Driver manager isn't only for PostgreSQL. Consider them gone. > I'm happy if someone(you ?) maintains psqlodbc on unix. I don't think I'm qualified. > I got few replies from PG community about psqlodbc on unix. > I've been wondering how many people are using psqlodbc > driver on unix in reality. Switching to unixODBC is worth > considering as an alternative. I'm talking to the unixODBC maintainer about working with us. The PostgreSQL unixODBC driver was a fork from the psqlodbc driver and he has always been interested in converging. -- Peter Eisentraut peter_e@gmx.net http://funkturm.homeip.net/~peter