Skip site navigation (1) Skip section navigation (2)


From: "Graham Vickrage" <graham(at)digitalplanit(dot)com>
To: <pgsql-interfaces(at)postgresql(dot)org>
Subject: VB and ODBC
Date: 2001-04-27 11:17:52
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-interfaces
I am a new to ODBC and relatively new to VB. I am trying to make a
connection to a postgres 7.0 DB from word via a VB macro. I think I have
installed the ODBC driver correctly (win98) and am trying to make a
connection via the VB module using the following.

Sub ClientOrder()
    With ActiveDocument.MailMerge
        .MainDocumentType = wdFormLetters
        constr = "DSN=PostgreSQL;" _
                 & "FIL=RedISAM;"
       .OpenDataSource Name:="dbname", _
       Connection:=constr, SQLStatement:="SELECT Client_order_id FROM
    End With
End Sub

This does not work I think because of the .OpenDataSource Name:="dbname". In
other examples (ie access) it points directly the the DB File ie
'c:/somefile.mdb'. How would this work for postgres, is there an equivilant
on the linux box (I think not). Or could someone point me to some examples
of this.

Thanks in advance


pgsql-interfaces by date

Next:From: Alexey NalbatDate: 2001-04-27 12:50:21
Subject: Re: can external C-function get multiple rows?
Previous:From: Shane HansenDate: 2001-04-26 17:13:32
Subject: persistent connection with c++

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group