Subject | Re: Copy paste tables |
---|---|
Author | throwmail2000 |
Post date | 2004-03-07T10:33:14Z |
--- In firebird-support@yahoogroups.com, "Alan McDonald" <alan@m...>
wrote:
If Firebird could create and associate Domain's based on source table
in 'insert into mytable2 select * from mytable1' that would be
very convenient especially for people migrating from other databases
or people who are creating large number of tables.
Maybe this is a wishlist candidate.
wrote:
> > What's the easy way to copy table(without data)?edit the
> >
> > I tried 'insert into mytable2 select * from mytable1 where 1=0;
> >
> > This did created mytable2 table, but it didn't copied the damin names
> > and instead put the firebird native data type as field types.
> > I ran the above query in IBExpert.
> >
> > Also when I looked into DDL there were no Trigger or generator
> > for mytable2, mytable1 has one trigger and 1 generator.
> >
> > Thanks
> >
>
> just extract the metadata for the table (easy in IBExpert), then
> script to change the name of the table and run it using the currentThanks, that worked perfectly.
> connection - you get all metadata the same
> Alan
If Firebird could create and associate Domain's based on source table
in 'insert into mytable2 select * from mytable1' that would be
very convenient especially for people migrating from other databases
or people who are creating large number of tables.
Maybe this is a wishlist candidate.