Add 12 records at one time?

krolgat

New member
Local time
Today, 11:22
Joined
Sep 2, 2008
Messages
4
First i hope i could express myself correctly because english is not my native language but i'll have to try to get my problem solved.

i'm working with a database to manage the budget, i have a table with five columns with fields like [date_of_movement] [month] [amount] [ref_1] [ref_2].

My problem is that when i create a form based on that table i dont want to type or to select (combo box) the month, i want a command button or a macro that generates 12 new records with the name of the months in it and that i just type the amount and the other fields needed. I don't know if this can be done in an easy way because i'm not an access expert but i'll apreciate any ideas.


Thanks for the help
 
You can easily extract the MONTH from any date so the field seems like it is not needed. What dates will you be using?
 
i know it looks like i'm duplicating information in a row by having [date] and [month] field but they refer to different things. i need to have the track for the changes i make to the budget, so if i make a change for the next six months my [date for movement] will be today but the [month] will be october, november...etc. so i can't extract the month from the field [date].

Any idea?
 
So the [date for movement] will be the same in all six records or will it reflect the date you make a change? Sorry but I'm a little dense at understanding what you need.
 
Yes, you're right, the date of the movement will also be the same for the six records. Actually, [ref_1] and [ref_2] are also the same, it will look something like this.

[month][date of movement][amount][ref_1][ref_2]
jan 09/02/2008 100 sufl om
feb 09/02/2008 -50 sufl om
march 09/02/2008 200 sufl om
apr 09/02/2008 300 sufl om
june 09/02/2008 600 sufl om
july 09/02/2008 50 sufl om
august 09/02/2008 80 sufl om
sept 09/02/2008 90 sufl om
oct 09/02/2008 -40 sufl om
nov 09/02/2008 600 sufl om
dec 09/02/2008 75 sufl om

Then i'll have another 12 records with different date and different references [ref_1] [ref_2] but with changes in the amount for all the months, that's the reason why i'm trying to add the 12 records at the same time.

i've tried with a subform but the problem is the same because i have to either type the month or select it from a combo box, i just want to make it easier.

Thanks for the help
 
Last edited:
You actually only have 5 fields for the record. Your table definition should be:
Month Short Integer
Year Short Integer
Ref1 Text
Ref2 Text
AmountArray Currency (occurs 12 times)

The Literal months can be labels on a form and headings on a report.

This should not be 12 records in my opinion. Any specific reason why you want 12 records?
 
How many budget items will have sets of 12 records?
 
i don´t know if i get your question right but if you mean how many changes i can make to the budget there's no limit, so i have no limit to the [date of movement] field and no limit for the sets of 12 records.

And the other thing is that the table will be too big because the fields [ref_1] [ref_2] refers to different units or areas of the company, so i need the track of each one and they are about 40.

Thanks for all your posts
 
Are you planning to display all 12 records in a SubForm? What will be the LinkChild/MasterFields for the SubForm?
 

Users who are viewing this thread

Back
Top Bottom