Hello
Just wondering why it doesn't works...
I have 3 tables in DB:
Material - contains some text, audio or video
User - info about all registered users
VotedUser - here stored all user that voted for some material
So I created model class as follows:
class VotedUser(SQLObject):
"""
Rating model class
"""
ip = UnicodeCol(length = 15)
material = ForeignKey('Material', notNull=True, cascade=None)
user = ForeignKey('User', notNull=True, cascade=None)
vote_date = DateTimeCol(default = DateTimeCol.now)
rating = FloatCol()
When I run the site I'v got table creation error from MySQL.
I guess that it's because two foreign keys are IDs with auto increment
flag.
Am I right and if not how can I avoid that?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"pylons-discuss" 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/pylons-discuss?hl=en
-~----------~----~----~----~------~----~------~--~---