|
From: Oleg B. <ph...@ph...> - 2011-06-13 17:55:09
|
On Mon, Jun 13, 2011 at 01:48:08PM -0400, Peter Douma wrote:
> I just started using SQLObject
Welcome!
> When I get to this model
>
> class Event(SQLObject):
> event_id = IntCol( unique = True )
> describ = StringCol()
> date = DateTimeCol(default = DateTimeCol.now)
> organizer = ForeignKey("Organizer", default=None)
> sponsers = MultipleJoin("Sponser")
> attendees = RelatedJoin("Attendee")
>
> I get the following error:
> conxt.#sql-d58_2b' (errno: 150)
The error doesn't look like it it's from SQLObject. Can you provide
more details? Database? driver? full traceback?
> If I run it again, everything works fine. The first time through the table is created, but not the the related tables.
Could it be a problem with ForeignKey pointed to a table
('organizer') that hasn't been created yet?
Oleg.
--
Oleg Broytman http://phdru.name/ ph...@ph...
Programmers don't die, they just GOSUB without RETURN.
|