on 12-14-2018 2:24 PM
I need help; or, I need help finding help... I want to query my PD Repository database to answer questions about the "health" of our models. I have explored the Repository Data Model, but am struggling still. I want to answer questions like: Within a certain Repository folder, including sub-folders, within all current-version physical data models, how many tables have non-empty comments? (And, similarly, for columns.)
I've figured out bits and pieces - but only at the highest level, for example:
select count(*) from PMOBJT where CLSS=272 and cmmt<>0 and lvrs=1; -- number of latest version tables with a comment
What I have not figured out is how to determine how objects are related to each other - folders within folders, PDM's within folders, tables with PDMs, columns within PDMS.You might have seen this already, but there is a published metamodel that explains all of the relationships between the tables. I found this one:
Look at the "MetaModel.oom" file. It should give you more help also.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I missed a reference. The actual Repository PDM file:
C:\Program Files\SAP\PowerDesigner 16\Examples\Repository Metamodel.pdm
To follow up... The key was in knowing how to write hierarchical queries. I still don't know how, really, but a teammate does, and helped me out.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
In the script you could check out the model in memory then navigate it in the usual way
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
98 | |
11 | |
11 | |
10 | |
10 | |
8 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.