473,405 Members | 2,279 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,405 software developers and data experts.

A loop on recordset.field value

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, 79 views)
Dec 10 '19 #1
2 1289
twinnyfo
3,653 Expert Mod 2GB
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
Mous
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

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

Similar topics

4
by: GavMc | last post by:
Hello I am new to internet programming and wonder if anyone can help me with this.... I am trying to pass a hidden field value on a form into another field on the form so that it can then be...
6
by: Mike | last post by:
In VB I have a recordset and want to work with specific fields. I realize I can use an index number e.g. rst(23)but I don't like using index numbers in case I change the underlying fields or...
1
by: J | last post by:
Situation - Using the table pubs.titleauthor in a strongly typed dataset, attached to a datagrid, using the datagrid I would like to set the royaltyper field = null (the database allows nulls in...
1
by: George Addison | last post by:
I'm able to query an Access database on my server (remote), and I can even successfully get the number of records returned in my recordset. BUT when I try to access a field value, I get an error...
2
by: xenophon | last post by:
I added a Hidden Form Field to a form in the code behind. The value is being set in JavaScript client-side, but it is not persisting to the server in the PostBack. I know the value is being set...
5
by: Stuart | last post by:
Hi all, Iv'e got a page that has a mass amount of input fields, all of which require a decimal figure. To make it easier when it comes to inputting data, I'm trying to setup + and - links that...
6
by: KDCinfo | last post by:
Although I'm making an ajax call, this is really a javascript question (although it could be even more of an HTML or DOM question... not exactly sure) I'm doing an ajax call to a remote php...
2
by: Brave | last post by:
I'm hoping someone can help me with a small issue. I have an asp page that displays informaton from an Access database. I want to create a form that allows users to display only data that...
4
by: narutodc | last post by:
Hi, I'm working on an ASP Jscript page run on IIS 5. However i got a very strange problem: The code is like this var rs = getPaymentDetail(pId);//Get the ADODB record set this.paymentId =...
3
by: Indrajit Chakraborty | last post by:
I am developing a simple web site in ASP. I have a web page which has a form, and I want to set the values of two text box to 2 fields selected by a query. One of the fields is a name field which has...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.