I would like create table as select statement

http://www.postgresql.org/docs/8.1/static/sql-createtableas.html

On 1 June 2015 at 20:48, Mike Bayer <mike...@zzzcomputing.com> wrote:

>
>
> On 6/1/15 9:39 AM, Ranjith Ramachandra wrote:
>
>  I am using sqlalchemy's core features do write some abstraction layer.
> The layer itself needs to be able to create tables from select statements.
>
>  Sample code:
>
>      metadata = MetaData(bind=engine)
>     table = Table(table_name, metadata, autoload=True,
> autoload_with=engine)
>     s = select(table).where(table.c.column_1 > 10)
>
>  Now what I want to be able to is create a new table from the select
> statement above. How can I do it?
>
> can you be more specific?  What DDL would you like to emit ?
>
>
>
>
>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "sqlalchemy" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to sqlalchemy+unsubscr...@googlegroups.com.
> To post to this group, send email to sqlalchemy@googlegroups.com.
> Visit this group at http://groups.google.com/group/sqlalchemy.
> For more options, visit https://groups.google.com/d/optout.
>
>
>  --
> You received this message because you are subscribed to a topic in the
> Google Groups "sqlalchemy" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/sqlalchemy/lKDkX68fOqI/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> sqlalchemy+unsubscr...@googlegroups.com.
> To post to this group, send email to sqlalchemy@googlegroups.com.
> Visit this group at http://groups.google.com/group/sqlalchemy.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"sqlalchemy" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sqlalchemy+unsubscr...@googlegroups.com.
To post to this group, send email to sqlalchemy@googlegroups.com.
Visit this group at http://groups.google.com/group/sqlalchemy.
For more options, visit https://groups.google.com/d/optout.

Reply via email to