on 08-15-2006 8:59 AM
Hi Everybody,
It is possible to create reports about the repository, for example I use a field in different tables and want to list it?
or I want a list of all able CHAR fields that I have in my repository?
It is possible to group Tables or fields to logical units... I mean I use a table (<b>T1</b>) in two different applications <b>A1</b> and <b>A2</b> and I want to document this situation on MSD..... later I would like to create a report that tells me which table ( or fields) has <b>A1</b>..... or maybe other report that tells me in which Applications is table <b>T1</b> used...
Thanks again for your kind support and orientation
Best Regards
FedeX
I'm sorry but I think that functionality is not there. You can, however, use Java API to create your reports. When doing that, besides retrieving your MDM data, you can also retrieve the repository structure, tables and fields, as well as which type of fields they are.
For instance, to retrieve the tables on a MDM Rep:
// Assume an initialized CatalogData mdmConnector;
public String[] getTablesCodes()
{
CMTableInfo table = new CMTableInfo();
CMTableInfoArray tablesArray = new CMTableInfoArray();
String result[] = null;
try
{
tablesArray = mdmConnector.GetTables();
result = new String[tablesArray.GetCount()];
for(int i = 0; i < result.length; i++)
{
table = tablesArray.GetCMTableInfoAt(i);
result<i> = table.GetCode(); // this is to get the correct language
}// Get the tables names
}//try
catch(Exception e)
{
System.out.println("An error occurred on MDMBridge getTables()");
e.printStackTrace();
}// Catch
return result;
}// Get Tables Codes
And to get the fields of each table:
public String[] getFieldsCodes(String table)
{
String[] result = null;
try
{
CMFieldInfoArray fields = mdmConnector.GetFields(table);
CMFieldInfo field = new CMFieldInfo();
result = new String[fields.GetCount()];
for(int i = 0; i < result.length; i++)
{
field = fields.GetCMFieldInfoAt(i);
result<i> = field.GetCode();
}// for
}//try
catch(Exception e)
{
System.out.println("An Error has ocurred on MDMBridge at getFields(String table)");
e.printStackTrace();
}//catch
return result;
}// get Fields from a table
You could add code in order to get, besides the name of the table/fields, the correspondant data type
I hope that helps
Alejandro
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi FedeX,
This functionality is not available in MDM clients.However the Java API's could be used to get the functionality required.
Here, you using the API you can access properties of the tables in repository as well as the fields in the respective tables.
The code posted above by the fellow SDN should be a good starting point.
Hope that helps.
Regards,
Tanveer.
<b>Please mark helpful answers</b>
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
78 | |
10 | |
9 | |
7 | |
6 | |
6 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.