Thread: Can;t connect to db with pgaccess
Downloaded the latest pgacess. Looks pretty neat. Unfortunatley it will not connect to my 6.3 database. Thinking that it might be a cnfiguration problem on this database (it has bee in service for over a year now). I donwloade the Debian package, and set up a test database on the Debian box. Still mo go. Do I have to set up the access control file in some special way to get this going? -- Stan Brown stanb@netcom.com 770-996-6955 Factory Automation Systems Atlanta Ga. -- Windows 98: n. minor patch release for 32-bit extensions and a graphical shell for a 16-bit patch to an 8-bit operating system originally coded for a 4-bit microprocessor, written by a 2-bit company that can't stand for 1 bit of competition. - (c) 1998 Stan Brown. Redistribution via the Microsoft Network is prohibited.
Stan Brown wrote: > > Downloaded the latest pgacess. Looks pretty neat. Unfortunatley it will > not connect to my 6.3 database. Thinking that it might be a > cnfiguration problem on this database (it has bee in service for over > a year now). I donwloade the Debian package, and set up a test database > on the Debian box. Still mo go. PgAccess 0.93 will work fine on PostgreSQL 6.4 and higher. Due to some enhancements made in libpgtcl, there is another option to pg_result (-error) that does not exist in PosgreSQL 6.3.x So, in order to make PgAccess 0.93 work with PostgreSQL 6.3.x you should : replace in procedure wpg_exec the following line: set pgsql(errmsg) [pg_result $pgsql(res) -error] with this one : set pgsql(errmsg) "NO ERROR INFORMATION SUPPLIED" And it will work fine! In some error cases, you will not get the appropriate error message from libpgtcl. Best wishes for the next year, -- Constantin Teodorescu FLEX Consulting Braila, ROMANIA
Constantin Teodorescu <teo@flex.ro> writes: > Stan Brown wrote: >> Downloaded the latest pgacess. Looks pretty neat. Unfortunatley it will >> not connect to my 6.3 database. > PgAccess 0.93 will work fine on PostgreSQL 6.4 and higher. > Due to some enhancements made in libpgtcl, there is another option to > pg_result (-error) that does not exist in PosgreSQL 6.3.x I think Stan's problem is at a lower level than that: 6.4 libpq will not talk to a pre-6.4 server, period. (It wants the 2.0 version of the FE-to-BE protocol, which the older servers don't offer. The other way around, new server and old client, is no problem.) 6.4 libpgtcl won't work without 6.4 libpq, either. You could put the PgAccess 0.93 Tcl code atop a 6.3.x libpgtcl and libpq, and then it'd talk to older servers. I dunno whether the "-error" change that Constantin mentions is the only change that would be needed in the Tcl code. It'd probably be a more profitable use of your time to upgrade to a 6.4(.1) server. My experience is that 6.4 is a good deal more stable than 6.3.x... regards, tom lane
Tom Lane wrote: > > Constantin Teodorescu <teo@flex.ro> writes: > > Stan Brown wrote: > >> Downloaded the latest pgacess. Looks pretty neat. Unfortunatley it will > >> not connect to my 6.3 database. > > > PgAccess 0.93 will work fine on PostgreSQL 6.4 and higher. > > Due to some enhancements made in libpgtcl, there is another option to > > pg_result (-error) that does not exist in PosgreSQL 6.3.x > > I think Stan's problem is at a lower level than that: 6.4 libpq will not > talk to a pre-6.4 server, period. (It wants the 2.0 version of the > FE-to-BE protocol, which the older servers don't offer. The other way > around, new server and old client, is no problem.) There were a lot of messages that I received with this problem. A lot of people have PostgreSQL 6.3.2 distribution working fine with PgAccess 0.90 or prior, and when they upgrade to 0.93, it won't work. They have the right libpq+libpgtcl couple for their postgres, but libpgtcl prior to 6.4 does not have the -error option in pg_result. > It'd probably be a more profitable use of your time to upgrade to > a 6.4(.1) server. My experience is that 6.4 is a good deal more > stable than 6.3.x... That's true. I'm truly excited about 6.4.x and so on. It gives me confidence and courage to work on big projects with it. -- Constantin Teodorescu FLEX Consulting Braila, ROMANIA