I need to change several tables in schema, for example: prefixed with some for all the tables, for example For:
Optional table "SCHEMA". Add "Tab 1" ("COLUMN1" character (4) No '' data '', '' COLUMN2 '' VARCHAR (16) tap default 'MORE_DATA',); I need it to iterate over several tables, such as SCHEMA.table1, SCHEMA.table2 ... and so on. There are about 800 tables in the Schema.
I was wondering if there is any kind of wildcard that I can use? I was looking for a cursor from the system tables, but to make sure there should be some easy way.
What do I have to do in those cases, if DBMS does not provide an easy way, then just Writing a script that will do this for me. Something like this: Choose tbname from
db2 "sysibm.systables where to delete schema = 'SCHEMA' gtk tblist # header here and edit $ tblist for t (tblist) ; It is necessary to optimize for the scripting tool ... " This is the bash type format, you use.
Comments
Post a Comment