Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1T1o5w-0001A3-JW for pgsql-bugs@postgresql.org; Thu, 16 Aug 2012 00:37:52 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1T1o5s-0005Du-Kk for pgsql-bugs@postgresql.org; Thu, 16 Aug 2012 00:37:52 +0000 Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.5/8.14.5) with ESMTP id q7G0bltY026576; Wed, 15 Aug 2012 20:37:47 -0400 (EDT) From: Tom Lane To: =?ISO-8859-1?B?QW5nZWwgWvrxaWdh?= cc: pgsql-bugs@postgresql.org Subject: Re: ProblemWithCharsOSX In-reply-to: References: Comments: In-reply-to =?ISO-8859-1?B?QW5nZWwgWvrxaWdh?= message dated "Wed, 15 Aug 2012 10:19:14 -0500" Date: Wed, 15 Aug 2012 20:37:47 -0400 Message-ID: <26575.1345077467@sss.pgh.pa.us> X-Pg-Spam-Score: -1.9 (-) X-Archive-Number: 201208/117 X-Sequence-Number: 33841 =?ISO-8859-1?B?QW5nZWwgWvrxaWdh?= writes: > I'm a PostgreSQL user in the linux world but at the office there is a Mac > computer and I have a problem with postgres in it. > The problem is when I use characters with tildes in spanish like in the > follow word "países". > The next is ilustrates my problem: > test=# SHOW SERVER_ENCODING; > server_encoding > ----------------- > UTF8 > (1 row) > test=# SELECT pg_client_encoding(); > pg_client_encoding > -------------------- > UTF8 > (1 row) > test=# CREATE TABLE países (nombre VARCHAR(10)); > CREATE TABLE > test=# \d > List of relations > Schema | Name | Type | Owner > --------+-------+-------+-------- > public | pases | table | dragon > (1 row) FWIW, I cannot reproduce that as stated on my own Mac. I suspect though that the problem is not with Postgres per se but with your terminal window. If you're using Terminal, check the encoding setting in Preferences ... Settings, and also look at Preferences ... Encodings. You'll probably have trouble unless Terminal is using the same encoding that psql thinks the client_encoding is. regards, tom lane