Unconfigured Ad Widget

Collapse

Announcement

Collapse
No announcement yet.

How to identify field holding invalid decimal data

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • How to identify field holding invalid decimal data

    If the invalid data is in the input files at a command line enter: STRDBG STRSQL SELECT * FROM LIB/INFILE Exit SQL and look at your joblog. It will tell you the record(s) number and field(s) name conataining invalid data. This works on V5R3, don't know about previous versions. However if the invalid data is in a program variable and you cannot trace the data back to a file I don't think there's much you can do if you don't have the source code or a listing of it. Good luck

  • #2
    How to identify field holding invalid decimal data

    In the listing for the compiled program, take a look at the last executed statement. If it is in the "C" specs go back to the dump and take a look at the fields being used. You should be able to get a better indication. If the statement does not appear in the program, it may be in the *INIT or *READ routines. You should still be able to determine the bad field. Dave

    Comment


    • #3
      How to identify field holding invalid decimal data

      Hi fellas, thanks for the replies. Again, the problem I have is that I don't definately have the correct object source. I'll experiment with what you suggest and get back with my findings Thanks again

      Comment


      • #4
        How to identify field holding invalid decimal data

        When I have decimal data errors, there are usually two places I look. The first is the input files. Use another program to check all the numeric fields. I have ended up writing 'fix' programs for most of my main files that z-add all numeric fields to itself. This way I can keep things running and work on tracking down the problem without interrupting production. The second place to look in input parameters (or the LDA if you still have some 36 era code, which I do). Often I find a parameter in a CL progam is not set correctly and I pass blanks. Have you tried STRISDB and step through the program a line at a time? This will show you exactly what is happening. I've never had to work without source code, so I don't know how well any of these suggestions will work. Good luck. ---Dale

        Comment


        • #5
          How to identify field holding invalid decimal data

          A program that is no longer supported by its authors is returning decimal data errors. They compiled the object without the debugging tables, so I cannot debug the pgm the reason for the problem. Is there any other way to identify the effected field? I do have access to source for the object but I'm not confident that it is the same version. I have obtained a last statement number from the RPG formatted dump, and also checked out the System formated dump but neither names the culprit. Thanks for any help

          Comment


          • #6
            How to identify field holding invalid decimal data

            I would use QUERY on the file and only select the fields that have numeric fields. The job log for the query will tell you what the first field on your list has invalid data. This way you do not have to look at character fields.

            Comment

            Working...
            X