Hi, I am not a professional coder; hobby-like thing. I would like to encapsulate my table definitions in a new class:
class MyTable( Table): def __init__( self, metadata): Table.__init__( self, my_table_name, metadata, col1, col2...) metadata = MetaData() table = MyTable( metadata) Traceback (most recent call last): File "create_tables.py", line 11, in <module> table = MyTable( metadata) TypeError: __call__() takes at least 3 arguments (2 given) ******* I tested different things and I have the feeling that it is not possible to subclass the Table class. Is this true? If no: what is the mistake I make? If yes: why? does Table class have some special decoration or something like that? How do you avoid to define your table in every script you write to use that table with its corresponding class? Thanks for your help, tamas --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "sqlalchemy" group. To post to this group, send email to sqlalchemy@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sqlalchemy?hl=en -~----------~----~----~----~------~----~------~--~---