varseReturnUpdateQuery=db.Set<BBAC_SE_DETAIL>().FromSqlRaw("select distinct b.* from (select * FROM [BQ_SA].[dbo].[Set_BBAC_SE_DETAIL] where TransType=-1 and Remark is null and BusinessType=1) a left join [BQ_SA].[dbo].[Set_BBAC_SE_DETAIL] b on a.PN=b.PN and a.LU=b.LU where b.TransType=1 and b.BusinessType=1 and b.ProType in (3,7,0) and b.IsDeleted=0");
varhbpoReturnUpdateQuery=db.Set<HBPO_SE_DETAIL>().FromSqlRaw("select distinct b.* from (select * FROM [BQ_SA].[dbo].[Set_HBPO_SE_DETAIL] where TransType=-1 and Remark is null and BusinessType=2) a left join [BQ_SA].[dbo].[Set_HBPO_SE_DETAIL] b on a.PN=b.PN and a.LU=b.LU where b.TransType=1 and b.BusinessType=2 and b.ProType in (3,7,0) and b.IsDeleted=0");