select md.code,v.code from cfvariable as vinner join cfvarmdl as mv on v.idvarmdl=mv.idvarmdlinner join cfdevmdl as md on mv.iddevmdl=md.iddevmdl and md.code='YH17'where v.code ~ '^Temp\d$'