-3

I am facing an issue with the below FUNCTION. I am exporting this to a .xml file and in the log file I am receiving the error "** Invalid character in numeric input /. (76)". Please help me in resolving this issue.

CLASS JITS.BE.ANDON.DataItems :

    CONSTRUCTOR PUBLIC DataItems():        
    END.

    DEFINE PUBLIC VARIABLE cValue               AS LONGCHAR NO-UNDO.

    DEFINE TEMP-TABLE AlertList NO-UNDO 
           FIELD Item AS CLASS Progress.Lang.Object.
     /* Method for storing alerts against an item instance */
    METHOD PUBLIC VOID AddAlerts(INPUT alert AS CLASS JITS.BE.ANDON.Alerts):
        CREATE AlertList.
        AlertList.Item = alert.
    END.

    /* Method to retrieve alerts against an instance */
    METHOD PUBLIC VOID GetAlerts(OUTPUT TABLE  AlertList):
    END.    

END CLASS.



FUNCTION GETLASTSEQDATETIME RETURNS CHARACTER (INPUT mYObj AS CLASS JITS.BE.ANDON.DataItems):

  ASSIGN mYObj:cValue = '99/99/9999 00:00:00'.

  FIND FIRST sfcf_au where sfcf_au.assu_id = ENTRY(2,mYObj:CPARAMETER,"|") NO-LOCK NO-ERROR.
  FIND FIRST sfcf_au_ship OF sfcf_au NO-LOCK NO-ERROR. 

  FOR LAST comh_corder_version_head NO-LOCK:
      ASSIGN 
           mYObj:cValue = STRING(comh_corder_version_head.covh_received_date) + " " + STRING(comh_corder_version_head.covh_received_time,"HH:MM:SS"). 

      LEAVE.
  END.

    RETURN ''.
END FUNCTION.
Jensd
  • 7,886
  • 2
  • 28
  • 37
  • 1
    This code sample does not seem to be related to the problem being described. To obtain a stack trace when an error occurs add the following parameters -debugalert -errorstack -clientlog myerror.debug – Tom Bascom Dec 03 '19 at 14:53
  • 1
    Try to narrow down your problem to a a few runnable lines of code that you can post here together with your input-data. Then somebody might be able to help. What you post really doesn't do anyting. – Jensd Dec 04 '19 at 10:25

1 Answers1

0

I'm struggling a little to understand your code snippet. For example, I can't see where myObj:CPARAMETER would come from, or what its value is. You are also not telling us where the error comes from, so I am having to guess and make assumptions. If you want to know where the error comes, then you need to add debug messages to the code.

But I assume it's the use of myObj:CPARAMETER that is causing the errors. And I also assume that in some way it's got a date in it. I assume assu_id is an integer value and the ABL is doing a runtime conversion of ENTRY (2,...) to INT which is failing because ENTRY is a Character value which is then being converted to an INT.

All of this is based on assumptions though.

jdpjamesp
  • 762
  • 7
  • 19