A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » New Users
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Calculating in table field



 
 
Thread Tools Display Modes
  #1  
Old April 15th, 2005, 07:27 PM
:\(
external usenet poster
 
Posts: n/a
Default Calculating in table field

Hi.
I've created a field in a form that calculates the age from the birthdate of
the previous field.
But I would like it to figure in the table. All the help info only tells you
how to do it in a form.
Can someone please tell me how to be able to do either have the table see
the age from the form or how to put the format in the table field.
Thanks
J.


  #2  
Old April 15th, 2005, 07:45 PM
Rick B
external usenet poster
 
Posts: n/a
Default

As answered alll the time in these newsgroups (did you try searching?) you
don't store calculated results in a table. It is redundnat and what happens
if one of the values change?

Search and read previous posts for more details.

Rick B


"" wrote in message
...
Hi.
I've created a field in a form that calculates the age from the birthdate

of
the previous field.
But I would like it to figure in the table. All the help info only tells

you
how to do it in a form.
Can someone please tell me how to be able to do either have the table see
the age from the form or how to put the format in the table field.
Thanks
J.




  #3  
Old April 15th, 2005, 07:47 PM
Ed Warren
external usenet poster
 
Posts: n/a
Default

Don't store age in a table!!

Date of Birth is a constant
Age is variable

Use tables to store data (date of birth)
Use forms to 'see data' and enter data.

Ed Warren


"" wrote in message
...
Hi.
I've created a field in a form that calculates the age from the birthdate
of the previous field.
But I would like it to figure in the table. All the help info only tells
you how to do it in a form.
Can someone please tell me how to be able to do either have the table see
the age from the form or how to put the format in the table field.
Thanks
J.




  #4  
Old April 15th, 2005, 08:23 PM
:\(
external usenet poster
 
Posts: n/a
Default

ok ok Gotcha. Thanks.
I only wanted it there coz I am trying to set up a mail merge into word for
a letter that will give the age of the person at the time of writing the
letter.
As far as I get it, you can only mail merge from tables and not forms.
But that's another story. I promise to search more thoroughly before I ask
about that one!!
Thanks again.


"Ed Warren" wrote in message
...
Don't store age in a table!!

Date of Birth is a constant
Age is variable

Use tables to store data (date of birth)
Use forms to 'see data' and enter data.

Ed Warren


"" wrote in message
...
Hi.
I've created a field in a form that calculates the age from the birthdate
of the previous field.
But I would like it to figure in the table. All the help info only tells
you how to do it in a form.
Can someone please tell me how to be able to do either have the table see
the age from the form or how to put the format in the table field.
Thanks
J.






  #5  
Old April 15th, 2005, 08:30 PM
Rick B
external usenet poster
 
Posts: n/a
Default

I would guess you can mail merge from a query.



"" wrote in message
...
ok ok Gotcha. Thanks.
I only wanted it there coz I am trying to set up a mail merge into word

for
a letter that will give the age of the person at the time of writing the
letter.
As far as I get it, you can only mail merge from tables and not forms.
But that's another story. I promise to search more thoroughly before I ask
about that one!!
Thanks again.


"Ed Warren" wrote in message
...
Don't store age in a table!!

Date of Birth is a constant
Age is variable

Use tables to store data (date of birth)
Use forms to 'see data' and enter data.

Ed Warren


"" wrote in message
...
Hi.
I've created a field in a form that calculates the age from the

birthdate
of the previous field.
But I would like it to figure in the table. All the help info only

tells
you how to do it in a form.
Can someone please tell me how to be able to do either have the table

see
the age from the form or how to put the format in the table field.
Thanks
J.








  #6  
Old April 15th, 2005, 08:35 PM
Ed Warren
external usenet poster
 
Posts: n/a
Default

AaHaa! (the my lightbulb glimmers)

What you want to do is base your mail-merge on a query. Use date of birth
to calcuate the age in the query (based on date of birth and sendingdate)
and you have just what you want. You will want to function in a module

CalcAge(passedDateOfBirth as Date/time, passedDateOfMailing as date) as
integer

Then in the query you will enter in one of the columns:

Age:CalcAge([dateOfBirth],[DateOfMailing])

Ed Warren
-
"" wrote in message
...
ok ok Gotcha. Thanks.
I only wanted it there coz I am trying to set up a mail merge into word
for a letter that will give the age of the person at the time of writing
the letter.
As far as I get it, you can only mail merge from tables and not forms.
But that's another story. I promise to search more thoroughly before I ask
about that one!!
Thanks again.


"Ed Warren" wrote in message
...
Don't store age in a table!!

Date of Birth is a constant
Age is variable

Use tables to store data (date of birth)
Use forms to 'see data' and enter data.

Ed Warren


"" wrote in message
...
Hi.
I've created a field in a form that calculates the age from the
birthdate of the previous field.
But I would like it to figure in the table. All the help info only tells
you how to do it in a form.
Can someone please tell me how to be able to do either have the table
see the age from the form or how to put the format in the table field.
Thanks
J.








  #7  
Old April 15th, 2005, 08:50 PM
Rick B
external usenet poster
 
Posts: n/a
Default

Personally, I would not make it that complex. I would just add a new column
to my query with...


Age:
DateDiff("yyyy",[Birthdate],Date())+(Format([Birthdate],"mmdd")Format(Date(
),"mmdd"))







"Ed Warren" wrote in message
...
AaHaa! (the my lightbulb glimmers)

What you want to do is base your mail-merge on a query. Use date of birth
to calcuate the age in the query (based on date of birth and sendingdate)
and you have just what you want. You will want to function in a module

CalcAge(passedDateOfBirth as Date/time, passedDateOfMailing as date) as
integer

Then in the query you will enter in one of the columns:

Age:CalcAge([dateOfBirth],[DateOfMailing])

Ed Warren
-
"" wrote in message
...
ok ok Gotcha. Thanks.
I only wanted it there coz I am trying to set up a mail merge into word
for a letter that will give the age of the person at the time of writing
the letter.
As far as I get it, you can only mail merge from tables and not forms.
But that's another story. I promise to search more thoroughly before I

ask
about that one!!
Thanks again.


"Ed Warren" wrote in message
...
Don't store age in a table!!

Date of Birth is a constant
Age is variable

Use tables to store data (date of birth)
Use forms to 'see data' and enter data.

Ed Warren


"" wrote in message
...
Hi.
I've created a field in a form that calculates the age from the
birthdate of the previous field.
But I would like it to figure in the table. All the help info only

tells
you how to do it in a form.
Can someone please tell me how to be able to do either have the table
see the age from the form or how to put the format in the table field.
Thanks
J.










  #8  
Old April 15th, 2005, 10:20 PM
:\(
external usenet poster
 
Posts: n/a
Default

Ok I'll experiment.
Thanks for all your help



"Rick B" Anonymous wrote in message
...
Personally, I would not make it that complex. I would just add a new
column
to my query with...


Age:
DateDiff("yyyy",[Birthdate],Date())+(Format([Birthdate],"mmdd")Format(Date(
),"mmdd"))







"Ed Warren" wrote in message
...
AaHaa! (the my lightbulb glimmers)

What you want to do is base your mail-merge on a query. Use date of
birth
to calcuate the age in the query (based on date of birth and sendingdate)
and you have just what you want. You will want to function in a module

CalcAge(passedDateOfBirth as Date/time, passedDateOfMailing as date) as
integer

Then in the query you will enter in one of the columns:

Age:CalcAge([dateOfBirth],[DateOfMailing])

Ed Warren
-
"" wrote in message
...
ok ok Gotcha. Thanks.
I only wanted it there coz I am trying to set up a mail merge into word
for a letter that will give the age of the person at the time of
writing
the letter.
As far as I get it, you can only mail merge from tables and not forms.
But that's another story. I promise to search more thoroughly before I

ask
about that one!!
Thanks again.


"Ed Warren" wrote in message
...
Don't store age in a table!!

Date of Birth is a constant
Age is variable

Use tables to store data (date of birth)
Use forms to 'see data' and enter data.

Ed Warren


"" wrote in message
...
Hi.
I've created a field in a form that calculates the age from the
birthdate of the previous field.
But I would like it to figure in the table. All the help info only

tells
you how to do it in a form.
Can someone please tell me how to be able to do either have the table
see the age from the form or how to put the format in the table
field.
Thanks
J.












  #9  
Old April 17th, 2005, 02:14 PM
Bruce
external usenet poster
 
Posts: n/a
Default

I had to do this in Excel then reimported the Table into Access.

Bruce
"" wrote in message
...
Hi.
I've created a field in a form that calculates the age from the birthdate

of
the previous field.
But I would like it to figure in the table. All the help info only tells

you
how to do it in a form.
Can someone please tell me how to be able to do either have the table see
the age from the form or how to put the format in the table field.
Thanks
J.




 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Seeking some expert advice. HD87glide Using Forms 14 March 23rd, 2005 10:11 PM
Design help, please SillySally Using Forms 27 March 6th, 2005 04:11 AM
Duplicate data Rob Green Database Design 3 November 7th, 2004 03:08 AM
Access & OleDb - generating schema changes, problem with identity/counter fields. Thomas Tomiczek [MVP] Database Design 9 November 5th, 2004 10:32 AM
COMPARE THE TWO TABLES Stefanie General Discussion 0 June 4th, 2004 04:36 PM


All times are GMT +1. The time now is 07:21 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.