Visual Integrator: records read not equal to records passed, but no records failed or were skipped

SOLVED

We are importing SO  invoice records using VI. There are 445 lines in the file.  The summary says that none of them failed or were skipped, yes the number "passed" is not equal to the number read.  

What causes this to happen?  

From looking at the summary, we can see that some lines were indeed silently skipped.

  • 0
    My guess would be duplicate lines that were ignored / not counted more than once. That's odd for an invoice import though, but if these are updates and you included line key, that could explain it.
  • 0 in reply to Kevin M

    I've verified there aren't any duplicate lines.  We are using the same ItemCode for 2 of the lines on the invoice, namely "*TIME".  As a side note, could you tell me what prependig the * to the ItemCode does? We've been using that method when it's not an actual item in inventory.

    Here's more detail info on the line that did not pass.

    The left side is the header. The middle is the first line (which was not passed & ignored). The right side is another line from the invoice that did pass and was imported. (i've blanked out some sensitive info)

  • 0 in reply to bradvido
    It shouldn't but line 326 could be updating line 325's detail record instead of adding a detail record. I've seen odd things like that before.
    (* items are special "non-inventory" items, correct).
  • 0 in reply to Kevin M
    I'm curious about the "L.LotSerialFullyDistributed"=Y parameter. Could you explain (or point me to documentation) what this flag does?
  • 0 in reply to bradvido

    More info on this. We've found that moving the line that is skipped to a different position in the import file (usually down a few lines in the invoice) will cause everything to work w/o skipping any lines. We, however, cannot determine what is causing this! Any ideas what would cause this?

    Update: This problem seems to occur when two lines that are very similar are next to each other in the import, namely the Item Code and Item Type are the same on the two lines.  I still don't understand why the line gets skipped, especially since moving it to a different position fixes the problem.

  • 0 in reply to bradvido
    L.LotSerialFullyDistributed pertains to items with the Lot or Serial valuation. (There is no documentation for things like this, outside of the help files).

    What you describe sounds exactly as I suspected. The subsequent line is updating the previous row instead of adding a new one. I don't know what to suggest other than playing with the job settings to see if you can get something to work. Something odd like L.LineKey set to column 100 (i.e. something not in your data source) might do the trick.
  • 0
    Along the lines of what Kevin M has been saying I think that without assigning a unique LineKey for each line that VI will look at the same item code/item type within an invoice as being one line in the sense that it will just keep overwriting itself and you will only end up with 1 line for that item. If you have control of how the import file is generated you could generate LineKeys within the import file. Sage's natural LineKeys look like this.

    Line 1, LineKey 1 = 000010
    Line 2, LineKey 2 = 000011
    Line 3, LineKey 3 = 000012

    So it starts it 000010 and increments by 1 from there. I haven't tested this but I would try to do a Incr Assign on LineKey within VI and set the default at 000010, hypothetically it should start at 000010 and increment by 1 from there.
  • 0 in reply to Jon_K

    Thanks for the tip! I've added the L.LineKey to the import job, set it to auto-increment starting at 10, but the job is still skipping records. What is really strange is that I don't see the L.LinkKey field at all in the "Record Detail" on the lines in the job summary. Is that normal? I made sure to save the job after adding the L.LineKey field and have tried it 3 times now.
    Regardless, it still skipped lines just as before. Is there something special that needs to be done to set the LineKey field? Also, I've only ran "Test" so far, not performed the actual import.

    Update: I've also tried editing the import file to manually add the line keys and doing a REPL on that column, but still the LineKey does not show up in the summary when I drill into the lines.  I noticed that the line key is red in the column select list for the import job maintenance, and assume that means it's a primary key. Does that means it can't be assigned manually?

  • 0 in reply to bradvido
    I've sometimes found that the linekey can only be set when updating data. When adding rows, it's ignored.
  • 0 in reply to Kevin M
    That makes sense then, because we are only inserting, not updating. We do have control over how the import file is generated, so I was thinking I could add "buffer" lines between any two lines that share the same ItemCode & ItemType. Any ideas on what would be best to add a $0 amt line? Is it possible to add a comment line or something like that?