X-Original-To: pgsql-odbc-postgresql.org@localhost.postgresql.org Received: from localhost (neptune.hub.org [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id E6B89D1D54E for ; Wed, 14 Jan 2004 09:06:53 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (neptune.hub.org [200.46.204.2]) (amavisd-new, port 10024) with ESMTP id 56014-01 for ; Wed, 14 Jan 2004 05:06:23 -0400 (AST) Received: from anchor-post-31.mail.demon.net (anchor-post-31.mail.demon.net [194.217.242.89]) by svr1.postgresql.org (Postfix) with ESMTP id C04C5D1B4A4 for ; Wed, 14 Jan 2004 05:06:21 -0400 (AST) Received: from mwynhau.demon.co.uk ([193.237.186.96] helo=mainbox.archonet.com) by anchor-post-31.mail.demon.net with esmtp (Exim 3.35 #1) id 1Aggyk-0003nx-0V; Wed, 14 Jan 2004 09:06:23 +0000 Received: by mainbox.archonet.com (Postfix, from userid 529) id DCE441758D; Wed, 14 Jan 2004 09:06:20 +0000 (GMT) Received: from client17.archonet.com (client17.archonet.com [192.168.1.17]) by mainbox.archonet.com (Postfix) with ESMTP id 7D90A1758B; Wed, 14 Jan 2004 09:06:18 +0000 (GMT) From: Richard Huxton To: Andreas , pgsql-odbc@postgresql.org Subject: Re: How to check if a connection is alive ? Date: Wed, 14 Jan 2004 09:06:18 +0000 User-Agent: KMail/1.5 References: <4004B79A.9030709@gmx.net> In-Reply-To: <4004B79A.9030709@gmx.net> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200401140906.19042.dev@archonet.com> X-Bogosity: No, tests=bogofilter, spamicity=0.000000, version=0.15.3 X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200401/21 X-Sequence-Number: 3650 On Wednesday 14 January 2004 03:29, Andreas wrote: > Hi, > > Access 2000 > Postgresql 7.4.1 > newest PG-ODBC > > how can I check if a DAO- or ADO-connection is still alive ? > I'd like to maintain a connection to a remote PG server within my VBA code. > It should be opend when the users start the application and closed when > the app terminates. You could have a timer that calls a function that just runs "SELECT true" or similar. If the query fails, you've lost your connection. Is that the sort of thing you meant? -- Richard Huxton Archonet Ltd