Re: [gnome-db] Microsoft SQL Server access via the FreeTDS Provider in libgda



Hello,


On Sun, Sep 08, 2002 at 10:49:44AM -0400, Daniel Morgan wrote:
> What is the status of accessing Microsoft SQL Server 7/2000 databases
> via
> the FreeTDS provider within libgda?

Theoretically works (uses core freetds api), but is untested.

The freetds provider supports connections and issuing queries at the
moment. The view queries/database query have to be corrected (just
tested sql part so far and hence forgot the master.. prefix producing 
an error on views selected when the master database is left). Also
database changing has to be added (e.g. DATABASE dsn is ignored; of 
course changing db works using the 'use' sql statement). I'm having
tests tomorrow, so i can begin fixing it around this weekend.

So far i can only test connections to Sybase ASE 11.9.2 from a Debian
client.

For using SQL Server 7.0, you should just replace the dsn parameters
TDS_MAJVER=4;TDS_MINVER=2 with TDS_MAJVER=7;TDS_MINVER=0 (or MAJVER=8 
for SQL Server 2000; though 7 should be fine) and change the other,
dsn params to suit to your environment (e.g. TDS_PORT, TDS_HOST,
TDS_QUERY).

You should be able to connect to the server (i.e. the default db
associated with the user) and issue sql commands then (theoretically
;-). For more details on determining the correct tds 
protocol version have a look at the freetds user guide.

Comments, suggestions and reports on environments working are welcome.

Regards
Holger
  <section path="/apps/libgda/Datasources/FreeTDS">
    <entry name="Provider" type="string" value="FreeTDS"/>
    <entry name="Username" type="string" value="dbtest"/>
    <entry name="Password" type="string" value="********"/>
    <entry name="DSN" type="string" value="DATABASE=master;TDS_HOST=sybase;TDS_QUERY=sybase;USER=dbtest;TDS_PORT=4100;TDS_MAJVER=4;TDS_MINVER=2;PASSWORD=********"/>
    <entry name="Description" type="string" value="sybase ase 11.9.2 via freetds tds version 4.2"/>
  </section>


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]