And this company is not going to be an ongoing customer (at least not one on plan) so I don't want to create a headache of me having to fix extra VI imports may fail for unexpected reasons.
Original Message:
Sent: 12-09-2024 17:58
From: Kevin Moyes
Subject: Ways to track that a record has been exported from Sage 100
With that strategy I always set them up to run after midnight, with DateUpdated = YESTERDAY (as a VC command line date parameter). If you need to run a back-dated batch, the report date parameter makes that easy.

You are correct in that VI imports for status flags is a point of failure in such a process. We spent years supporting those issues before developing other strategies.
------------------------------
Kevin Moyes
Technical Systems Analyst
Munjal White Consulting Co.
Toronto ON
------------------------------
Original Message:
Sent: 12-09-2024 17:51
From: Wayne Schulz
Subject: Ways to track that a record has been exported from Sage 100
I might pivot to working with the Date Updated as opposed to the invoice date. They would not be updating to history. They say that they are ok with running this once daily after-hours. What I may pitch is just to run this late enough in the day (10 pm to 11 pm ) that nobody would be in Sage posting any invoices. I'd like to keep it as un-complex as possible because in the midst of the project they are already undergoing layoffs.
One of my fears is that trying to write back into AR Invoice History Header could result in file lock issues should a user leave for the day and leave their data entry screen open ( I'm not certain if any of this would cause file locking but if I can avoid that possibility it seems like a good tradeoff)
------------------------------
Wayne Schulz
wayne@s-consult.com
Schulz Consulting
(860) 516-8990
CT
Original Message:
Sent: 12-09-2024 17:38
From: Kevin Moyes
Subject: Ways to track that a record has been exported from Sage 100
If duplicates are not a disaster, you can export based on DateUpdated... but don't do this if they import to invoice history (eg. import updates to posted invoice data), which changes that value. A skipped schedule (server maintenance / power outage) requires a back-dated batch... so this is not a 100% hands-free option, but it usually works quite nicely.
A reporting solution that maintains a mirror table of what has been sent (Sage Alerts / KS / ActionQ) is a great idea. Everything works off of ODBC, with no complications related to updating a "sent" flag.
Otherwise, you need to set up a way of tracking what has been sent... and I have done this kind of process dozens of times. The most reliable method is to store your status values outside of the normal Sage tables. Something like a UDT to hold InvoiceNo + HeaderSeqNo value as the key field, with a "status" column. Script adds new UDT rows with a "Processing" status, run your report for the currently selected rows, then run a second script to change "Processing" to "Sent/Done"... with a date/time if you want.
------------------------------
Kevin Moyes
Technical Systems Analyst
Munjal White Consulting Co.
Toronto ON