Skip to main content
10-Marble
April 1, 2025
Question

Type incompatability for PTC.PrincipalMgmt.User error.

  • April 1, 2025
  • 2 replies
  • 368 views

Version: Windchill 13.0

 

Use Case: I am trying to access an API in the change management domain which GETs some data and i want to make a get call using a filter by the name "Owner" which is of PTC.PrincipalMgmt.User type, trying to build a simple filter query here but when using queries like Owner eq " OwnerName " I get an error : { "error": { "code": null, "message": "The types 'PTC.PrincipalMgmt.User' and 'Edm.String' are not compatible." } } which clearly signals that the query format is wrong since i need to pass the object and i have passed string. So what change do i need to perform in my GET call.


Description:

I am trying to access an API in the change management domain which GETs some data and i want to make a get call using a filter by the name "Owner" which is of PTC.PrincipalMgmt.User type, trying to build a simple filter query here but when using queries like Owner eq " OwnerName " I get an error :
{
"error": {
"code": null,
"message": "The types 'PTC.PrincipalMgmt.User' and 'Edm.String' are not compatible."
}
}
which clearly signals that the query format is wrong since i need to pass the object and i have passed string. So what change do i need to perform in my GET call.

2 replies

joe_morton
18-Opal
18-Opal
April 2, 2025

hi,

Can you share the snippet of code where you do the query?

12-Amethyst
April 4, 2025

Please share the REST URL which you are trying to exceute for Change object ?