I downloaded the database and made the changes directly through SQL because I had to get it done right away.
We deleted some old users from our Mendix application and it broke our OData published service. The error we are getting is that the changedBy field on our entity is pointing to a system.user that no longer exists. I did not think that the Mendix framework would allow this; however, it has and I need to get it fixed.
My thought was to use a Retrieve Object activity and an XPAth contsraint of [ActivityTracker.Activity_Account = 5066549680791009]. This gives me an error of “Incompatible expression types: Administration.Acount, Integer.Long.”
I thought the Activity_Account which is a relationship was stored as long.
Anyone have any idea how I can fix this? I was going to retrieve all the affected objects and then update them to have a user id that is valid.
It looks like Mendix 8 has the CAST function but we’re still on 7.16.
$DeadUserID is from a Create Integer/Long variable activity.
Try instead with XPathconstraint:
[ActivityTracker.Activity_Account/Account/Id = 5066549680791009]
Instead of having to change the ID to another user, could you do the following:
I know this isn’t ideal, but this will allow you to remove the ‘changedby’ association from your OData published resource and still let you push the relevant data out in the OData feed. That way if another account gets deleted in the future, you won’t have to go through this trouble all over again.