On 2 Sep 2009, at 8:27pm, P Kishor wrote:

> Simon
> Slavin<slav...@hearsay.demon.co.uk> wrote:
>>
>> On 2 Sep 2009, at 2:39pm, Alberto Simões wrote:
>>
>>> Can you please send me your env?
>>
>> It works fine for me on Leopard, and I have done no special
>> environment setting at all: I use the default Unix settings and the
>> default SQLite settings for 10.5.
>>
>> You might want to check which shell you're using (csh ?  bash ?) to
>> see if the shell is filtering out your funny characters for you.
>
> actually, does not work for me.

I apologise.  You're quite right: you can't type non-ASCII characters  
into the sqlite3 command-line tool.  What I'd done when I was testing  
was to put commands into a text file and use the '.read' command.  I  
just tested this: make a text file with the following in:

CREATE TABLE myTab (myCol TEXT);
INSERT INTO myTab (myCol) VALUES ('pub');
INSERT INTO myTab (myCol) VALUES ('café');

Then I did this:

SimonsMBP2009:Desktop simon$ sqlite3 testchars.sql
SQLite version 3.4.0
Enter ".help" for instructions
sqlite> .read commands.txt
sqlite> SELECT * FROM myTab;
pub
café
sqlite> .dump
BEGIN TRANSACTION;
CREATE TABLE myTab (myCol TEXT);
INSERT INTO "myTab" VALUES('pub');
INSERT INTO "myTab" VALUES('café');
COMMIT;
sqlite>

As you can see, the accented character went in fine, and sqlite  
retained and displays it fine.  The problem is you just can't type  
such a character, or you can't using an unchanged bash shell.  The  
setting for the bash command-line would be

set input-meta on

This allows bash to handle the accented e correctly.  But it's not  
passed into the command-line tool that comes with OS X 10.5.  I'll be  
able to test this with the version of sqlite3 that comes with 10.6 soon.

Simon.
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to