Code not compilable

Posts   
 
    
Sokon1
User
Posts: 97
Joined: 17-Jul-2006
# Posted on: 17-Aug-2006 10:13:18   

Hi,

I added a custom 1:1 relationship between two tables and let LLBLGen generate code, which can't be compiled. There ist one line where the compiler misses a parameter:


/// <summary> Retrieves the related entity of type 'PartnerEntity', using a relation of type '1:1'</summary>
/// <param name="forceFetch">if true, it will discard any changes currently in the currently loaded related entity and will refetch the entity from the persistent storage</param>
/// <returns>A fetched entity of type 'PartnerEntity' which is related to this entity.</returns>
public virtual PartnerEntity GetSinglePartner(bool forceFetch)
{
if( ( !_alreadyFetchedPartner || forceFetch || _alwaysFetchPartner) && !base.IsSerializing && !base.IsDeserializing )
{

PartnerEntity newEntity = PartnerEntity.FetchPolymorphic(base.Transaction, , base.ActiveContext);
if(base.ParticipatesInTransaction)
{
 ...

The method 'FetchPolymorphic' expects 3 values, the second value is missing. Any idea?

using v2.0.0.0, self servicing and "sqlserverspecific.net20" template.

Thanks again in advance for your help!

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39927
Joined: 17-Aug-2003
# Posted on: 17-Aug-2006 18:59:20   

You added the relation to both sides of the relation? Or just to one side? If to one side: add the relation to BOTH sides.

Frans Bouma | Lead developer LLBLGen Pro
Sokon1
User
Posts: 97
Joined: 17-Jul-2006
# Posted on: 21-Aug-2006 11:09:04   

This option is checked by default, right? I don't remember having changed a thing. In the meantime, we changed our structure a little, so this problem no longer exists. But next time the problem reappears I'll check if that's the problem. Thanks for your answer!