Creating new table with same structure as existing one
Posted in 2003
I need to create "archive" table that will have the same structure as
"production" one.
When I run my program it have to create table named "pronop_yyyymm" ( yyyymm is
argument to my program representing date in format year(4)month(2)) if it
doesn't exist. I will write rows from table "pronop" that are in given
month/year to "pronop_yyyymm" and delete them from "pronop" (I know that DELETE
is very slow but I don't have alternative).
What I want is not to change program (or part of program where I create
"pronop_yyyymm") when structure of table "pronop" is changed.
I am using I4GL. I have an idea to do it with "dbschema" and some scripting.
Is there any other way?
nebojsa
------------------------------------
Remove spam block (DELETE_) to reply