CIM Load PO "~" not working correctly?

irfanj

New Member
I'm new to QAD (and this forum). Just thought I'd get that out of the way. I'm currently developing in QAD EE Cloud 2017, and have copied an old program we used to use to CIM load data from a file. As per every other post about CIM loads on this forum, the code is fairly simple (I post it here in case something is wrong):
Code:
{us/bbi/mfdeclre.i}
batchrun = yes.
input from value(vcim-input).
output to  value(vcim-output) unbuffered.
run value(vcim-process).
output close.
input close.

I'm trying to cim load a PO using the above code (executed via terminal, vcim-process is popomt.p) and the first few lines of the input are below (PO, Supplier, Ship-To, Order-Date, Due-Date, Buyer and Bill To):
Code:
"04-65543"
"LONMEC"
"04"
"03/26/19" ~
"04/05/19" ~
"CANDICE" ~
"CORP" ~

The first 3 lines (which do not end in ~) work fine. Line 4-5 causes the following error (... added by me to remove unnecessary lines):
Code:
   Order Date: 03/26/19  Price Tbl:            Confirming:       Imp/Exp:
     Due Date: ~          Disc Tbl:              Currency:     Language:
...
** Invalid date input. (85)
** us/po/popomtb.p: Unable to evaluate field for assignment. (143)

Am I doing something wrong with the input file format?
 
"03/26/19" ~
"04/05/19" ~
"CANDICE" ~
Be sure the ~ is the last character from each line, Im pretty sure you have an extra space or other hide character.
Another suggestion, never use "run " for external programs; always use "gprun.i"
 

irfanj

New Member
Thanks for the reply. I wrote some code to check the file and this is what I'm getting:
Code:
INPUT FROM VALUE(cFileIn).

REPEAT:
IMPORT UNFORMATTED cLine.
MESSAGE cLine SKIP SUBSTRING(cLine, LENGTH(cLine), 1) VIEW-AS ALERT-BOX.
END.

The last character for the date and others is showing up as ~, as expected.
2001
 
Top