We ar eunable to extract user by roles and groups. When checked with PTC, ptc said, there is no option available with PTC at the moment. This is very useful functionality.
I am also curious to know generate a report to find all the containers they are a member of and in what roles. Is there a way? But PTC say its not possible. Here is the case number CS22167
We have run into the same issue here, we had to report on who we have in a custom group driving enabling functionality. I had to go directly to WDS and copy the contents of the group out to a text field, but having the ability to export the table in the group like other tables would be great. Also with the upcoming 11.1 licensing group structure and needs to look into the groups there for licensing costs, this functionality would be heavily used.
To test this I wrote a Java script that will either:
1) List the Groups, Teams and Roles a specified user is in
or
2) Remove the specified user from the Groups, Teams and Roles.
I didn't get fancy so right now the script is run from a Windchill shell and results are displayed in the shell. Could certainly write results to a file too.
For example, java ext.util.ReportUserUsage joe.smith -remove
The -remove argument would trigger the script to remove the user. If -remove is not entered the user's usage is simply reported.
This could also be setup to be run from the Windchill GUI rather than a Windchill shell.
Windchill shell output looks like this:
C:\ptc\Windchill_11.2\Windchill>java ext.tools.ReportUserUsage Administrator *** 13 groups found that Administrator is in.
@d_graham - We can have our developers do something like this, no problem, but the situation is that almost all tables in WC you can export the contents.. The one used for administrators that would may need to report on said groups, would have to develop a tool to do it. The code and the actions are there, just not setup for that table.
If you want to view the Groups, Roles, Teams and the associated username this can be done using QueryBuilder which includes the ability to export list to file.
If information you want is users-group relations at Organisation/Site level then you really can't get it from QueryBuilder because it stored in WindchillDS and not in DB.
@d_graham - it's sad bud QueryBuilder can't list groups/users relations created at Org/Site level.
As I wrote several times in the community, at the moment the only way to have the correspondence between users and groups to which they belong is to use Java methods.
The mode is explained in one of the various links in this document
I have used it for several years and it works very well, just organize the correct membership of users to the various groups, which in turn are included in the roles to regulate access.
When a new user arrives in the company, I ask from which user the ACLs must be copied then, through a report built using the Java method, I check in which groups the user is present as a reference for the new one, which I insert in the same groups.
However, I seem to have read that, from version 12, Windchill DS will be abandoned and all its data will be inserted in the Windchill DB, so the problems should finally be solved.
@oulyanin you are correct re: the OOTB tables and columns, however, it is possible to do it using "Java method" option in QueryBuilder.
I wrote a method that simple gets all groups and then loops through to see if the user in question is a member. If yes, than add the group's name to a String and return the String.
If you are looking for exporting Group Membership Hierarchy, then starting Windchill 11.1 M020
TheExport List to CSV action has been added to the Members table on group information page using which you can export group members table to CSV file with membership hierarchy.