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

Community Tip - New to the community? Learn how to post a question and get help from PTC and industry experts! X

Setting Date Effectivity on bulk data is consuming lot of time

ptc-4228636
1-Newbie

Setting Date Effectivity on bulk data is consuming lot of time

Currently working on a data-migration project where Legacy ERP data needs to be loaded as WTPart.

Created WTParts and the Structures using data dump.

Now trying to set Date Effectivity on the loaded parts with respect to the Parent Parts.

Have developed an utility with the help of PTC case CS59121 to load Data effectivity on bulk data.

sample code :

----------------------------------------------------------------------------------------------------

EffManagedVersion[] effVers = new EffManagedVersion[1];

effVers[0] =wtpartLatest;

EffGroup effGroup;

String dateStartString = startDate;

Date datestart = sdf.parse(dateStartString);

Locale locale = new Locale("en-US");

startDate = WTStandardDateFormat.format(datestart,WTStandardDateFormat.WF_STANDARD_DATE_ONLY_FORMAT, locale,TimeZone.getTimeZone("GMT"));

effGroup = new EffGroup(null,wt.effectivity.WTDatedEffectivity.class,(startDate+"-").trim());

effGroup.setEffTypeModifier(EffTypeModifier.EXACT);

effGroup.setEffContext(wtpartParentmaster);

//EffGroupAssistant.appendEffGroups(effVers ,new EffGroup[]{effGroup});

EffGroupAssistant.appendEffGroupsQuietly(effVers ,new EffGroup[]{effGroup});

PersistenceHelper.manager.refresh(wtpartLatest);

----------------------------------------------------------------------------------------------------

While loading the Effectivity came to see that some WTParts are being used as BOM Components under n number of BOM Assemblies(WTParts).

It almost took 1 hour to update 170 objects.

Now it is consuming lot of time. Please help me in this regard.

Thanks,

Niranjan

2 REPLIES 2

Hi Niranjan,

We are also migrating the data from ERP system to Windchill PDM Link 10.1.

Can you help me in the effectivity configuration in Windchill, Is it same like Valid from date in SAP.

Please suggest.

Thanks

Top Tags