UPDATE
  obpm2.tenant_users
SET
  authenticated_status = '#{authenticated_status}',
  authenticated_result = IF('#{authenticated_status}'='0' || '#{authenticated_status}'='1','','#{authenticated_result}'),
  authenticated_time = '#{authenticated_time}',
  background_screening_status = '#{background_screening_status}',
  last_background_screening_time = '#{last_background_screening_time}'
WHERE id=SUBSTRING('#{id}',1,INSTR('#{id}','___')-1)