On Wed, Sep 2, 2009 at 6:14 PM, Simon Slavin<slav...@hearsay.demon.co.uk> wrote:
>
> 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.
>

well, I think the problem is with the sqlite3 command line tool. I can
type accented characters in the Terminal.app using bash and no fancy
setting just fine. See below

punk...@lucknow ~$I ate at el niño café çirca 1984 with ümlaut and hei∫e in øslo
-bash: I: command not found
punk...@lucknow ~$sqlite3
SQLite version 3.6.11
Enter ".help" for instructions
Enter SQL statements terminated with a ";"
sqlite> create table t1(x);
sqlite> insert into t1 values ('I ate at el nio caf irca 1984 with
mlaut e in Heislo');
sqlite> select * from t1;
I ate at el nio caf irca 1984 with mlaut e in Heislo
sqlite>


setting input-meta on doesn't change the above behavior at all.


> Simon.



-- 
Puneet Kishor http://www.punkish.org
Carbon Model http://carbonmodel.org
Charter Member, Open Source Geospatial Foundation http://www.osgeo.org
Science Commons Fellow, http://sciencecommons.org/about/whoweare/kishor
Nelson Institute, UW-Madison http://www.nelson.wisc.edu
-----------------------------------------------------------------------
Assertions are politics; backing up assertions with evidence is science
=======================================================================
Sent from Madison, WI, United States
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to