hi
i ask subsonic for a table in my database it returs the table and all other tables connected threw foreign keys,
cant i stop it bringing back all the extra table info??
here is my code:
[WebMethod]
[ScriptMethod]
public List<DealEquipment> GetDealEquipment(Guid DealID)
{
List<DealEquipment> dealEquipmentList = new List<DealEquipment>();
Deal deal = new Deal(DealID);
DealEquipmentCollection dealEquipmentCollection = deal.DealEquipmentRecords();
foreach (DealEquipment dealEquipment in dealEquipmentCollection)
{
DealEquipment dealEquipmentTemp = dealEquipment;
DealEquipmentSerialNumberCollection dealEquipmentSerialNumberCollection = new DealEquipmentSerialNumberCollection().Where(DealEquipmentSerialNumber.Columns.FkDealEquipmentID, Comparison.Equals, dealEquipmentTemp.PkDealEquipmentID).Load();
dealEquipmentTemp.objSerialNumber = new List<DealEquipmentSerialNumber>();
foreach (DealEquipmentSerialNumber dealEquipmentSerialNumber in dealEquipmentSerialNumberCollection)
{
dealEquipmentTemp.objSerialNumber.Add(dealEquipmentSerialNumber);
}
dealEquipmentList.Add(dealEquipmentTemp);
}
return dealEquipmentList;
}
The dealEquipmentList that i return is suppose to only contain my foreinkey to supplier, but the supplier tables info is also included
this is a problem since the supplier object contains huge binary images
i try to set it to null but it is ignored
any ideas?