MetaForeignKeyColumn is marked with RequiredAttribute

Posts   
 
    
lubo278
User
Posts: 32
Joined: 10-Apr-2007
# Posted on: 23-Mar-2009 17:27:07   

Hi, I am working with Dynamic Data (from MS) and again I have a problem which is not exactly LLBL problem, but I cannot solve it withou you.

The problem is, that I have a column/field that is FK in a table. In DD it shows as two columns (i.e. IdUser and User one is **MetaColumn **and the other is MetaForeignKeyColumn). This relation is not required by DB (IdUser is nullable), MetaColumn IdUser is not marked with **RequiredAttribute **(which is correct), but User column (of type MetaForeignKeyColumn) is. It breaks a lot of things this way (Required field validators, FK filters, fields, etc.). I have no idea how MetaData providers work in DD, If you just could give me some hints simple_smile .

Are there source codes available to SD.LLBLGen.Pro.DynamicDataSupportClasses.NET35.dll ?

thanks Lubo


LLBL GenPro 2.6 .NET 3.5 MS SQL 2005

lubo278
User
Posts: 32
Joined: 10-Apr-2007
# Posted on: 23-Mar-2009 17:33:46   

Ehm, without further questions simple_smile

Is this correct?

Assembly: SD.LLBLGen.Pro.DynamicDataSupportClasses.NET35.dll Method: BuildEntityFieldProviderListAssociationsProperties()

  LLBLGenProEntityFieldProvider item = new LLBLGenProEntityFieldProvider(this, descriptor2.PropertyType, false, false, false, false, 0, descriptor2.Name, **false**, relationProvider);

if the last false is always false, I think DD marks MetaColumn Required

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39859
Joined: 17-Aug-2003
# Posted on: 24-Mar-2009 10:10:58   

True, will correct it, just a sec.

The new build is attached. This should correct the problem.

Attachments
Filename File size Added on Approval
SD.LLBLGen.Pro.DynamicDataSupportClasses.NET35.dll 21,504 24-Mar-2009 10:14.54 Approved
Frans Bouma | Lead developer LLBLGen Pro
lubo278
User
Posts: 32
Joined: 10-Apr-2007
# Posted on: 26-Mar-2009 08:09:06   

Works great! Thanks!