R
Rustle
I work for a shelter and occasionally we have to ask a guest to leave
for some reason. We call this being "barred" from our services. When
a staff person opens the main data entry form, based on "tblGuest",
there is a subform on a tab where this information can be entered. If
a guest is barred, a record is placed using the subform in
"tblBarInformation". The fields in this table are "BarID",
"BarLink" (equal to GuestID from tblGuest), "BarDate", and
"BarExpireDate."
Basically, I want to create a field in tblGuest that indicates the
guest's status as Barred if there is a current bar record in
tblBarInformation. So far, I've created a query such as this:
Field: BarID BarLink BarCurrent: [BarExpireDate]
Totals: GroupBy Group By Last
Criteria: >=Date()
This gives me all the bars that are current as of today. I want to
use this information to update the guest table somehow if the guest
has a current bar. I can't trust staff people to do this as they
aren't always on top of things.
More simply, how can I set a value in one table if there is date value
in another table that is equal to today or in the future { >=
Date() }?
Could I could create some kind of update query that runs when the main
form is opened to that guests record and that would set the status in
Guest? Or, should I somehow run an event in the subform when data is
updated there?
Thanks!
Russ
for some reason. We call this being "barred" from our services. When
a staff person opens the main data entry form, based on "tblGuest",
there is a subform on a tab where this information can be entered. If
a guest is barred, a record is placed using the subform in
"tblBarInformation". The fields in this table are "BarID",
"BarLink" (equal to GuestID from tblGuest), "BarDate", and
"BarExpireDate."
Basically, I want to create a field in tblGuest that indicates the
guest's status as Barred if there is a current bar record in
tblBarInformation. So far, I've created a query such as this:
Field: BarID BarLink BarCurrent: [BarExpireDate]
Totals: GroupBy Group By Last
Criteria: >=Date()
This gives me all the bars that are current as of today. I want to
use this information to update the guest table somehow if the guest
has a current bar. I can't trust staff people to do this as they
aren't always on top of things.
More simply, how can I set a value in one table if there is date value
in another table that is equal to today or in the future { >=
Date() }?
Could I could create some kind of update query that runs when the main
form is opened to that guests record and that would set the status in
Guest? Or, should I somehow run an event in the subform when data is
updated there?
Thanks!
Russ