cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Visit the PTCooler (the community lounge) to get to know your fellow community members and check out some of Dale's Friday Humor posts! X

how to fetch cad structure with Each component listed once with a consolidated total quantity

AP_10343008
15-Moonstone

how to fetch cad structure with Each component listed once with a consolidated total quantity

In getStructure API,  Number of cad doc occurrences repeated because of quantity of the component in the document structure. how to fetch cad structure with Each component is only listed once with a consolidated total quantity ?

ACCEPTED SOLUTION

Accepted Solutions

@AP_10343008 

I don’t think there is an alternative.

The sum is not stored in the dB. It has to be calculated.

 

Ever notice how when opening the structure tab for EPMDocs or WTParts you might see a message stating it’s working. That’s because Windchill has to calculate the structure.

You need to not only calculate the structure but you need to sum quantity EVERYWHERE the components is used in the structure.


Others can weigh in on this but I don’t see another way to get the info you’re looking for.

 

 

View solution in original post

9 REPLIES 9

I wrote a utility to do what you’re inquiring about.

The only way I found to do it was to write my own code that sums the quantity for each occurrence (recursively) in the assembly.

 

That will definitely work.

AP_10343008
15-Moonstone
(To:d_graham)

Yeah but it takes 5 mins to check quantity of 70k documents. I need an alternative instead of calculating quantity recursively.

@AP_10343008 

I don’t think there is an alternative.

The sum is not stored in the dB. It has to be calculated.

 

Ever notice how when opening the structure tab for EPMDocs or WTParts you might see a message stating it’s working. That’s because Windchill has to calculate the structure.

You need to not only calculate the structure but you need to sum quantity EVERYWHERE the components is used in the structure.


Others can weigh in on this but I don’t see another way to get the info you’re looking for.

 

 

HelesicPetr
22-Sapphire I
(To:d_graham)

Hi @d_graham and @AP_10343008 

I can confirm that I've never found any function that work enough fast for huge assemblies.

Always you need to go throw the BOM recursively and count the component count.. 

 

PetrH

Yep.

And even if there were a “function” the info still is not stored in the dB so it still needs to be calculated.

 

It just the way Windchill is. 🤷‍♂️😂

AP_10343008
15-Moonstone
(To:d_graham)

Thanks for the confirmation

AP_10343008
15-Moonstone
(To:d_graham)

As mentioned in this document thingworx navigate 9.4, can we expect consolidated quantity from next version of navigate or next version of windchill ?

 

AP_10343008_0-1689846607014.png

 

 

Hi @AP_10343008 

 

If PTC writes "in the future" be sure it takes several years 😄

 

nice example is filename length in Creo :D. 

 

PetrH

Okay Thanks

 

Announcements

Top Tags