create table as select ...
Posted in 2000
Topics: General Discussion
Hi, Can one do a create table ... as select ... from ... where ...? Or if there an equivalent? Basically, I am looking to copy a table from one schema to another. Thanks. Sent via Deja.com http://www.deja.com/ Before you buy.
Informix doesn't support 'create ... as select ... where ... '. <schan4me@yahoo.com> ''''' ' ''''''''':8tpr4t$e1r$1@nnrp1.deja.com... > Hi, > > Can one do a create table ... as select ... from ... where ...? > Or if there an equivalent? > > Basically, I am looking to copy a table from one schema to > another. > > Thanks. > > > Sent via Deja.com http://www.deja.com/ > Before you buy.
"Sergey E. Volkov" wrote:
> Informix doesn't support 'create ... as select ... where ... '.
unless of course you only want your copy as a temp table i.e. :-
select ...
from ...
into temp blah with no log
select *
from blah
Temp table is of course only persistent for the current session.
-----
Brett
(dbschema -d mydbs -t oldtabl |sed -e 's/oldtabl/newtabl/'; echo 'insert into
newtabl select * from oldtabl;') | dbaccess mydbs
Art S. Kagel
schan4me@yahoo.com wrote:
>
> Hi,
>
> Can one do a create table ... as select ... from ... where ...?
> Or if there an equivalent?
>
> Basically, I am looking to copy a table from one schema to
> another.
>
> Thanks.
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.