0
I did that last breath:
var resultado = (
from pdv in db.T_PDV
join tarefa in db.T_TarefaParceiro on pdv.CNPJ equals (tarefa.CNPJ) into _trf
from g1 in _trf.DefaultIfEmpty()
join parceiro in db.T_OsParceiro on tarefa.IDTarefaParceiro equals (parceiro.IDTarefaParceiro) into _pcr
from g2 in _pcr.DefaultIfEmpty()
join acao in db.T_Acao on tarefa.IDAcao equals (acao.IDAcao) into _acao
from g3 in _acao.DefaultIfEmpty()
join proxima in db.T_ProximaAcao on acao.IDAcao equals (proxima.IDAcao) into _pxm
from g4 in _pxm.DefaultIfEmpty()
join info in db.T_InfoClientePdv on pdv.CNPJ equals (info.CNPJ) into _info
from g5 in _info.DefaultIfEmpty()
join cliente in db.T_Cliente on info.IDCliente equals (cliente.IDCliente) into _clie
from g6 in _clie.DefaultIfEmpty()
select new
{
pdv.CNPJ,
pdv.DataCadastro,
cliente.NomeFantasia,
acao.Acao,
proxima.ProximaAcao,
parceiro.NumOs,
parceiro.DataVisita,
parceiro.DataAgendamento
}).ToList();
On that line is making that mistake:
join parceiro in db.T_OsParceiro on tarefa.IDTarefaParceiro equals (parceiro.IDTarefaParceiro) into _pcr
This is the error that is giving. I know that the task table, is already in left
. How do I get her back into another left
?
The name 'task' is not in Scope on the left side of 'equals'. Consider swapping the Expressions on either side of 'equals'.