Unconfigured Ad Widget

Collapse

Announcement

Collapse
No announcement yet.

More old file S/36 to AS/400

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

  • More old file S/36 to AS/400

    Sometimes I am able to copy from one externally described file to another externally described file with some different field sizes (same field names) and achieve the needed results using the *MAP and *DROP options. Sometimes the problem is such that only writing a RPG conversion program will get me the needed results. Just an old mainframer caught in the Web!

  • #2
    More old file S/36 to AS/400

    I am just sort of guessing here, but maybe your 36 file has more than 1 record layout to it. You may have to try to find the record id-usually the first few characters, then do a selective cpyf on just one record layout at a time. Some of the old programs where I work had 4 record layouts in one file. After we converted the 36 file, we now have 4 files. You may need to see the I specs from an RPG program to figure out the record id's and fields in each file.

    Comment


    • #3
      More old file S/36 to AS/400

      On Saturday, October 04, 1997, 04:58 AM, Manuel Alvarez wrote: Hi Roy McCray: I have a new problem with the old files S/36 with his packed fields. When I think all is O.K. with CPYF and the parameter *NOCHK, I found it a file that the registers in the member have different length. So, for example the register number 4, 5 and 7 have these fields: length: 10. type: CHAR length: 6. type: PACKED length: 10. type:PACKED length: 6. type: PACKED length: 6. type:PACKED length: 12 type: CHAR But the register number 6 has these fields: length: 10. type: CHAR length: 6. type: PACKED length: 8. type:PACKED length: 8. type: PACKED length: 6. type:PACKED length: 12 type: CHAR So, I canīt copy the registers in a file using the query for creating a new file that I can use.I create a file with the dds for CPYF with *NOCHK, but the fields has differents lengths. How can I use in the query this file for make a new file? THANKS, FRIENDS Manuel, I'm sorry, but I don't understand what you're trying to do. If you're simply trying to create a native externally described file from an old internally described S/36 file, you shouldn't have any great problems, tho you may have to fiddle around with the DDS for the native mode file. I don't think I've tried doing this with a CPYF before - How does CPYF know what the S/36 file looks like?? Do you have to first define it in IDDU as you do when you query a S/36 file? But it's a very simple RPG 3 program to do the same thing. With an RPG program you could change field sizes or types during the conversion. By changing the program very slightly (input specs and output file, record, and field names), you could use it for many S/36 file conversions, if that's what you want to do. Where does a query come into this picture?

      Comment

      Working...
      X