This error happens as a result of the contact not having the tenant field set on the ca_contact table. To resolve this, update the tenant\set the tenant field via a SQL script:
SET tenant = '0xAB01E3010A06F143A6668709256E2B8B'
WHERE UserID = 'xxxxx'
xxxxx = UserID of the contact getting the error
0xAB01E3010A06F143A6668709256E2B8B = UUID of the tenant
Alternatively, you can achieve same result using pdm_extract and pdm_userload commands