question

GuhananthS-8954 avatar image
0 Votes"
GuhananthS-8954 asked YiyiYou-MSFT commented

Linq GetAll join 3 tables issues not working

Hi
I have three Repository

  1. FormPages

  2. PackageMapping

  3. Packets

i write query in sql like this
select a.Id,b.PacketName,c.FormType,c.PageNumber,a.DisplayOrder,c.FormType from PacketMappings a inner join Packets b on a.PacketId=b.Id inner join FormPages c on c.Id = a.Id

This return results .

i wrote

private readonly IRepository<FormPage> _formPageRepository;
private readonly IRepository<Packet> _packetRepository;
private readonly IRepository<PacketMapping> _packetmappingRepository;



public async<PacketDetails> Split(PacketDetails input)
{

var str = await __packetmappingRepository.GetAll().ToListAsync();
how to join other table repository

}

dotnet-aspnet-core-mvc
· 1
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Hi,GuhananthS-8954,

Why not try to create a new repository which joins 3 tables?

0 Votes 0 ·

0 Answers