Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lUOrb-0006P6-IP for pgsql-hackers@arkaria.postgresql.org; Thu, 08 Apr 2021 07:14:03 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1lUOra-000234-7D for pgsql-hackers@arkaria.postgresql.org; Thu, 08 Apr 2021 07:14:02 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lUOrZ-0001yV-FE for pgsql-hackers@lists.postgresql.org; Thu, 08 Apr 2021 07:14:02 +0000 Received: from [66.111.4.238] (helo=forward4-smtp.messagingengine.com) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lUOrW-00028d-J1 for pgsql-hackers@lists.postgresql.org; Thu, 08 Apr 2021 07:14:00 +0000 Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailforward.nyi.internal (Postfix) with ESMTP id B33D01940953; Thu, 8 Apr 2021 03:13:47 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute3.internal (MEProxy); Thu, 08 Apr 2021 03:13:47 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm2; bh=WvzvJAcIsKU/+fzY/k8WxdXOrI15/dzAbsn0jkHqZ JY=; b=pHIj+f7vFnOw8xafVIUtYNbG/0O8eO7FpDn+4T2pOhuqCNW+V0EMBfnUN AfH9zWQFBUNfw98u9xftPNjdokl4YhMj/TejX5CE0icmIVWL21FLkDUfXs/KfFKZ 7dGvYkUdU2/17KebisBNtCYJOPix/k1X07YO69U79lY+KfEcboRT5CGl84Bvq5E/ NfNoWEC501FXiHKnDJL8j845yISoP3LtJfkDm5Yfj0gEKG22QR/ECwkX5Ege9cuG YmZUp00pK8V+WhypxPM3oOsKckvfZBboWGe7hZ4YT53+U04kqKZbzI67kU+OXgyP cAzDmIONwZsyFg1rdK0cLGjirNwyA== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduledrudejkedguddujecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfgh necuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmd enucfjughrpefuvfhfhffkffgfgggjtgfgsehtjeertddtfeejnecuhfhrohhmpefrvght vghrucfgihhsvghnthhrrghuthcuoehpvghtvghrrdgvihhsvghnthhrrghuthesvghnth gvrhhprhhishgvuggsrdgtohhmqeenucggtffrrghtthgvrhhnpeelveehheeuieduieet iedtkeeuteelfeetjeffieffudegvdffvdfftdeivdeukeenucfkphepleefrddvtddvrd dvheefrddugeefnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhf rhhomhepphgvthgvrhdrvghishgvnhhtrhgruhhtsegvnhhtvghrphhrihhsvggusgdrtg homh X-ME-Proxy: Received: from laptop206oxuk.local (p5dcafd8f.dip0.t-ipconnect.de [93.202.253.143]) by mail.messagingengine.com (Postfix) with ESMTPA id 60F2E24005A; Thu, 8 Apr 2021 03:13:45 -0400 (EDT) Subject: Re: Support tab completion for upper character inputs in psql To: "tanghy.fnst@fujitsu.com" , David Zhang , Kyotaro Horiguchi , Tom Lane Cc: "pgsql-hackers@lists.postgresql.org" References: <457958.1612724100@sss.pgh.pa.us> <20210208.170212.1547983279045749071.horikyota.ntt@gmail.com> <696766648c7a4266864f843b0e4140dd@G08CNEXMBPEKD05.g08.fujitsu.local> <5f225addccc54478a6436b78423f21be@G08CNEXMBPEKD05.g08.fujitsu.local> <24171b05-cf0f-3073-a73a-57b45b794049@enterprisedb.com> <3140db2a-9808-c470-7e60-de39c431b3ab@highgo.ca> From: Peter Eisentraut Message-ID: Date: Thu, 8 Apr 2021 09:13:44 +0200 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:78.0) Gecko/20100101 Thunderbird/78.9.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Host-Lookup-Failed: Reverse DNS lookup failed for 66.111.4.238 (deferred) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 01.04.21 11:40, tanghy.fnst@fujitsu.com wrote: > On Wednesday, March 31, 2021 4:05 AM, David Zhang wrote > >> 8 postgres=# update tbl SET DATA = >> 9 >> 10 postgres=# update TBL SET >> 11 >> 12 postgres=# >> >> So, as you can see the difference is between line 8 and 10 in case 2. It >> looks like the lowercase can auto complete more than the uppercase; >> secondly, if you can add some test cases, it would be great. > > Thanks for your test. I fix the bug and add some tests for it. > Please find attached the latest patch V4. > > Differences from v3 are: > * fix an issue reported by Zhang [1] where a scenario was found which still wasn't able to realize tap completion in query. > * add some tap tests. Seeing the tests you provided, it's pretty obvious that the current behavior is insufficient. I think we could probably think of a few more tests, for example exercising the "If case insensitive matching was requested initially, adjust the case according to setting." case, or something with quoted identifiers. I'll push this to the next commit fest for now. I encourage you to keep working on it.