Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Error Checking when using Select/Parameter Query to open Form

Status
Not open for further replies.

JimUK

Technical User
Jan 1, 2001
57
US
I have a table called "NEWETR1" and am using a Select Query using the "like" statement to find a specific "ETR". The ETR number has the format 2003-0001 and is a text field. Query works fine and opens my Read_ETR Form and shows me all the data. What I need is a way to check for input errors. Tried using validation on table level and on form level. Is there a way to check for invalid entry in sql query itself. Things I want to check for are Null entry, Invalid format, (anotherwords something other then 2003-0001) i.e. 2003-001 and range checking which eludes me because the table has ETR's from years as far back as 1984-0001 to present, so it's not as simple as doing Max/Min. Any ideas greatly appreciated.


Jim
 
You can use a recordset. Pull the data into a recordset in the background...check it and then load it into a form

I hope this is what you are asking
 
I thought that was one possible way to solve it. Recordsets give me the shivers but will make an attempt at it. Still using Access 97 here so should be able to find something already written up on it. Thanks for the input.

Jim
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top