Received: from makus.postgresql.org (makus.postgresql.org [98.129.198.125]) by mail.postgresql.org (Postfix) with ESMTP id 5CAAE143B1AE for ; Tue, 20 Mar 2012 19:19:05 -0300 (ADT) Received: from 30.55.colo.spiretech.net ([69.168.55.30] helo=lists.commandprompt.com) by makus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1SA7OR-00082M-No for pgsql-hackers@postgresql.org; Tue, 20 Mar 2012 22:19:04 +0000 Received: from clam (spinlock.commandprompt.com [69.168.55.30]) by lists.commandprompt.com (Postfix) with ESMTPA id 0D7FD92; Tue, 20 Mar 2012 15:19:39 -0700 (PDT) Received: from clam ([195.88.15.88] helo=clam) by assp.commandprompt.com with ESMTPS(AES128-SHA) (2.1.1); 20 Mar 2012 15:19:37 -0700 From: Alex To: Marko Kreen Cc: Daniel Farina , pgsql-hackers Subject: Re: Another review of URI for libpq, v7 submission References: <87d38eaq3f.fsf@commandprompt.com> <87k42lsgck.fsf@commandprompt.com> <20120317145110.GA25172@gmail.com> Date: Wed, 21 Mar 2012 00:18:44 +0200 In-Reply-To: <20120317145110.GA25172@gmail.com> (Marko Kreen's message of "Sat, 17 Mar 2012 16:51:10 +0200") Message-ID: <8762dyuda3.fsf@commandprompt.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Assp-Version: 2.1.1(11364) on assp.commandprompt.com X-Assp-Client-TLS: yes X-Assp-ID: assp.commandprompt.com m1-81979-08610 X-Assp-Envelope-From: ash@commandprompt.com X-Assp-Intended-For: pgsql-hackers@postgresql.org X-Assp-Original-Subject: Re: [HACKERS] Another review of URI for libpq, v7 submission X-Pg-Spam-Score: -1.1 (-) X-Archive-Number: 201203/1335 X-Sequence-Number: 205217 Marko Kreen writes: > On Thu, Mar 15, 2012 at 11:29:31PM +0200, Alex wrote: >> https://github.com/a1exsh/postgres/commits/uri > > The point of the patch is to have one string with all connection options, > in standard format, yes? So why does not this work: > > db = PQconnectdb("postgres://localhost"); > > ? Good catch. I've figured out that we'll need a bit more intrusive change than simply overriding the expand_dbname check in conninfo_array_parse (like the current version does) to support URIs in all PQconnect* variants. I still need to figure out some details, but this is to give people a status update. -- Alex