Skip to main content
12-Amethyst
May 31, 2022 7:44 AM UTC
Solved

WTUser vs WTPrincipal

Hello, I am currently querying users by email.

 

I am doing it this way - so target is WTUser

querySpec.appendWhere(new SearchCondition(WTUser.class, WTUser.EMAIL, SearchCondition.EQUAL, email,false), new int[]{0});

 

But I also found this way:

OrganizationServicesHelper.manager.queryPrincipals(...)

 

Do both solutions go through the entire user list of Windchill since the second one is for principals and not for users?

And what is the general difference between WTUser and WTPrincipal or are they the same?

 

BR

HelesicPetr
22-Sapphire II
Jun 1, 2022 6:13 AM UTC

Hi @TG_10272716 

A WTUser is subClass of the WTPrincipal so yes they are "same".

PetrH

1 reply

HelesicPetr
22-Sapphire II
Jun 1, 2022 6:13 AM UTC

Hi @TG_10272716 

A WTUser is subClass of the WTPrincipal so yes they are "same".

PetrH

Translate