X-Original-To: pgsql-odbc-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 010AA329EB9 for ; Wed, 8 Sep 2004 08:22:20 +0100 (BST) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 46372-06 for ; Wed, 8 Sep 2004 07:22:12 +0000 (GMT) Received: from anchor-post-32.mail.demon.net (anchor-post-32.mail.demon.net [194.217.242.90]) by svr1.postgresql.org (Postfix) with ESMTP id 40A87329EC7 for ; Wed, 8 Sep 2004 08:22:09 +0100 (BST) Received: from mwynhau.demon.co.uk ([193.237.186.96] helo=mainbox.archonet.com) by anchor-post-32.mail.demon.net with esmtp (Exim 3.35 #1) id 1C4wmO-000EXi-0W; Wed, 08 Sep 2004 07:22:08 +0000 Received: from [192.168.1.17] (client17.archonet.com [192.168.1.17]) by mainbox.archonet.com (Postfix) with ESMTP id 1C6E8168D0; Wed, 8 Sep 2004 08:22:07 +0100 (BST) Message-ID: <413EB31E.5070500@archonet.com> Date: Wed, 08 Sep 2004 08:22:06 +0100 From: Richard Huxton User-Agent: Mozilla Thunderbird 0.7 (X11/20040615) X-Accept-Language: en-us, en MIME-Version: 1.0 To: lchan Cc: mombasa@ptolemy.arc.nasa.gov, quit Nguyen , pgsql-odbc@postgresql.org Subject: Re: new to Unixodbc: can't connect to Postgresql References: <55fe1952.0409021316.7eea93f8@posting.google.com> <413829A1.5010309@archonet.com> <6.1.0.6.0.20040907142637.028725b0@mail.arc.nasa.gov> In-Reply-To: <6.1.0.6.0.20040907142637.028725b0@mail.arc.nasa.gov> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests= X-Spam-Level: X-Archive-Number: 200409/12 X-Sequence-Number: 4387 lchan wrote: > Hi Richard, > Thank you for responding to my plea for help. No problem - please try to keep the mailing list cc'ed - there are smarter people than me on it. >> 1. Make sure you are logging connection attempts in postgresql.conf >> and see if anything is happening there. > > I have double checked the postgresql.conf file. There's only a trace > file produced, and it's a SQLERROR -2 (SQL_INVALID_HANDLE). This is the odbc logs - we also want to look at the postgresql logs. Their location is usually defined in your postgresql startup script. > Pasted > below is my postgres.conf file. I would be very grateful if you let me > know, if > you spot anything that's incorrect. Where is postgresql logging to? Find out, then add the following lines to your postgresql.conf: log_connections=true log_statement=true Restart postgresql and this will then log every connection and every SQL statement you send. Connect using "psql -h localhost -U myuser mydatabase", you should be asked for your password and get a prompt. Check the logs to make sure the successful connection is logged. Then try to connect via odbc and see what the postgresql logs say. -- Richard Huxton Archonet Ltd