Age Calculations

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a Form that gets its information from a huge Table of information.
With the help of this fantastic group, I have created a Query which
automatically figures out the age of each rescued animal in years and months.
Now, I need to add that information to the Form, but the Form will not allow
me to use the Query that gets its information from the Table. How can I
overcome this obstacle?
 
Becky said:
I have a Form that gets its information from a huge Table of
information. With the help of this fantastic group, I have created a
Query which automatically figures out the age of each rescued animal
in years and months. Now, I need to add that information to the
Form, but the Form will not allow me to use the Query that gets its
information from the Table. How can I overcome this obstacle?

What does "...not allow me..." mean? Are you being physically restrained?
:-)

Do you want to change the RecordSource of the form from the current table to
the new query or do you want to see data from both? The former should just
be a matter of changing the RecordSource property for the form from whatever
it is now to the name of the query.
 
... "Are you being physically restrained?"

Yes, my hands are tied!!!

My Form was designed from the master Table that contains all the information
we use for all our reports, queries, etc. Since it's not good to put a
calculation in a Table, I created a Query to obtain an Age field (in Yrs and
Mos) using the DOB for the calculation. It was a 3-step process because I
first created a formula for the age in years in one field, then the number of
months in another field, then combined those two fields and added the terms
"yrs" and "mos" in the 3rd field, and the 3rd field is the one I want showing
in the Form.

I created a relationship between my Table and my Query, but when I try to
add the Yrs and Mos field to my form, I get an error message that says I
can't use a query that's tied to the Table that the form comes from.

Does any of this make sense?
 
To answer your last question: Yes, I would like to see information from both
the Table and Query.
 
Base your form on the QUERY. Your query should include all the fields from
the table, plus your calculated values.

Rick B
 
Becky said:
... "Are you being physically restrained?"

Yes, my hands are tied!!!

My Form was designed from the master Table that contains all the
information we use for all our reports, queries, etc. Since it's not
good to put a calculation in a Table, I created a Query to obtain an
Age field (in Yrs and Mos) using the DOB for the calculation. It was
a 3-step process because I first created a formula for the age in
years in one field, then the number of months in another field, then
combined those two fields and added the terms "yrs" and "mos" in the
3rd field, and the 3rd field is the one I want showing in the Form.

I created a relationship between my Table and my Query, but when I
try to add the Yrs and Mos field to my form, I get an error message
that says I can't use a query that's tied to the Table that the form
comes from.

Does any of this make sense?


Your query is using the original table for input right? If so, just add all of
the rest of the fields from the table to the query and then use the query
*instead of* your table rather that trying to join to it.
 
Back
Top