Mark Tabor

Mark Tabor

  • 585
  • 2k
  • 460.8k

Showing data from two tables

Aug 7 2024 2:45 PM

Dear all I would like to ask a question I am having one property table in which I have (Id,Name,price,TypeID) TypeID is integer here and basically I have property type another table (id,type_name) 

now when i am binding my viewmodel like 

MYWM.Property=dbcontext.property.ToLuist(), it get all columns values from property table but the issue is for propertyID here i have id which I need to show property type name from property type table how to us include and add that column as well based in TypeID, in this line bcontext.property.ToLuist(), remember i have no forieng key specify only the matching thing is i have property type id in property table which mades with ID column of property type table 


Answers (1)