Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Automatic Number in Table?

Status
Not open for further replies.

mfleming

Technical User
Jul 2, 2003
65
CA
Hello.

I have a databese setup for all my address, Wedding RSVP's ect.

Table Info:
Yes/No for "RSVPResponded" in "Address.Table"
Number for "RSVPInvited" in "Address.Table"
Number for "RSVPAttending" in "Address.Table"


Questions:

1. I want to add "RSVPNotAttending to "Address.Table by using a auto number generated if "RSVPResponed" = "True" And "RSVPInvited" <> "RSVPAttending" = "RSVPNotAttending".

2. Is there any way to do this in the "Address.Table"? ie. If RSVPResponed = True then RSVPInvited-RSVPAttending = "RSVPNotAttening" table value?

3. I have a Report setup that uses the values in "Address.Table" to have a Running SUm of # Invited, # Responed and I want to add # Not Attending, is this possible from the table or do I have to create a query?


Thanks

Matt
 
Why on earth would you want an AutoNumber stored in a field IF some criteria is valid ?

An AutoNumber field will ( as the name suggests ) AUTOMATICALLY populate the field when you add a record ( every record )


As for the report,
If you have a running sum of Invited, Responded and Attending then the Not Attending is a simple calculated value - you calculate it on the report . It does not need to ( and should not ) go anywhere near the table.



'ope-that-'elps.



G LS
spsinkNOJUNK@yahoo.co.uk
Remove the NOJUNK to use.
 
It sounds like you used the term autonumber incorrectly. An autonumber field that sequentially numbers a new record in a table. The first record is 1, the second is 2. If you delete 2 the next record is 3. It is unique.
You meant you wanted a value automatically calculated. That is something different. It is referred to as a "calculated field". You can not do a calculated field in a table however this is easily done in a query. So build a query based on your table and add the field "calcRSVPNotAttending". Go to the Access Help and type in
"calculated fields, queries"
There is a good example on how to do this. Now build a report or form based on your query.

Good luck
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top