from TRAN_S in (
from x in (
from x in _context.DwPropertyDetails
where
x.LandId == 2 &&
x.TransactionPrice != null &&
x.FlatType == "Studio"
select new
{
TRANSACTION_PRICE =
x.TransactionPrice ?? (long?)0,
ACTUAL_SIZE = x.ActualSize ?? (long?)0,
rank = 0 + 1
})
where
x.rank == 1
select new
{
TRAN_S = (int?)x.TRANSACTION_PRICE ?? (int?)0
})
from PER_FT_S in (
from x in (
from y in _context.DwPropertyDetails
where
y.LandId == 2 &&
y.TransactionPrice != null &&
y.FlatType == "Studio"
select new
{
PER_FT_S =
y.TransactionPrice / y.ActualSize ??
(long?)0,
rank = 0 + 1
})
where
x.rank == 1
select new
{
PER_FT_S = (int?)x.PER_FT_S ?? (int?)0
})
select new
{
TRAN_S,
PER_FT_S
};
Must return TRAN_S and PER_FT_S column