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

New access user

Status
Not open for further replies.

Ben6550

Technical User
Jan 8, 2004
16
GB
Where abouts do i programme a query such as:
SELECT SUM(Days) AS (Total Days)
FROM Weeks
WHERE =Tuesdays

The only queries i know how to use are using the wizard.
 
Ben,

As along as the Weeks table exist with the fields that you have stated you can do the following.

Select the option for a new query.
When prompted for a new table click cancel.
At this point you should have an empty query screen.
Select view and SQL View.
Cut and paste your query.
Now switch back to design view.

If everything is correct the QBE (Query By Example) grid will be filled in based on your SQL statement.

Use the SQL statement in answers allows the forum members to not have to try to step someone through how to use the QBE which can be cumbersome depending on how complex a query is.


Steve
 
Are you attempting to count the number of records in the table "Weeks" where a field named "Days" has the value "Tuesday"?
SELECT Count(Days) AS (Total Days)
FROM Weeks
WHERE ="Tuesday";

If my WAG is wrong, please provide a better description of your request.

Duane
MS Access MVP
Find out how to get great answers faq219-2884.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top