On Dec 7, 11:18 am, "Michael Bayer" <[email protected]> wrote:
> it seems like you basically want access to the dictionary of type->class. > You can get this off the base mapper (i.e. class_mapper(BaseClass) ) in a > dictionary called "polymorphic_map". Ah, thank you - exactly what I needed. It took me a moment to figure out how to get the actual class out of the mapper, but I found class_ and all is well. So now I have something like this: new_node = class_mapper(Node).polymorphic_map[node_type].class_() and it all happens in one line. Look reasonable? Thanks again! -- You received this message because you are subscribed to the Google Groups "sqlalchemy" 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/sqlalchemy?hl=en.
