supladaiii
New Member
- Joined
- Mar 15, 2008
- Messages
- 30
Hello. I have (2) tables. PartNo is alphanumeric.
TABLE1 data is from Vendor. This is the shipment register.
Assume that each shipment/PackList is for a single PartNo but multiple quantities.
Columns: PartNo, ShipDate, ShipQty, PO, PackList.
<tbody>
[TD="width: 68"]ShipDate[/TD]
[TD="width: 64"]ShipQty[/TD]
[TD="width: 64"]PO[/TD]
[TD="width: 64"]Packlist[/TD]
[TD="class: xl65, align: right"]01/31/19[/TD]
[TD="align: right"]4[/TD]
[TD="align: right"]90100[/TD]
[TD="align: right"]50001[/TD]
[TD="class: xl65, align: right"]01/31/19[/TD]
[TD="align: right"]3[/TD]
[TD="align: right"]90100[/TD]
[TD="align: right"]50002[/TD]
[TD="class: xl65, align: right"]02/15/19[/TD]
[TD="align: right"]2[/TD]
[TD="align: right"]90200[/TD]
[TD="align: right"]50003[/TD]
[TD="class: xl65, align: right"]02/28/19[/TD]
[TD="align: right"]5[/TD]
[TD="align: right"]90200[/TD]
[TD="align: right"]50004[/TD]
</tbody>
TABLE2 data is from Customer. This is the customer's consumption report that identifies which PartNo was pulled when.
Assume that UseQty is either 1 or 2 and MatlDoc+MatlDoc_LineNo is a unique identifier.
Columns: PartNo, PullDate, UseQty, MatlDoc, MatlDoc_LineNo, PymtDoc.
<tbody>
[TD="class: xl65, width: 64"]PullDate[/TD]
[TD="width: 64"]UseQty[/TD]
[TD="width: 64"]MatlDoc[/TD]
[TD="width: 64"]MatlDoc_LineNo[/TD]
[TD="width: 64"]PymtDoc[/TD]
[TD="class: xl66, width: 64"]PackList[/TD]
[TD="width: 64"][/TD]
[TD="class: xl65, align: right"]02/01/19[/TD]
[TD="align: right"]1[/TD]
[TD="align: right"]887654[/TD]
[TD="align: right"]1[/TD]
[TD="class: xl66, align: right"]50001[/TD]
[TD="class: xl65, align: right"]02/01/19[/TD]
[TD="align: right"]2[/TD]
[TD="align: right"]887654[/TD]
[TD="align: right"]2[/TD]
[TD="class: xl66, align: right"]50001[/TD]
[TD="class: xl65, align: right"]02/01/19[/TD]
[TD="align: right"]1[/TD]
[TD="align: right"]887654[/TD]
[TD="align: right"]3[/TD]
[TD="class: xl66, align: right"]50002[/TD]
[TD="class: xl65, align: right"]02/15/19[/TD]
[TD="align: right"]1[/TD]
[TD="align: right"]887785[/TD]
[TD="align: right"]1[/TD]
[TD="class: xl66, align: right"]50001[/TD]
[TD="class: xl65, align: right"]02/15/19[/TD]
[TD="align: right"]1[/TD]
[TD="align: right"]887785[/TD]
[TD="align: right"]2[/TD]
[TD="class: xl66, align: right"]50003[/TD]
[TD="class: xl65, align: right"]02/15/19[/TD]
[TD="align: right"]1[/TD]
[TD="align: right"]887785[/TD]
[TD="align: right"]3[/TD]
[TD="class: xl66"][/TD]
[TD="class: xl65, align: right"]02/20/19[/TD]
[TD="align: right"]1[/TD]
[TD="align: right"]889100[/TD]
[TD="align: right"]1[/TD]
[TD="class: xl66"][/TD]
[TD="class: xl65, align: right"]02/20/19[/TD]
[TD="align: right"]1[/TD]
[TD="align: right"]889100[/TD]
[TD="align: right"]2[/TD]
[TD="class: xl66"][/TD]
[TD="class: xl65, align: right"]02/28/19[/TD]
[TD="align: right"]1[/TD]
[TD="align: right"]890150[/TD]
[TD="align: right"]1[/TD]
[TD="class: xl66"][/TD]
[TD="class: xl65, align: right"]03/01/19[/TD]
[TD="align: right"]2[/TD]
[TD="align: right"]890175[/TD]
[TD="align: right"]1[/TD]
[TD="class: xl66"][/TD]
[TD="class: xl65, align: right"]03/04/19[/TD]
[TD="align: right"]2[/TD]
[TD="align: right"]890250[/TD]
[TD="align: right"]1[/TD]
[TD="class: xl66"][/TD]
</tbody>
GOAL: If info is blank then Assign/Identify PackList# for each consumption. (I have added a column [PackList] in TABLE2 for this info)
I need a MACRO that would "pull" consumption from a PackList number and assign the PackList from oldest to newest (FIFO).
{At the moment, I am currently spending way too much time doing this manually even with column helpers and conditional formatting to let me know which packlist is completely used.}
TABLE1 data is from Vendor. This is the shipment register.
Assume that each shipment/PackList is for a single PartNo but multiple quantities.
Columns: PartNo, ShipDate, ShipQty, PO, PackList.
PartNo |
12345-A |
45678-B |
12345-A |
45678-B |
<tbody>
[TD="width: 68"]ShipDate[/TD]
[TD="width: 64"]ShipQty[/TD]
[TD="width: 64"]PO[/TD]
[TD="width: 64"]Packlist[/TD]
[TD="class: xl65, align: right"]01/31/19[/TD]
[TD="align: right"]4[/TD]
[TD="align: right"]90100[/TD]
[TD="align: right"]50001[/TD]
[TD="class: xl65, align: right"]01/31/19[/TD]
[TD="align: right"]3[/TD]
[TD="align: right"]90100[/TD]
[TD="align: right"]50002[/TD]
[TD="class: xl65, align: right"]02/15/19[/TD]
[TD="align: right"]2[/TD]
[TD="align: right"]90200[/TD]
[TD="align: right"]50003[/TD]
[TD="class: xl65, align: right"]02/28/19[/TD]
[TD="align: right"]5[/TD]
[TD="align: right"]90200[/TD]
[TD="align: right"]50004[/TD]
</tbody>
TABLE2 data is from Customer. This is the customer's consumption report that identifies which PartNo was pulled when.
Assume that UseQty is either 1 or 2 and MatlDoc+MatlDoc_LineNo is a unique identifier.
Columns: PartNo, PullDate, UseQty, MatlDoc, MatlDoc_LineNo, PymtDoc.
PartNo | ||
12345-A | ||
12345-A | ||
45678-B | ||
12345-A | ||
12345-A | ||
45678-B | 50002 | |
12345-A | 50003 | |
45678-B | 50002 | |
45678-B | 50004 | |
45678-B | 50004 | |
45678-B | 50004 |
<tbody>
[TD="class: xl65, width: 64"]PullDate[/TD]
[TD="width: 64"]UseQty[/TD]
[TD="width: 64"]MatlDoc[/TD]
[TD="width: 64"]MatlDoc_LineNo[/TD]
[TD="width: 64"]PymtDoc[/TD]
[TD="class: xl66, width: 64"]PackList[/TD]
[TD="width: 64"][/TD]
[TD="class: xl65, align: right"]02/01/19[/TD]
[TD="align: right"]1[/TD]
[TD="align: right"]887654[/TD]
[TD="align: right"]1[/TD]
[TD="class: xl66, align: right"]50001[/TD]
[TD="class: xl65, align: right"]02/01/19[/TD]
[TD="align: right"]2[/TD]
[TD="align: right"]887654[/TD]
[TD="align: right"]2[/TD]
[TD="class: xl66, align: right"]50001[/TD]
[TD="class: xl65, align: right"]02/01/19[/TD]
[TD="align: right"]1[/TD]
[TD="align: right"]887654[/TD]
[TD="align: right"]3[/TD]
[TD="class: xl66, align: right"]50002[/TD]
[TD="class: xl65, align: right"]02/15/19[/TD]
[TD="align: right"]1[/TD]
[TD="align: right"]887785[/TD]
[TD="align: right"]1[/TD]
[TD="class: xl66, align: right"]50001[/TD]
[TD="class: xl65, align: right"]02/15/19[/TD]
[TD="align: right"]1[/TD]
[TD="align: right"]887785[/TD]
[TD="align: right"]2[/TD]
[TD="class: xl66, align: right"]50003[/TD]
[TD="class: xl65, align: right"]02/15/19[/TD]
[TD="align: right"]1[/TD]
[TD="align: right"]887785[/TD]
[TD="align: right"]3[/TD]
[TD="class: xl66"][/TD]
[TD="class: xl65, align: right"]02/20/19[/TD]
[TD="align: right"]1[/TD]
[TD="align: right"]889100[/TD]
[TD="align: right"]1[/TD]
[TD="class: xl66"][/TD]
[TD="class: xl65, align: right"]02/20/19[/TD]
[TD="align: right"]1[/TD]
[TD="align: right"]889100[/TD]
[TD="align: right"]2[/TD]
[TD="class: xl66"][/TD]
[TD="class: xl65, align: right"]02/28/19[/TD]
[TD="align: right"]1[/TD]
[TD="align: right"]890150[/TD]
[TD="align: right"]1[/TD]
[TD="class: xl66"][/TD]
[TD="class: xl65, align: right"]03/01/19[/TD]
[TD="align: right"]2[/TD]
[TD="align: right"]890175[/TD]
[TD="align: right"]1[/TD]
[TD="class: xl66"][/TD]
[TD="class: xl65, align: right"]03/04/19[/TD]
[TD="align: right"]2[/TD]
[TD="align: right"]890250[/TD]
[TD="align: right"]1[/TD]
[TD="class: xl66"][/TD]
</tbody>
GOAL: If info is blank then Assign/Identify PackList# for each consumption. (I have added a column [PackList] in TABLE2 for this info)
I need a MACRO that would "pull" consumption from a PackList number and assign the PackList from oldest to newest (FIFO).
{At the moment, I am currently spending way too much time doing this manually even with column helpers and conditional formatting to let me know which packlist is completely used.}