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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Select Query vs. Parameter Query

Status
Not open for further replies.

JerSand

Technical User
Oct 25, 2000
74
US
The SQL for what seems a very simple query (it doesn't even involve a join) rounds-out this request for advice. When I run the query (which is saved, with its own distinctive name), ACCESS launches a "Query1.ActivityCd" box asking for a parameter value. I'd be grateful if someone would offer me ideas about why this would happen. If I just click on "OK", the query seems to run just fine, but the parameter request is unnerving.

Thanks.

JerSand

SELECT tblInspectionsAndTime.MineID, tblInspectionsAndTime.EventNo, tblInspectionsAndTime.ActivityCd, tblInspectionsAndTime.BeginDate, tblInspectionsAndTime.EndDate, tblInspectionsAndTime.SiteHrs, tblInspectionsAndTime.TravelHrs, tblInspectionsAndTime.ReportHrs
FROM tblInspectionsAndTime
WHERE tblInspectionsAndTime.MineID="3301173" AND (tblInspectionsAndTime.BeginDate Between #1/1/1998# And #12/31/1998#);
 
Access does not recognize ActivityCD as the name of a column in Query1.
 
Thanks, rac2. I followed the implications of your response, deleted ActivityCd, and the query ran smoothly. I'm befuddled, but satisfied. I had brought ActivityCd into the query in design view, using the simple drag-and-drop method. After deleting it and getting the query to run smoothly, I added ActivityCd again, and now there's no hangup.

Again, thanks for your helpful response, rac2.

JerSand
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top