As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only.
Join the TIBCO Community TIBCO Community is a collaborative space for users to share knowledge and support one another in making the best use of TIBCO products and services. There are several TIBCO WebFOCUS resources in the community.
From the Home page, select Predict: WebFOCUS to view articles, questions, and trending articles.
Select Products from the top navigation bar, scroll, and then select the TIBCO WebFOCUS product page to view product overview, articles, and discussions.
Request access to the private WebFOCUS User Group (login required) to network with fellow members.
Former myibi community members should have received an email on 8/3/22 to activate their user accounts to join the community. Check your Spam folder for the email. Please get in touch with us at community@tibco.com for further assistance. Reference the community FAQ to learn more about the community.
Example : QTYREM = 20 I have to take the 20 items and divide the qtyrem by 7wk. Please see the example below qtyrem=20 ,I have to place 2 items each week and 7th week it should show remaining. Please let me know if you need more details.
Erm, is that "quantity remaining" as a weekly inventory recap for 7 weeks descending? So if the top right column B is "Quantity Remaining"... errrm... so what happens in Column C-I then? I can't figure out what is happening there except the sum is on column B but what do the dates in X and Y axis correlate with? So if 6/4/2017 we have 20 and 6/4/2017 also 2 happens? If thats sales, then how do you get to 16?
Clear as mud, that.
So, once the logic of what the numbers represent is clear, then the question is what does the database contain and is there any sales or inventory aggregates. Or is that just an "I want" and no idea of what is in the database.
Then we get into how do we calculate the "week" and what does it correlate to and how often the numbers change and what do you do when the year changes and such small details.
Cheers, H. WebFOCUS 8.1.05M Oracle 11g - DB2 RedHat
Posts: 115 | Location: Brighton UK | Registered: February 19, 2005
OK, so in that original table do the rows correlate with each other or not?
Or is the number given there in the first column just a number given and then you have to spread the "usage" as in how long will it stretch? Then by the example given the 2nd row makes no sense, as by the logic given it would be 6/11/2017 16 2 2 2 2 2 2 4
Cheers, H. WebFOCUS 8.1.05M Oracle 11g - DB2 RedHat
Posts: 115 | Location: Brighton UK | Registered: February 19, 2005
And here a way to assign Qty per week. But keep in mind that it's based on assumption that it's evenly distributed against the 7 weeks and where the latest week has the remaining qty added to its week value:
DEFINE FILE CAR
NBWK /P2 = 7;
QTY /P2 = 5;
QTYPERWK /P2 = INT(QTY / NBWK);
QTY7WK /P2 = QTYPERWK * NBWK;
QTYREM /P2 = DMOD(QTY, NBWK, QTYREM);
QTY1 /P2 = IF QTY LE 7 AND QTY GE 1 THEN 1 ELSE QTYPERWK;
QTY2 /P2 = IF QTY LE 7 AND QTY GE 2 THEN 1 ELSE QTYPERWK;
QTY3 /P2 = IF QTY LE 7 AND QTY GE 3 THEN 1 ELSE QTYPERWK;
QTY4 /P2 = IF QTY LE 7 AND QTY GE 4 THEN 1 ELSE QTYPERWK;
QTY5 /P2 = IF QTY LE 7 AND QTY GE 5 THEN 1 ELSE QTYPERWK;
QTY6 /P2 = IF QTY LE 7 AND QTY GE 6 THEN 1 ELSE QTYPERWK;
QTY7 /P2 = IF QTY EQ 7 THEN 1 ELSE (IF QTYPERWK GT 0 THEN QTYPERWK + QTYREM ELSE 0);
END
TABLE FILE CAR
PRINT QTY AS 'Starting Qty'
QTYPERWK AS 'Qty Per Week'
QTY7WK AS 'Qty After,7 weeks'
QTYREM AS 'Remaining Qty,After 7 weeks'
QTY1 AS 'Qty Wk 1'
QTY2 AS 'Qty Wk 2'
QTY3 AS 'Qty Wk 3'
QTY4 AS 'Qty Wk 4'
QTY5 AS 'Qty Wk 5'
QTY6 AS 'Qty Wk 6'
QTY7 AS 'Qty Wk 7'
BY COUNTRY NOPRINT
WHERE READLIMIT EQ 1;
WHERE RECORDLIMIT EQ 1;
END
This message has been edited. Last edited by: MartinY,
WF versions : Prod 8.2.04M gen 33, Dev 8.2.04M gen 33, OS : Windows, DB : MSSQL, Outputs : HTML, Excel, PDF In Focus since 2007
Posts: 2409 | Location: Montreal Area, Qc, CA | Registered: September 25, 2013