Table Definition Repository

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

Post Reply
denzilsyb
Participant
Posts: 186
Joined: Mon Sep 22, 2003 7:38 am
Location: South Africa
Contact:

Table Definition Repository

Post by denzilsyb »

Hallo all

This is more out of interest that I am asking.

Is it only me, or is managing table definitions within DS a nightmare? I have developers creating table defs left right and centre (including me), and, even though we have predefined categories, we still have the odd definition being created in a random place within the repository. My point is that its just too easy to create definitions anywhere.

How have you guys prevented this issue?
dnzl
"what the thinker thinks, the prover proves" - Robert Anton Wilson
kcbland
Participant
Posts: 5208
Joined: Wed Jan 15, 2003 8:56 am
Location: Lutz, FL
Contact:

Post by kcbland »

Appoint a metadata steward. I've found that someone has to be in charge of keeping the repository clean, enforcing standards, etc. Your issue with table definitions is true also for functions, jobs, etc. A rigorously enforced standard that is periodically reviewed and refined is the best approach, in my opinion.
Kenneth Bland

Rank: Sempai
Belt: First degree black
Fight name: Captain Hook
Signature knockout: right upper cut followed by left hook
Signature submission: Crucifix combined with leg triangle
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Exactly. That and a big stick. Helps with the 'enforced' part. :wink:
-craig

"You can never have too many knives" -- Logan Nine Fingers
denzilsyb
Participant
Posts: 186
Joined: Mon Sep 22, 2003 7:38 am
Location: South Africa
Contact:

Post by denzilsyb »

I was afraid this was the case. Perhaps a good spanking is in order :D

I think we'll keep to the standards we have and accept that using the repository is a learning process for the developers.
yes... the table definition IM_SAVING_THIS_AGAIN_ZZZZ is stored somewhere and doesnt mean anything to anyone else. look at the standards!
the joys of documentation
dnzl
"what the thinker thinks, the prover proves" - Robert Anton Wilson
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

I recently completed a "best practices audit" for a client. One of the not-so-best practices I uncovered was use of the Saved category of Table Definitions. Developers (properly) use this as temporary storage for example to migrate column definitions from the input side of an Aggregator stage to the output side, but never clean up. I found seven saved versions of the same table definition in seven different Saved sub-categories. This is also something for your metadata steward to manage. Perhaps a rule like automatic deletion from Saved after seven days? There's nothing to prevent a Save to a "proper" category, if that's the intent.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Tania
Participant
Posts: 22
Joined: Tue Jul 13, 2004 7:54 am
Location: Johannesburg

Post by Tania »

:idea: Maybe you could introduce a fine(monetary of course) for developers found saving definitions outside the standard repositories and those not fined can go for a drink on Friday with the fine money. :D

Best luck anyway.
ogmios
Participant
Posts: 659
Joined: Tue Mar 11, 2003 3:40 pm

Post by ogmios »

I'm more for the stick approach.

Ogmios
Stef
Participant
Posts: 24
Joined: Wed May 21, 2003 12:37 pm
Location: Montreal, Canada

Post by Stef »

Well, then... use the stick then take the money :twisted:
denzilsyb
Participant
Posts: 186
Joined: Mon Sep 22, 2003 7:38 am
Location: South Africa
Contact:

Post by denzilsyb »

ray.wurlod wrote:Perhaps a rule like automatic deletion from Saved after seven days? There's nothing to prevent a Save to a "proper" category, if that's the intent.
This is/was the intent, but Im interested as to how we are going to auto delete after 7 days? Are we talking a bit of BASIC code that goes into the repository and does the cleanup. Is there a topic that has covered this before so I can go do some reading..
dnzl
"what the thinker thinks, the prover proves" - Robert Anton Wilson
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

There's nothing out there, but it wouldn't be too difficult. Date/time modified is in DS_AUDIT.

Code: Select all

SELECT INSTANCE, DTM FROM DS_AUDIT WHERE CLASS = '4';
will get you started

Code: Select all

SELECT INSTANCE, DTM FROM DS_AUDIT WHERE EVERY DTM < '2004-08-14';
will get you even closer. You will need also to look at DTC for any that have not been modified. You may also need to join to DS_METADATA (WHERE DS_AUDIT.INSTANCE = DS_METADATA.DSRID) to get the CATEGORY.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Post Reply