Effort does not check for not null when inserting

Aug 2, 2013 at 10:12 AM
Hi
I'm using effort as my test databasae, but when I'm inserting entities I get no error for my columns marked as not null, any ideas?

I'm using EF 5 database first approach on a sql server database, and thanks in advance
Coordinator
Aug 12, 2013 at 8:30 PM
Hi,

There was a related problem I fixed today, check most recent source or nightly build (130813, not available at the writing of this comment) if it solved your problem.
Sep 13, 2013 at 8:05 AM
Hi,
I got the latest version form nightly builds using nuget but still have the problem, does my entity model needs to have some special attribute or configuration regarding non nullable columns (beside nullalble="false")?

this is my entity storage model, hope it helps:
 <EntityType Name="Roles">
          <Key>
            <PropertyRef Name="RoleId" />
          </Key>
          <Property Name="RoleId" Type="int" Nullable="false" StoreGeneratedPattern="Identity" />
          <Property Name="Name" Type="nvarchar" Nullable="false" MaxLength="32" />
          <Property Name="Display" Type="nvarchar" Nullable="false" MaxLength="32" />
          <Property Name="IsSystem" Type="bit" Nullable="false" />
</EntityType>
Coordinator
Oct 23, 2013 at 10:31 AM
Edited Oct 23, 2013 at 10:32 AM
Sorry for the late response.

I am not able to reproduce this. I am using the exact same schema and the following code:
Role role = new Role();
role.IsSystem = false;
role.Display = "display";

ctx.Configuration.ValidateOnSaveEnabled = false;

ctx.Roles.Add(role);
ctx.SaveChanges();
And I got the following exception:
DbUpdateException:          An error occurred while updating the entries. See the 
                            inner exception for details.
UpdateException:            An error occurred while updating the entries. See the 
                            inner exception for details.
TargetInvocationException:  Exception has been thrown by the target of an invocation.
ContraintException:         Column 'Name' cannot be null. Error code: GenericError
Oct 26, 2013 at 6:28 AM
Hi
Thank you for your effort, would you please specify which versions of effort and nmemory your using
Thanks again
Coordinator
Oct 27, 2013 at 9:57 PM
I used 1.0.0-beta4-131023, but I upgraded the test project to 1.0.0-beta5, and it worked too. Entity Framework is 5.0.