Community Tip - Learn all about PTC Community Badges. Engage with PTC and see how many you can earn! X
Version: Windchill 12.1
Use Case: Good day. I am new to Windchill. Can Someone help me to setup a report to collect the Maturity History of all documents / parts in a report? I need to generate a report that calculates the time difference between the "In Work" date and the "Released" date of an object. in other words a report on all the items lifecycle states from in work to released.
Description:
I have tried with Query builder and I just get errors.
Perhaps if someone has a qml example that I can upload and tweak.
For those reading, this discussion grew out of what was written here.
https://community.ptc.com/t5/Windchill/Query-Builder-Lifecycle-History-Example/m-p/444736
Here's some tips to help you get started.
First, it's pretty difficult to report 2 different types of things in one report. I'd recommend one report dedicated to parts, and a separate report for documents. Both reports would work similarly.
I'd start with something like this:
Start with the Part Master. This ensures we're looking at a single Part. (For Documents, you'd use the Document Master here). From there, link to 2 different Part objects. These are different iterations. Most likely the first iteration to be "In Work" is a different iteration than the one that was "Released".
Each Part is linked to a Life Cycle History. That gives us all state changes for that iteration.
The Criteria shown lets you compare when the first part iteration got to In Work against when another part iteration of the same revision got to Released.
From there, you just need to use the Date Difference database function to get the duration between the 2 states:
One caveat to look out for... this doesn't take into account if a part enters one of the states more than once in a single Revision. If you have that scenario, you'll need to add additional subselects to limit the Life Cycle History's considered. That gets more complicated, so hopefully you don't have that scenario.
Thank you so much for your help on this one.
For now I only need it for documents. I will look at the parts report later in the year or next year.
I just have a question or 2 about what you have shown me.
When I add the Date Difference as you have shown, i get the following error. See below.
Also, what arguments should I have in my "Select or Constrain" tab.
I have the following, see below.
My Criteria Table looks like this below.
Datediff database function only works on SQL server not Oracle.
How to use date difference database function in QML in Windchill PDMLink
These are the three requested parameters
Oops.. I wasn't using Datediff correctly. Here's the support page with all the Database functions: https://support.ptc.com/help/wnc/r12.1.1.0/en/index.html#page/Windchill_Help_Center/querybuilder/QBSelectOrConstrainDatabaseFunction.html#