× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Hi,

They are like below :-


On display file screen (a subfile)


Enter item number :- .................


Once we enter item number then program need to look for this item number in
a item master file and if it successfully finds an item in it then it
further checks corresponding boxes ( for each item there might be multiple
such boxes in box id field of this same item master file) and for each
such box there is corresponding 'quantity' field is there in same item
master file so we need to add all such quantities for all the individual
boxes and then finally sum it up and show on display file screen.

Just for more clarification:-

Box no. Quantity
Box 1 5
Box 2 7
Box 3 15

Then just for example if all the above 3 boxes are there for item number
'xyz' then
Program should be able to read this item master file for a specfic item
number which is entered on display file(which is a subfile with record,
control, header and footer but does not contain column headings on display
screen for these boxes but such multiple boxes are present in this item
master file for each such item number )

And then program should add quantities for all these boxes and on the
display file(subfile) it should be able to display like :- "Tot
Quantities: 27 Sum"





Thanks a lot.. ..










On Sun, Sep 10, 2023, 00:00 Glenn Gundermann <glenn.gundermann@xxxxxxxxx>
wrote:

Sorry, my previous reply was incorrect. No need for GROUP BY.Is each box a
separate row in the item master table or is each box and quantity a
separate column in the same row? If the former:exec sqlSELECT
sum(quantity) INTO :totalQtyFROM item_master WHERE item_number =
:itemNo;Your display file will define the field TOTALQTY.Yours truly,Glenn
Gundermannglenn.gundermann@xxxxxxxxx(416) 317-3144
--
This is the RPG programming on IBM i (RPG400-L) mailing list
To post a message email: RPG400-L@xxxxxxxxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives
at https://archive.midrange.com/rpg400-l.

Please contact support@xxxxxxxxxxxxxxxxxxxx for any subscription related
questions.



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.