Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Generated Business Rules for Numeric Columns
Message
De
05/03/2009 18:12:03
 
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:
01386041
Vues:
37
Kevin,

That would work in some cases, but I have a requirement where zero is the least likely value so it wouldn't make sense to default it to zero. There is also the possibility of the user accidently deleting the value and then zero would inadvertently be inserted. I could probably prevent this with client-side validation, but doesn't that kind of defeat the purpose of having the business rules in the business objects?

I think part of the problem is that the web controls are really text based controls (HTML) where an empty string is natively acceptable. The MM datasets retain the null value but the entities do not when the column is non-nullable.

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

Click here to load this message in the networking platform