Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / SQL Server / ADP / October 2007

Tip: Looking for answers? Try searching our database.

2 MS Access validation Q's

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
busyguy1 - 20 Oct 2007 04:43 GMT
I want to prevent entry into a field in Access, using home/student 2007
version.  Field name FromDate and field name ThruDate.  If i plug in the
validation text [ThruDate]>=[FromDate] i get an error message "Invalid SQL
-cannot use multiple columns in a column level CHECK constraint".  How can I
validate so the thru date is always greater than the from date. note: the
from date does increase.

Also, how do I validate a field whereby i want the entry to be in the %
format, and with only a 2 or 3 digits number the % sign.   I do not need the
decimal format.  I will be entering values such as 90% and 150%. Always with
the % sign. Thanks!
Signature

busyguy1

Sylvain Lafontaine - 20 Oct 2007 18:33 GMT
First, this newsgroup is about ADP and SQL-Server and has nothing to do with
MDB files.

Second, in your case, you must make the distinction between column
validation rules and table validation rules.  As you want to put a
constraint on the combinaison of two or more columns, you add a table
constraint instead of a column constraint: while in design mode, right click
on the *title bar* and choose Properties from the contextual menu to enter
the properties dialog window for the table (instead of the properties dialog
window for one of the columns).

For your second question, I don't know.

Finally, usually column and table constraints is not the best idea.
Instead, you should create a form and put all the validation there.  It's
the only way to write complex validation rules.

Signature

Sylvain Lafontaine, ing.
MVP - Technologies Virtual-PC
E-mail: sylvain aei ca (fill the blanks, no spam please)

>I want to prevent entry into a field in Access, using home/student 2007
> version.  Field name FromDate and field name ThruDate.  If i plug in the
[quoted text clipped - 10 lines]
> with
> the % sign. Thanks!
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.