Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Generated Business Rules for Numeric Columns
Message
De
06/03/2009 11:18:25
 
 
À
06/03/2009 10:21:20
Timothy Bryan
Sharpline Consultants
Conroe, Texas, États-Unis
Information générale
Forum:
ASP.NET
Catégorie:
The Mere Mortals .NET Framework
Versions des environnements
Environment:
C# 3.0
OS:
Windows XP SP2
Network:
Windows XP
Database:
MS SQL Server
Application:
Web
Divers
Thread ID:
01383003
Message ID:
01386221
Vues:
33
Tim,

I agree with everything you are saying. The problem is that I can't check for the empty value because I'm using the entity centric appraoch, which when using non-nullable database columns, the corresponding entity properties do not have nullable data types, which means they are automatically initialized to zero if the UI control is empty. The dataset carries the null (or empty string) from the UI but the entity ends up having a zero. This inconsistency is what makes it impossible to test for the null (or empty string) using the business rules in the entity centric approach.

The only work around I can think of is to have the entities always use nullable data types and use the automatically generated business rules to enforce the non-nullable rules.

I'm curious to see how this is going to work in the next release that uses the entity framework.

Al
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform