async def insert_tmp_meo_vg(self, meo: MasterEOResId, vg: VersionGroupResId): sql = "insert into TmpMasterEOVersionGroups(meoId,versionGroupId) values (%s,%s);" return await self.do_sql(sql, [meo.id(), vg.id()])
async def versiongroup_metadatameos_by_meo(self, meo: MasterEOResId) -> Dict[VersionGroupResId, MasterEOResId]: return await self.vg_mmeo_result("select * from VersionGroupMetadataMeos where masterEOId=%s;", meo.id())
async def master_eo_timing_by_meo(self, meo: MasterEOResId) -> List[MasterEOResId]: sql = "select * from MasterEOTimingView where masterEoId=%s;" rs = await self.do_sql(sql, [meo.id()]) return [MasterEOResId.of_id(x["masterEoId"]) for x in rs]
async def find_tmp_mastereo_to_versiongroups_by_meo(self, resid: MasterEOResId) -> \ Dict[MasterEOResId, VersionGroupResId]: sql = "select * from TmpMasterEOVersionGroups where meoId = %s;" rs = await self.do_sql(sql, [resid.id()]) return {MasterEOResId.of_id(x["meoId"]): VersionGroupResId.of_id(x["versionGroupId"]) for x in rs}