You use the validators at the client end, either the win form or the web page.
Say you have a textbox that the user enters a number in. You apply a RangeValidator to the textbox which, when the button to insert the data is clicked, checks the value in the textbox is within the specified range. If not,processing stops.
If you want to do the validation in the database you can set up check constraints on the column. Here is a sample table definition that restricts a column to positive numbers:
CREATE TABLE Persons
P_Id int NOT NULL,
LastName varchar(255) NOT NULL,
Help! I want to create a java program that finds the highest even integer among the values entered by the user. Stop asking values when a value less than 1 have been entered. If no even integer is entered, display "No Even Integer"
Hi, as I was told that my code doesn’t scale well at all, I thought perhaps I’d try to get a better understanding of interfaces/abstract classes and classes and the relationship between them.
I don’t want at this stage work on a big separate project as I've already got plenty ...