By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
443,836 Members | 2,059 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 443,836 IT Pros & Developers. It's quick & easy.

A loop on recordset.field value

P: 2
hi everybody,
I'm a VBA beginner and I need Please your help to create loop that will generate a date for each operation order based on a forecast by month.

In one hand I've forecast table

Site Operation_ID Month Quantity

And in second hand detail table

City Operation_ID Operation_Order Year date

the final result is a date for each operation order based on the forecast

I put on attachement a example of the expected result
Attached Files
File Type: xlsx Result_Example.xlsx (16.4 KB, 19 views)
Dec 10 '19 #1
Share this Question
Share on Google+
2 Replies


twinnyfo
Expert Mod 2.5K+
P: 3,330
Mous,

Welcome to Bytes!

Unfortunately, I have very little idea what it is you are trying to do. I think I have an idea that for your forecast table you want the same number of records in the final table for each month?

I can only presume that you are receiving these data sets separately and somehow you have to merge them to make sense? Otherwise, my advice would be to have the date of the Operation order included in the first table.

This one is just hurting my brain right now, but I am thinking that there must be a "relatively easy" way to do this, but the only way I can think of doing it is with a bunch of domain aggregate functions to count the records upon themselves. I'm sure that's not the best way, but I'll have to think about this one for a while.
Dec 10 '19 #2

P: 2
Hi Twinnyfo and thanks for the quick response.

Youíre right ! for the forecast table you want the same number of records in the final table for each month?
Unfortunately, I canít have date in the first table.
But we can add Date field in the 2 second one without a need to create a 3rd table

Thanks
Dec 11 '19 #3

Post your reply

Sign in to post your reply or Sign up for a free account.