Troubles Transfering Items with Serial Numbers

Hi! I have a problem, when i want to post the shipment of a Transfer Order that contains Items with Serial numbers. Attain 3.60 wants to create a “Tracking Specification” with an already existing “Entry No.”. (The already existing Entry No. is created during the Shipment.) All Happens in the Function SaveTempWhseSplitSpec of Codeunit 5704. The strange thing is: When I try to ship one Line at time, everything goes right. Who knows what can be the problem here? thx to all who read this and try to understand me. Touny

The service request system contans dozens of issues on transfer orders with item tracking in 360. However for your issue there exists a “fix”. Check out service request NZ-460-301-JVDQ.

Hi Nav nav! Where can i find service request NZ-460-301-JVDQ? Thx!

Don’t you know Service-System? Anyway, here is the solution… This has been a known issue and has been corrected in 3.70, below you can find the fix for 3.60. There are a number of service request that relate to this issue, I have also listed those below or you can just do a search on “tracking specification”, which will also give you a number of requests that are related to the issue. Lotus entries: DE-598-427-ZEB9 BE-524-23-HEHY Regards Patrick Shortt Codeunit 5704 TransferOrder-Post Shipment 3.60: Attention: The following code is an extract from 3.70, modified for 3.60. It hasn’t been completely tested in 3.60! It should fix this issue and DE-468-938-3LZ2. … BEGIN TempWhseSplitSpecification.RESET; // add line TempWhseSplitSpecification.DELETEALL; // add line IF Status = Status::Open THEN BEGIN CODEUNIT.RUN(CODEUNIT::“Release Transfer Document”,Rec); … ReserveTransLine.TransferTransferToTransfer(TransLine, TransLine2,TransLine.“Qty. to Ship (Base)”,1); SaveTempWhseSplitSpec; // delete line TransferItemTracking(TransLine2); … LOCAL PROCEDURE InsertShptEntryRelation@38(VAR TransShptLine@1002 : Record 5745) : Integer; VAR ItemEntryRelation@1001 : Record 6507; ItemTrackingMgt@1004 : Codeunit 6500; // add line WhseSNRequired@1003 : Boolean; // add line WhseLNRequired@1000 : Boolean; // add line BEGIN TempHandlingSpecification.RESET; IF ItemJnlPostLine.CollectTrackingSpecification(TempHandlingSpecification) THEN BEGIN TempHandlingSpecification.SETRANGE(“Buffer Status”,0); IF TempHandlingSpecification.FIND(’-’) THEN BEGIN REPEAT IF WhseReference <> 0 THEN BEGIN // add line ItemTrackingMgt.CheckWhseItemTrkgSetup( // add line TransShptLine.“Item No.”,WhseSNRequired,WhseLNRequired,FALSE); // add line IF WhseSNRequired OR WhseLNRequired THEN BEGIN // add line TempWhseSplitSpecification := TempHandlingSpecification; // add line TempWhseSplitSpecification.“Source Type” := DATABASE::“Transfer Line”; // add line TempWhseSplitSpecification.“Source ID” := TransShptLine.“Transfer Order No.”; // add line TempWhseSplitSpecification.“Source Ref. No.” := TransShptLine.“Line No.”; // add line TempWhseSplitSpecification.INSERT; // add line END; // add line END; // add line ItemEntryRelation.INIT; … LOCAL PROCEDURE SaveTempWhseSplitSpec@26(); // can be delete entirely 04-11-2002/BGA Problem description: Transfer Orders with several lines containing item tracking could not been shipped, because the temporary Item Tracking lines belonging to the parent transfer lines were not filtered out in the Code 5704, SaveTempWhseSplitSpec procedure. Correction made: Codeunit 5704 TransferOrder-Post Shipment LOCAL PROCEDURE SaveTempWhseSplitSpec Old code: TempHandlingSpecification.RESET; IF TempHandlingSpecification.FIND(’-’) THEN New code: TempHandlingSpecification.RESET; TempHandlingSpecification.SETRANGE(“Buffer Status”,0); IF TempHandlingSpecification.FIND(’-’) THEN-

Thank You very much, Patrick Shortt!

I’ve found another issue: In the Codeunit TransferOrder - Post Shipment we have a function InsertItemEntryRelation. This one makes as one of the first lines the following call: IF ItemJnlPostLine.CollectTrackingSpecification(TempHandlingSpecification) THEN … This function loads the tracking specification specified in the transfer order into TempHandlingSpecification which is used for posting. Now if you have two lines of items with serial nos. you get an error. I think i know why: The variable TempHandlingSpecification filled by CollectTrackingSpecification is a global temporary variable. The first time he loads the specification, everything is ok. But on the second line, he tries to reload the specification of the second line into the already filled TempHandlingSpecification, because the variable is global and still has the specification for the last line stored and therefore you get “… already exists.” error. I took a look into Cronus 3.70 and saw that the temporary tracking specification used for retrieving THERE is local and called TempHandlingSpecification2. I’ve exchanged every call to CollectTrackingSpecification with CollectTrackingSpecification2 except for the following bit: TempHandlingSpecification.“Source Prod. Order Line” := TransShptLine.“Line No.”; TempHandlingSpecification.“Buffer Status” := TempHandlingSpecification.“Buffer Status”::MODIFY; TempHandlingSpecification.MODIFY; Further, i guess the posting routines take the wrong entry number for the Item Entry Relation. I always ended up getting an error message about already existing entries, so i made the following change: ItemEntryRelation.INIT; ItemEntryRelation.“Item Entry No.” := TempHandlingSpecification2.“Appl.-to Item Entry”; ItemEntryRelation.TESTFIELD(“Item Entry No.”); ItemEntryRelation.“Serial No.” := TempHandlingSpecification2.“Serial No.”; ItemEntryRelation.“Lot No.” := TempHandlingSpecification2.“Lot No.”; ItemEntryRelation.TransferFieldsTransShptLine(TransShptLine); ItemEntryRelation.INSERT; TempHandlingSpecification := TempHandlingSpecification2; TempHandlingSpecification.“Entry No.” := TempHandlingSpecification2.“Appl.-to Item Entry”; TempHandlingSpecification.“Source Prod. Order Line” := TransShptLine.“Line No.”; TempHandlingSpecification.“Buffer Status” := TempHandlingSpecification.“Buffer Status”::MODIFY; TempHandlingSpecification.INSERT; i have written the changes i made in bold. I now have a hybrid codeunit between 3.60 SP2, 3.70 and my own inventions, but my transfer order is now postable all entries made seem to be 100% correct.