Hi, everyone. I am trying to find and replace blank instances of a date field with the date I want it to read. I know absolutely nothing about programming in Progress, so I'm just attempting to edit a procedure of someone elses. This is what I've ended up with:
DEF VAR a AS INT LABEL "records read" NO-UNDO.
DEF VAR b AS INT LABEL "records updated" NO-UNDO.
DEF VAR c AS INT.
MESSAGE "Processing PDSC...".
mainloop:
FOR EACH pdsc WHERE
pdsc.cono = 1 AND
pdsc.levelcd = 7.
IF NOT pdsc.refer BEGINS "Industry" THEN NEXT mainloop.
a = a + 1.
IF pdsc.startdt IS NULL THEN
ASSIGN
pdsc.startdt = "23/09/2011"
b = b + 1.
END.
DISP a b WITH FRAME aa SIDE-LABELS.
I appreciate there's some unnecessary baggage in there, but my current problem seems to be on the IF pdsc.startdt IS NULL THEN line. I get the following error message:
** Unable to understand after -- "pdsc.startdt". (247)
** Could not understand line 12. (198)
I've tried a number if variants, pdsc.startdt = "", LENGTH(pdsc.startdt) = 0 etc, but all with the same results. Can anyone please help me with the correct syntax for this?
DEF VAR a AS INT LABEL "records read" NO-UNDO.
DEF VAR b AS INT LABEL "records updated" NO-UNDO.
DEF VAR c AS INT.
MESSAGE "Processing PDSC...".
mainloop:
FOR EACH pdsc WHERE
pdsc.cono = 1 AND
pdsc.levelcd = 7.
IF NOT pdsc.refer BEGINS "Industry" THEN NEXT mainloop.
a = a + 1.
IF pdsc.startdt IS NULL THEN
ASSIGN
pdsc.startdt = "23/09/2011"
b = b + 1.
END.
DISP a b WITH FRAME aa SIDE-LABELS.
I appreciate there's some unnecessary baggage in there, but my current problem seems to be on the IF pdsc.startdt IS NULL THEN line. I get the following error message:
** Unable to understand after -- "pdsc.startdt". (247)
** Could not understand line 12. (198)
I've tried a number if variants, pdsc.startdt = "", LENGTH(pdsc.startdt) = 0 etc, but all with the same results. Can anyone please help me with the correct syntax for this?