Setting line length for mainframe files

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • misi01
    Old Hand
    • Jun 2005
    • 210

    Setting line length for mainframe files

    Assume the following when comparing PC files with the mainframe:-

    - the folder comparison ALWAYS specifies the PC folder on the left-hand side
    - ditto, the MF PDS is always on the right-hand side
    - the files that need to be compared on the PC all have a filetype of .CBL
    - the equivalent MF PDS is always called xxxxxx.yyyy.COBOL

    I would like to be able create settings that say that the left-hand side should be converted using ANSI, and the right-hand side should be converted using 1143. In addition, the line length of the right-hand side is ALWAYS 80 characters.

    I have managed to open a couple of files but at the moment, the right-hand side is (by default) always being opened using 936 as the conversion. I can change this via Session, Session settings and the format tab to 1143. Trouble is, the file isn't shown with a line length of 80 bytes.

    I changed the settings via Tolls, File formats as shown in the attached screen, but when I then review the results, trailing spaces seem to still be significant as shown in the second attachment
    Last edited by misi01; 18-May-2010, 06:49 AM.
  • misi01
    Old Hand
    • Jun 2005
    • 210

    #2
    Since nothing's happened, I'm going to bump this

    What values do you need to know such that the results from BC3 are the same as BC2 ? I attach 2 screen captures comparing the SAME files using BC2 & 3. As you can see, BC3 considers the very first line in the files as differing whereas BC2 doesn't.
    Last edited by misi01; 18-May-2010, 06:49 AM.

    Comment

    • Aaron
      Team Scooter
      • Oct 2007
      • 15997

      #3
      Hello,

      It looks like you've got your File Formats/Rules set up pretty well. Turn on Ignore Unimportant Differences (upper left Toolbar, looks like a squiggly Equals sign). This will hide the Blue/Unimportant Text and show it as Black/Equal text. It is enabled in your BC2 screenshot but not your BC3 screenshot.

      Are you still having trouble with the line length not 80? If so, could you provide some screenshots to show what you mean in BC2 and BC3. You can also send example files to [email protected] and include a link to this forum post.
      Aaron P Scooter Software

      Comment

      • misi01
        Old Hand
        • Jun 2005
        • 210

        #4
        Thanks Aaron

        I did as you suggested and the difference on the first line disappeared. Trouble is, when I then selected the next difference section, I got the appended screen capture which seems to be indicating that the trailing blanks are considered different (as indicated by the green arrow).

        My basic problem is as follows.

        I want to be able to define a session that compares a PC folder on the left (all with filetypes CBL) with a PDS on the mainframe on the right (that will always be called xxxx.yyyy.COBOL). I want the selected file on the left to be opened using ANSI and the one of the right using Swedish-Finnish. In addition, the left file and right files are ALWAYS 80 characters long. The left-hand file contains CRLF after each 80 characters, the right-hand file has "records" that are 80 bytes - ie, no CRLF).

        I get the impression that when I want to save a session with the files open, it wants to save them as shown in the second capture (note how it seems to append the names of the files being compared).

        If I close these files and try and save the session as shown in the 3rd capture, it doesn't seem to "realize" the format settings I want since that isn't an option when saving a session based on the folder contents.

        Hope this clarifies matters.
        Last edited by misi01; 18-May-2010, 06:49 AM.

        Comment

        • misi01
          Old Hand
          • Jun 2005
          • 210

          #5
          Bump

          I would very much like to see a solution/suggestion to this problem. From our point of view here at the bank, as it stands, BC3 offers no improvements on BC2.

          Comment

          • Michael Bulgrien
            Carpal Tunnel
            • Oct 2007
            • 1772

            #6
            This is not the same scenario as you had in your original screenshot. As you can see, this line has red shading behind it, while the first line had blue shading behind it. The red indicates that your file format grammar rules have been defined in such a way that this line is considered to be an important change. You'll need to correct the grammar rules so that this line is considered to be an unimportant change.

            I do not have any cobol source to test with, but from what I remember, columns 73 to 80 (last 8 characters) are defined as a line number field. Your extra spaces extend into this area. Check how your line numbers are defined. Are they important, or unimportant?

            (Remove the checkmark from the "Line Number" grammar element under the session settings "Importance" tab.)
            BC v4.0.7 build 19761
            ¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯

            Comment

            • Michael Bulgrien
              Carpal Tunnel
              • Oct 2007
              • 1772

              #7
              P.S. I pulled some sample Cobol source off the Internet and tested your scenario (minus the mainframe) and the trailing spaces do not show up as significant on my system with the default cobol file format grammar rules that came "out-of-the-box" with BC3.

              Just curious...if you put both files locally on your PC, do the trailing spaces still show up as an important difference? If comparing two files on the PC get different results than comparing the same two files when one is on the mainframe...then maybe there is a mainframe-related bug that needs to be fixed???
              Last edited by Michael Bulgrien; 09-Mar-2009, 11:39 AM.
              BC v4.0.7 build 19761
              ¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯

              Comment

              • Aaron
                Team Scooter
                • Oct 2007
                • 15997

                #8
                Hello,

                BC3's definitions for Importance and Unimportance were changed to be handled by both File Formats and Session Settings. This is why they are not directly importable from BC2 into BC3. You can, however, recreate your rules manually.

                Blue text is considered Unimportant, but will still be hit by the "Next Difference" button, since it is technically a difference. You can hide blue text with the Ignore Unimportant Differences button, which will mark the Blue text as black, and treat it as equal. This is the same as BC2. So, first we want to make sure your text is Blue instead of Red, which means it is properly defined. Then configure BC to skip over Blue text.


                To mark your trailing whitespace (before the wrap) as unimportant, go to the Session menu -> Sesison Settings, Importance tab, and uncheck Trailing Whiteapce. Since this is a Session option, you will have to save it as part of a specific session or set it as the Text Compare Session default (lower left dropdown box; change from "Use in this view only" to "Also update Session Defaults").
                Your first pair of screenshots showed the trailing whitespace as Blue, while your second pair shows it as red. Did you Session Settings change inbetween these two screenshots?

                Please send in your BC Support package to [email protected] and, if you can, include a pair of sample files, if you are still running into any trouble setting up BC3.

                Please include a link to this forum post, as well.

                Side Note:
                Alternatively, you can create a specific folder compare, which will then use specific Text Compare settings. First Save the Folder Compare session, then open your files and change the setting, then go to the lower left dropdown box to change from "For this View Only" to one of the three other options (only one other option shown if Text Compare is not a Folder Compare's Child Session).
                Aaron P Scooter Software

                Comment

                • misi01
                  Old Hand
                  • Jun 2005
                  • 210

                  #9
                  Michael. Downloading the file to the PC shows no differences between them

                  Comment

                  • Michael Bulgrien
                    Carpal Tunnel
                    • Oct 2007
                    • 1772

                    #10
                    Originally posted by misi01
                    Michael. Downloading the file to the PC shows no differences between them
                    Sorry, could you qualify that statement? No differences between what?

                    No difference in the compare (meaning that the problem still exists when both files are on the PC)?

                    Or no important differences between the files (all sections are shaded blue) when both files are on the PC?
                    BC v4.0.7 build 19761
                    ¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯

                    Comment

                    • misi01
                      Old Hand
                      • Jun 2005
                      • 210

                      #11
                      Rather than there being any misunderstanding

                      I downloaded the mainframe file to my C-drive and compared it and the original PC file. My append of 03-Mar-2009, 07:33 AM showed "discrepancies". The new comparison is as shown in the attachment (note no "discrepancies" this time)

                      Comment

                      • Aaron
                        Team Scooter
                        • Oct 2007
                        • 15997

                        #12
                        Hello,

                        But on the server, you still see Red whitespace? Did you try setting the Session Setting to Ignore Trailing Whitespace?

                        The problem you hit in your 2nd post (Red Whitespace) is different than the first problem (Blue Whitespace). First we want to make sure your Session Settings/Importance Tab and FileFormats/Grammar tab are configured for your files, which will mark the Text as Blue Differences.

                        After we have succesffully made trailing spaces blue, then we can hide Blue Differences with the Ignore Unimportant Differences Toolbar button.

                        Session Settings are Session/Instance specific. If you want to use them for all settings, you need to update the Session Defaults for the Text Compare session type. You can do this from any Session Settings dialog (bottom left dropdown), or from the Home screen under the Edit Session Defaults folder->Text Compare.
                        Aaron P Scooter Software

                        Comment

                        • Michael Bulgrien
                          Carpal Tunnel
                          • Oct 2007
                          • 1772

                          #13
                          Originally posted by misi01
                          I downloaded the mainframe file to my C-drive and compared it and the original PC file. My append of 03-Mar-2009, 07:33 AM showed "discrepancies". The new comparison is as shown in the attachment (note no "discrepancies" this time)
                          Your 03-Mar-2009 screenshot showed the "discrepancy" on line 92. This screenshot is set at line 1.
                          The thumbnail still has red in it, so there must be important differences further down in the file.
                          BC v4.0.7 build 19761
                          ¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯

                          Comment

                          • misi01
                            Old Hand
                            • Jun 2005
                            • 210

                            #14
                            Quite right Michael, but my original "complaint" was the fact that, outwardly at least, two "identical" lines were being marked as different. Totally different lines further down were, as you pointed out, marked in red as expected.

                            Comment

                            • Aaron
                              Team Scooter
                              • Oct 2007
                              • 15997

                              #15
                              Hello misi01,

                              I'm having a bit of trouble following which of the 5 or so screenshots you are referring to at this point.

                              It is important to clarify when detecting differences if it is an Unimportant Difference or an Important Difference. Blue text that you 'hit' when you go to Next Difference simply means you need to toggle a switch (Ignore Unimportant Differences) which hides blue text as black. If two lines outwardly appear identical, but are showing a blue or red background, it means that a difference does exist, but the difference text is not currently displayed. This is usually because it is whitespace, and we hide whitespace by default. The toggle Show Whitespace characters can display the whitespace in the main window.

                              If you are hitting Red text you do not expect, then that means we need to change your Session Settings or Grammar, and that is dependent on specifically which text is being hit. An updated screenshot may help here, if this is the case.
                              Aaron P Scooter Software

                              Comment

                              Working...