Login | Register
My pages Projects Community openCollabNet

Discussions > users > Re: [maxq-users] DBUtil

maxq
Discussion topic

Back to topic list

Re: [maxq-users] DBUtil

Author saperski
Full name Marcin Cieslak
Date 2005-05-23 14:06:30 PDT
Message On 5/23/05, christophe blin <cblin at tennaxia dot com> wrote:
> Can you give more precisions please. I am not very familiar with Python
> (this is my first project with this language) so I do not understand what
> you mean by \u notation.

The problem you have is not specific to Python - you try to encode
unicode string in the
source file without givin its encoding (I guess in your case it's UTF-8).

Can you try putting the following in your code:

querystring = u"select id from project where name='T2 :
Conformit\u00E9: plan fonctionnel'"


projid = db.loadVal(querystri​ng.encode("iso-8859-​15"))
if projid == None:
   print "projid1:None"
else:
   print "projid1:"+projid

projid = db.loadVal(querystri​ng.encode("utf-8"))
....

See also description of Python unicode implementation

http://www.python.or​g/peps/pep-0100.html​

taking into account jython differences

http://www.jython.or​g/docs/differences.h​tml

Hope this helps,

--marcin

« Previous message in topic | 10 of 11 | Next message in topic »

Messages

Show all messages in topic

RE: [maxq-users] problem building, can't find javac James Richards <James dot Richards at demandtec dot com> James Richards <James dot Richards at demandtec dot com> 2005-04-22 10:42:11 PDT
     Documentation: command line arguments christophe blin <cblin at tennaxia dot com> christophe blin <cblin at tennaxia dot com> 2005-05-18 08:31:03 PDT
         Re: [maxq-users] Documentation: command line arguments christophe blin <cblin at tennaxia dot com> christophe blin <cblin at tennaxia dot com> 2005-05-20 02:32:20 PDT
             Re: [maxq-users] Documentation: command line arguments oliverbock Oliver Bock 2005-05-24 00:41:16 PDT
         DBUtil christophe blin <cblin at tennaxia dot com> christophe blin <cblin at tennaxia dot com> 2005-05-20 02:44:17 PDT
             Re: [maxq-users] DBUtil christophe blin <cblin at tennaxia dot com> christophe blin <cblin at tennaxia dot com> 2005-05-20 04:33:02 PDT
                 Re: [maxq-users] DBUtil christophe blin <cblin at tennaxia dot com> christophe blin <cblin at tennaxia dot com> 2005-05-20 08:44:02 PDT
                     Re: [maxq-users] DBUtil saperski Marcin Cieslak 2005-05-20 10:07:09 PDT
                         Re: [maxq-users] DBUtil christophe blin <cblin at tennaxia dot com> christophe blin <cblin at tennaxia dot com> 2005-05-23 02:37:37 PDT
                             Re: [maxq-users] DBUtil saperski Marcin Cieslak 2005-05-23 14:06:30 PDT
                                 Re: [maxq-users] DBUtil christophe blin <cblin at tennaxia dot com> christophe blin <cblin at tennaxia dot com> 2005-05-24 02:14:30 PDT
Messages per page: