Endevor

  • 1.  File Master PDS Update Option - Change a Word and not a substring.

    Posted Feb 22, 2017 10:04 AM

    Greetings,

    I need to do a massive update in all members of a PDS. I need to change the JCL CLASS parameter, within the job card. The problem is that when I apply the Change Command it changes not only the complete word but also possible substrings, and so it also changes MSGCLASS also. That is an undesired effect. Is it possible to change only a WORD and not a substring of a word?

     

    What I have tried:

     

    Case 1:

    //SYSIN     DD *   

    COPY,                                                 
      INFILE(SYSUT1),                                     
      OUTFILE(SYSUT1O),                                   
      REPLACEMEM(Y),                                      
      INFORMAT(JCL),                                      
      MEMBER(*),                                          
        CHANGE(1,0,EQ,C"CLASS=P",C"CLASS=Y")              

     

     

     

     

     

    Case2:

     

    //SYSIN     DD *                                      
      COPY,                                               
        INFILE(SYSUT1),                                   
        OUTFILE(SYSUT1O),                                 
        REPLACEMEM(Y),                                    
        INFORMAT(JCL),                                    
        MEMBER(*),                                        
          CHANGE(1,0,EQ,C" CLASS=P",C" CLASS=Y",AND,       /* I also tried the 'OR' keyword
                        C",CLASS=P",C",CLASS=Y",ALL)         

     

     

     

    The latter is a workaround to avoid the substitution of the parameter MSGCLASS but it only replaces the first expression.



  • 2.  Re: File Master PDS Update Option - Change a Word and not a substring.
    Best Answer

    Broadcom Employee
    Posted Feb 22, 2017 01:54 PM

    I used the following syntax and it seems to have given the desired result:

     

    COPY,
        INFILE(SYSUT1),
        OUTFILE(SYSUT1O),
        REPLACEMEM(Y),
        INFORMAT(JCL),
        MEMBER(*),
        CHANGE(1,0,EQ,C" CLASS=P",C" CLASS=Y",ALL),
        CHANGE(1,0,EQ,C",CLASS=P",C",CLASS=Y",ALL)

     

     

    In the future, it may be easier for you to use option 3.9 to create the proper syntax from the panels:

     

    CA File Master Plus ---------- Update From & To Character Strings ----------

      COMMAND ===>                                                             

                                                                                

                     Pos  Len   Op  Value                                                                                     All

                                                                                

      From ===> 1     0     EQ C" CLASS=P"___________________________________   

      To                                    C" CLASS=Y"___________________________________  Y

                                                                                

      From ===> 1     0     EQ C",CLASS=P"___________________________________   

      To                                     C",CLASS=Y"___________________________________  Y



  • 3.  Re: File Master PDS Update Option - Change a Word and not a substring.

    Posted Feb 22, 2017 01:58 PM
      |   view attached

    Hello,

    I used the Job submission option for then I can submit several massive updates at a time, since there are several classes to update.

    This will only affect the first 3 records of the JCL? That was also an issue.

    Thank you!

     

     

    Cumprimentos / Saludos / Grüße / Best Regards,

     

    Cátia Lindo

    Produban Portugal – Grupo Santander

    Planeamento

    Tel.: (00351) 21 420-1532 |  Ext. 135 532

    Mov.: (00351) 93 8883039

    Fax.: (00351) 21 420-1 586/587/588/589

    Catia.Lindo@produban.pt<mailto:Catia.Lindo@produban.pt>

    Rua da Mesquita, 6, Piso -5

    1070-238 Lisboa, Portugal



  • 4.  Re: File Master PDS Update Option - Change a Word and not a substring.

    Posted Aug 29, 2017 09:25 AM

    Thank you, but I do prefer using the JCL because this screen seems to me too much limited in options comparing to the flexibility of a SYSIN built in a JCL.

    Also, I don't see how using that option would do what I asked in this post which is recognize the string I provide as a WORD and not a substring.

    Even if I use that screen, it will susbtitute 2 strings, CLASS and MSGCLASS.