firebird and unicode

F

flupke

Hi,

i'm developing an app that uses wxPython and Firebird via kinterbasdb on
Win XP SP2. On insert of a record i get this error:
(kinterbasdb.InterfaceError)
(0, "Type mismatch: Input parameter for field named [name n
ot known at this stage of query execution] must be a string, rather than
a <type 'unicode'>.")

Python, wxPython are all unicode enabled. The firebird database is
created with the UNICODE_FSS charset and opened as such in kinterbasdb's
connect function (charset=UNICODE). The GUI's charset is made with
wxGlade and there i specified UTF-8 for the encoding.

I'm out of ideas as to why i get this error message.

Any ideas?

Thanks
Benedict
 
F

flupke

flupke said:
Hi,

i'm developing an app that uses wxPython and Firebird via kinterbasdb on
Win XP SP2. On insert of a record i get this error:
(kinterbasdb.InterfaceError)
(0, "Type mismatch: Input parameter for field named [name n
ot known at this stage of query execution] must be a string, rather than
a <type 'unicode'>.")

Python, wxPython are all unicode enabled. The firebird database is
created with the UNICODE_FSS charset and opened as such in kinterbasdb's
connect function (charset=UNICODE). The GUI's charset is made with
wxGlade and there i specified UTF-8 for the encoding.

I'm out of ideas as to why i get this error message.

Any ideas?

Thanks
Benedict

If looked around a bit and it seems i have to do a
kinterbasdb.init(type_conv=100). But this gives another error:

File "C:\Python24\lib\site-packages\kinterbasdb\__init__.py", line 343,
in init
fakeFunc.func_code = realFunc.func_code
ValueError: Date() requires a code object with 0 free vars, not 1

I installd the mx Data time module and the fixedpoint module but that
doesn't help. I still get the same error.
Does anybody know what's wrong?

Thanks,
Benedict
 
F

flupke

flupke wrote:
<snip>

I solved it by getting the latest py files from CVS and overwriting the
existing ones. It gave an Attribute error but that was gone after
commenting this line:
#isc_info_isc_version = _k.isc_info_isc_version

I'm not sure if this is a safe way of working. It's like jumping over a
fence with barb wire. You know your balls might be in danger but
sometimes you got to take a risk :)

I hope i don't end up singing with a funny voice ;)

Thanks,
Benedict Verheyen
 
F

F. Petitjean

Le Mon, 23 May 2005 09:30:31 GMT, flupke a écrit :
It's like jumping over a fence with barb wire.
You know your balls might be in danger but
sometimes you got to take a risk :)
+1 QOTW
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top