Hi, trying to connect to the existing Firebird database from the Windows XP machine, I am getting following strange Error:

import *
from sqlobject.sqlbuilder import *

db_filename = 'd|/sgdata/test/sysdat01.gdb'
connection_string = 'firebird://172.18.0.10:3050/' + db_filename
connection = connectionForURI(connection_string)

class Cenktgm01(SQLObject):
   _connection = connection   
   class sqlmeta:       
       fromDatabase = True

Cenktgm01._connection.debug = True
myTry = Cenktgm01()



Microsoft Windows XP [Verze 5.1.2600]
C:\automat>python pokusy.py
Traceback (most recent call last):
  File "pokusy.py", line 54, in <module>
    class Cenktgm01(SQLObject):
  File "C:\Python25\lib\site-packages\sqlobject-0.10dev_r3187-py2.5.egg\sqlobject\declarative.py", line 112, in __new__
    cls.__classinit__(cls, new_attrs)
  File "C:\Python25\lib\site-packages\sqlobject-0.10dev_r3187-py2.5.egg\sqlobject\main.py", line 781, in __classinit__
    cls.sqlmeta.addColumnsFromDatabase()
  File "C:\Python25\lib\site-packages\sqlobject-0.10dev_r3187-py2.5.egg\sqlobject\main.py", line 443, in addColumnsFromDatabase
    sqlmeta.addColumn(columnDef)
  File "C:\Python25\lib\site-packages\sqlobject-0.10dev_r3187-py2.5.egg\sqlobject\main.py", line 369, in addColumn
    setter = eval('lambda self, val: self._SO_setValue(%s, val, self.%s, self.%s)' % (repr(name), '_SO_from_python_%s' % name, '_SO_to_python_%s'
% name))
  File "<string>", line 1
    lambda self, val: self._SO_setValue('p$defkod', val, self._SO_from_python_p$defkod, self._SO_to_python_p$defkod)
                                                                               ^
SyntaxError: invalid syntax


Thanks for your comments

Petr