Sorry for the somewhat duplicate post, now with better subject header.
This has me totally stalled. Trying to insert a record into the db with
an enum column gets this error message.
code:
s = Sale( type="web", total=5.00, purchaser=1, status="pending",
sale_key="1234567" )
table:
class Sale(SQLObject):
# an enum of web sale, store purchase, or promo
type = EnumCol( enumValues=('web','store','promo'), notNone=True,
default='web' )
etc
error:
"/usr/local/lib/python2.4/site-packages/SQLObject-0.7.2b1-py2.4.egg/sqlobject/col.py",
line 921, in to_python
(self.enumValues, self.name, value), value, state)
Invalid: expected a member of ('web', 'store', 'promo') in the EnumCol
'type', got Set(['web']) instead
Can anyone shed some light on what is going on here? I am using mysql as
the backend. I can't for the life of me figure out what is going on
because the data *does* go into the table. But my controller crashes.
The same thing happens using the shell, I get an error message with a
traceback and then the data is in the table.
Mysql version: 4.1.20-1.RHEL4.1
MySQL-python version: MySQL-python-1.2.0-1.src.rpm
Thanks
Iain
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"TurboGears" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/turbogears?hl=en
-~----------~----~----~----~------~----~------~--~---