Jerry-
You don't need to add a field to your table. Use a query as the Record Source for any Form or Report the user sees and generate a field:
Flagged: [MathAccomodations] Or [ScienceAccomodations] Or [SocialStudiesAccomodations] Or [ReadingAccomodations]
Display the generated Flagged field on your Form or Report to inform the teachers.
John Viescas, Author
Microsoft Access 2010 Inside Out
Microsoft Access 2007 Inside Out
Microsoft Access 2003 Inside Out
Building Microsoft Access Applications
SQL Queries for Mere Mortals
http://www.viescas.com/
(Paris, France)
-----Original Message-----
From: MS_Access_Professionals@yahoogroups.com [mailto:MS_Access_Professionals@yahoogroups.com] On Behalf Of Jerry Mathers
Sent: Monday, January 28, 2013 8:48 PM
To: MS_Access_Professionals@yahoogroups.com
Subject: Re: [MS_AccessPros] Cycling through records
There are fields for four different subjects. Here are the fields I need to check:
MathAccommodations {Yes/No data type}
ScienceAccommodations {Yes/No data type} SocialStudiesAccommodations {Yes/No data type} ReadingAccommodations {Yes/No data type}
These fields determine if a student has any accommodations that need to be applied during testing or other similar types of classroom activities that require the use of these accommodations.
If any, or all of the four fields are True I want to set Flagged to True since the Flagged field is the one being displayed for the teachers so they know to look into what the specific accommodations are for any flagged students.
Jerry
________________________________
From: John Viescas JohnV@msn.com>
To: MS_Access_Professionals@yahoogroups.com
Sent: Monday, January 28, 2013 12:02 PM
Subject: RE: [MS_AccessPros] Cycling through records
Jerry-
If you can state what you're looking for as Conditions in a query, you can do it it one fell swoop with an Update query.
UPDATE MyTable
SET Flagged = True
WHERE (FldA Like "*something*") or ....
Spell out the conditions you're looking for, and I'll help you write the SQL.
John Viescas, Author
Microsoft Access 2010 Inside Out
Microsoft Access 2007 Inside Out
Microsoft Access 2003 Inside Out
Building Microsoft Access Applications
SQL Queries for Mere Mortals
http://www.viescas.com/
(Paris, France)
-----Original Message-----
From: MS_Access_Professionals@yahoogroups.com [mailto:MS_Access_Professionals@yahoogroups.com] On Behalf Of Jerry Mathers
Sent: Monday, January 28, 2013 5:38 PM
To: MS_Access_Professionals@yahoogroups.com
Subject: [MS_AccessPros] Cycling through records
I'm stuck on a problem that requires me to cycle through each record in a table looking for certain conditions in specific fields. If I find one of these conditions I need to flag that record (I will probably just put a check in a Yes/No field called Flagged).
The part I cannot figure out is how to cycle through all of the records in a table until I run out of them.
Obviously it to be something like this:
Step 1 Start with the first record
Step 2 Look for the conditions and turn on Flagged when true Step 3 Move to the next record Step 4 Look for the conditions and turn on Flagged when true Step 5 Repeat Steps 3 & 4 until there are no more records
It is Steps 1, 3 & 5 that are my problem. Can you point me in the right direction; maybe a bit of sample code or a website where I might find out how to do this?
Thanks for any help you can provide.
[Non-text portions of this message have been removed]
------------------------------------
Yahoo! Groups Links
[Non-text portions of this message have been removed]
------------------------------------
Yahoo! Groups Links
Reply via web post | Reply to sender | Reply to group | Start a New Topic | Messages in this topic (5) |
Tidak ada komentar:
Posting Komentar