Access an Entity Query in Linq -- Lightswitch application

173 Views Asked by At

I am using lightswitch. Now i have an entity name: Jobs and that entity "Jobs" has a query item name Query1. Now i would like to access Query1 using linq.

var qryUser = ds.sspData.Jobs.Where(a => a.UserName.Contains(uName)).FirstOrDefault();

That is a linq query on the entity Jobs. I want a linq query on Query1. I am not figuring it. help me.

1

There are 1 best solutions below

0
On

I was able to figure it out:

var q = (from a in ds.sspData.Query1() select a).Execute().ToList();