UPDATE tcmf
SET ClientModules = tcm.ClientModuleID
FROM VCLib.T_CLIENT_MODULE_FEATURE tcmf, VCLib.T_CLIENT_MODULES AS tcm
WHERE tcmf.Name = 'HideVmpReferral'
  AND tcm.ModuleType = 'HospitalizationControlClientModule'
  AND tcmf.ClientModules = (
    SELECT ClientModuleID 
    FROM VCLib.T_CLIENT_MODULES 
    WHERE ModuleType = 'FondClientModule'
  )