Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eZl53-0001x0-A8 for pgsql-general@arkaria.postgresql.org; Thu, 11 Jan 2018 22:12:13 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eZl51-0003Dg-4P for pgsql-general@arkaria.postgresql.org; Thu, 11 Jan 2018 22:12:11 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1eZl50-0003DW-T4 for pgsql-general@lists.postgresql.org; Thu, 11 Jan 2018 22:12:10 +0000 Received: from out3-smtp.messagingengine.com ([66.111.4.27]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1eZl4x-0003xT-HZ for pgsql-general@postgresql.org; Thu, 11 Jan 2018 22:12:09 +0000 Received: from compute7.internal (compute7.nyi.internal [10.202.2.47]) by mailout.nyi.internal (Postfix) with ESMTP id AFE8920BB9; Thu, 11 Jan 2018 17:12:05 -0500 (EST) Received: from frontend1 ([10.202.2.160]) by compute7.internal (MEProxy); Thu, 11 Jan 2018 17:12:05 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-sender:x-me-sender:x-sasl-enc; s=fm1; bh=gzbKKz rcdHqn1MhrTzivFziGPxUftjeHeWKhAdzsa4s=; b=cHSLL1XtDtTvQfzf79DWAI SwU2nfwpYp9Zq1HvDOcGogFuFDNHRGhyXzEiqjvYdmg4DkC7aYu53ajdrCRKF++d GXrF2RHy0W6X2IvNLakdsKGSTAJFvvJ8KXhM3712Ba8AQQSHyFQ+HZwWRxlUlDxB 6ZWkEUWcWZq2zulR0zd3crZvY74aRn5vALeSGxLWuSN8YWUPpnxl20v9aPV4OABa 5nYo8oSQajTKAOr/n2q8J948DfB/DXTesne8nbdFPMFfupXtbsPmctY+guGYj+/H X/3eeaFNdD1C44wWRvN8x8uZZw8BVUE70VgGl9gSgnmpuLRi015w9jqCeYbf1x/w == X-ME-Sender: Received: from april.local (c-73-13-66-39.hsd1.pa.comcast.net [73.13.66.39]) by mail.messagingengine.com (Postfix) with ESMTPA id 731147E430; Thu, 11 Jan 2018 17:12:05 -0500 (EST) Subject: Re: characters converted to ??? in postgres To: armand pirvu , "pgsql-general@postgresql.org" References: <59E42D78-E9AA-404A-9836-9A474ACFDDE3@gmail.com> From: Peter Eisentraut Organization: 2ndQuadrant Message-ID: <49e0edb1-5de6-21b2-6ab4-5264aff6b661@2ndquadrant.com> Date: Thu, 11 Jan 2018 17:12:05 -0500 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.13; rv:52.0) Gecko/20100101 Thunderbird/52.5.2 MIME-Version: 1.0 In-Reply-To: <59E42D78-E9AA-404A-9836-9A474ACFDDE3@gmail.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 1/11/18 16:34, armand pirvu wrote: > On OS X: > - case 1 fails > testdb=# insert into jt1 values ('??') ; > ERROR: invalid byte sequence for encoding "UTF8": 0xe2 0xa4 0x27 > Note that at paste time ≤ changed in ?? This looks like something is wrong with your libedit library. Try running psql with the -n option. If that helps, then look into building psql with libreadline instead. Because libedit is terrible. > - case 2 is fine > - echo -n '≤' |hexdump -C > 00000000 e2 89 a4 |...| > 00000003 -- Peter Eisentraut http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services