无法从system.linq.iqueryable转换为system.linq.parallelquery

时间:2016-06-18 02:46:56

标签: asp.net-mvc oracle entity-framework ado.net linq-to-entities

我用来将查询从oracle数据库转换为查询linq,但是我收到错误。 <Button> <Viewbox Width="20" Height="20"> <ContentPresenter ContentTemplate="{StaticResource Info}" /> </Viewbox> </Button> 。你能帮我解决这个问题吗? 这是我的查询oracle

cannot convert from system.linq.iqueryable to system.linq.parallelquery

这是我尝试转换为linq,

select kd_supp
from
(
select kd_supp
from
(
SELECT 
    KD_SUPP, NPWP_SUPP, 1 seq
FROM TAX.MPMISTAX_MSTSUPP
UNION 
(
    SELECT 
    b.KD_DLR KD_SUPP, b.DLR_NPWP2 NPWP_SUPP, 2 seq
    FROM MPMIS_MSTDEALER b 
    WHERE b.dlr_status<>'C' AND
    DLR_NPWP2 IS NOT NULL
)
) a
    where
    NPWP_SUPP = '016430472629001'
    order by seq desc
)
where
rownum <=1

我在(from data in MpmistaxMstsupps join kd_supp in MpmisMstdealerView on new {kd = data.KdSupp} equals new {kd = kd_supp.KdDlr} into join_kode_supp from result_kd in join_kode_supp.DefaultIfEmpty() join npwp_supp in MpmisMstdealerView on new {npwp = data.NpwpSupp} equals new {npwp = npwp_supp.DlrNpwp2} into join_npwp_supp from result_npwp in join_npwp_supp.DefaultIfEmpty() where data.NpwpSupp == "016430472629001" select new { KdSupp = result_kd.KdDlr, NpwpSupp = result_npwp.DlrNpwp2}) .Concat( from data in MpmistaxMstsupps join kd_supp in MpmisMstdealerView on new {kd = data.KdSupp} equals new {kd = kd_supp.KdDlr} into join_kode_supp from result_kd in join_kode_supp.DefaultIfEmpty() join npwp_supp in MpmisMstdealerView on new {npwp = data.NpwpSupp} equals new {npwp = npwp_supp.DlrNpwp2} into join_npwp_supp from result_npwp in join_npwp_supp.DefaultIfEmpty() where result_kd.DlrStatus != "C" && result_npwp.DlrNpwp2 != null select new { result_kd.KdDlr, result_npwp.DlrNpwp2 }) 收到错误。我希望你能帮我解决问题? enter image description here

0 个答案:

没有答案