On Jul 1, 2008, at 12:59 PM, jerryji wrote:

>
> Hi,
>
> Is there a way in SA to create an inheriting table without needing to
> specify all its parent's columns (hence _not at the ORM level_ , am I
> not right?) at the table level, like what the "CREATE TABLE capitals"
> does below --
>
> """
> CREATE TABLE cities (
>    name            text,
>    population    float,
>    altitude         int
> );
>
> CREATE TABLE capitals (
>    state           char(2)
> ) INHERITS (cities);
> """
>

thats a postgres-specific feature which SA has no direct support for.   
SQLA supports a backend-agnostic pattern called "joined table  
inheritance" which is largely the same thing implemented at the  
application level, whereby both parent and child table are queried  
explicitly.



--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to