Hi,
Can't figure out why this error is happening. I'm not the most experienced user of LLBLGen but have used it on previous projects in the past with no issues.
Getting the following error:
The prefetch path element at index 0 in the passed in prefetch path for root entity type 12 is meant for root entity type 0 which isn't a subtype of 12. This means that you've added a prefetch path node to a Path of an unrelated entity, like adding OrderDetailsEntity.PrefetchPathProduct to a prefetch path for CustomerEntity.
On this line of code:
UserEntity theUser = new UserEntity(UserId);
IPrefetchPath2 path = new PrefetchPath2((int)EntityType.UserEntity);
path.Add(UserEntity.PrefetchPathAddress);
path.Add(UserEntity.PrefetchPathAddress.SubPath.Add(AddressEntity.PrefetchPathLuprovince));
using (DataAccessAdapter da = new DataAccessAdapter())
{
da.FetchEntity(theUser, path);
}
The problem is the subpath I am adding. This is the DB schema:
User TABLE:
AddressID
Address TABLE:
AddressID
ProvinceID
LuProvince TABLE:
ProvinceID
It must be something trivial.
What did I do wrong?
Thanks.