|
| |
|
|
dustie
Posts: 2 Joined: 3/22/2008 Status: offline
|
SQL for MSAccess: Use of AND & OR - 3/22/2008 10:36:26
Individuals to receive credit for completing 5 courses. They must complete 1, 2, and 3 and then either 4 or 5 AND either 6 or 7. Some will complete all 7 - but in my results, I only want to show the first five completed. I keep getting all 7 results. How do I get just the first 5? course 1 course 2 course 3 course 4 or 5 course 6 or 7
< Message edited by dustie -- 3/22/2008 11:16:08 >
|
|
|
|
rdouglass
Posts: 9280 From: Biddeford, ME USA Status: offline
|
RE: SQL for MSAccess: Use of AND & OR - 3/22/2008 11:23:26
quote:
I only want to show the first five completed. Hi and Welcome to OutFront. "SELECT TOP (5) * FROM...." That'll give you the top 5 records returned but somehow I don't think that's quite what you're looking for. Maybe you can clarify?
_____________________________
Don't take you're eye off your final destination. ASP Checkbox Function Tutorial.
|
|
|
|
dustie
Posts: 2 Joined: 3/22/2008 Status: offline
|
RE: SQL for MSAccess: Use of AND & OR - 3/22/2008 11:40:04
You are right - not quite what I am looking for. They need to complete 5 courses....the first three are all required, the final two are their choices AND the order in which they complete 5 courses is up to them. 1) Course A (required) 2) Course B (required) 3) Course C (required) 4) Either Course D OR Course E 5) Either Course F OR Course G Does this help?
|
|
|
|
rdouglass
Posts: 9280 From: Biddeford, ME USA Status: offline
|
RE: SQL for MSAccess: Use of AND & OR - 3/22/2008 12:56:00
Well, it depends. Are you using the DRW or straight ASP or what to connect? Can you create the query with the appropriate results inside Access itself? If you can do that, then you can connect the DRW right to the query itself instead of putting the statement inside the DRW. If you're using ASP, I'd just set a flag for each one while you're looping thru your recordset or array. I suspect either of these might need some further explination so if possible, could you post what code and/or methods you're currently using?
_____________________________
Don't take you're eye off your final destination. ASP Checkbox Function Tutorial.
|
|
New Messages |
No New Messages |
Hot Topic w/ New Messages |
Hot Topic w/o New Messages |
Locked w/ New Messages |
Locked w/o New Messages |
|
Post New Thread
Reply to Message
Post New Poll
Submit Vote
Delete My Own Post
Delete My Own Thread
Rate Posts
|
|
|