0 Replies Latest reply: Jan 2, 2013 12:11 PM by Howard (... in Training) RSS

    APEX code corrupted by PVCS upon check in

    Howard (... in Training)
      We are using an (old) PVCS Version Manager, Version 6.7.11 (Build 915.12) and some APEX code is corrupted upon check in to PVCS.

      Has anyone had a similar problem using PVCS for CM of APEX?

      We have the following 11 lines of code to display a revision number. (Line numbers added for reference.)
      01 BEGIN
      02    SELECT ' $Revision:   1.4  $ '
      03      INTO :FNNNNN_REV
      04      FROM DUAL;
      05    select ltrim(:FNNNNN_REV,' $Revision:')
      06     INTO :FNNNNN_REV
      07     FROM DUAL;
      08    select rtrim(:FNNNNN_REV,'$ ')
      09      INTO :FNNNN_REV
      10      FROM DUAL;
      11 end;
      Most of the time, the code is checked into and out of PVCS with the version number code being updated correctly.
      01 p:=p||'BEGIN'||unistr('\000a')||
      02 '   SELECT '' $Revision:   1.4  $ '''||unistr('\000a')||
      03 '     INTO :FNNNNN_REV'||unistr('\000a')||
      04 '     FROM DUAL;'||unistr('\000a')||
      05 '   select ltrim(:FNNNNN_REV,'' $Revision:'')'||unistr('\000a')||   
      06 '     INTO :FNNNNN_REV'||unistr('\000a')||
      07 '     FROM DUAL;'||unistr('\000a')||
      08 '   select rtrim(:FNNNNN_REV,''$ '')'||unistr('\000a')||
      09 '     INTO :FNNNNN_REV'||unistr('\000a')||
      10 '     FROM DUAL;'||unistr('\000a')||
      11 'end;';
      Ocassionally, one line -- line 05 -- is corrupted on check-in. Compare with line 05 above.
      01 p:=p||'BEGIN'||unistr('\000a')||
      02 '   SELECT '' $Revision:   1.5  $ '''||unistr('\000a')||
      03 '     INTO :FNNNNN_REV'||unistr('\000a')||
      04 '     FROM DUAL;'||unistr('\000a')||
      05 '   select ltrim(:FNNNNN_REV,'' $Revision'\000a')||
      06 '     INTO :FNNNNN_REV'||unistr('\000a')||
      07 '     FROM DUAL;'||unistr('\000a')||
      08 '   select rtrim(:FNNNNN_REV,''$ '')'||unistr('\000a')||
      09 '     INTO :FNNNNN_REV'||unistr('\000a')||
      10 '     FROM DUAL;'||unistr('\000a')||
      11 'end;';
      Here are the original line of code and the two PVCS versions next to each other:
      05     select ltrim(:FNNNNN_REV,' $Revision:')    -- < Original code
      05 '   select ltrim(:FNNNNN_REV,'' $Revision:'')'||unistr('\000a')|| 
      05 '   select ltrim(:FNNNNN_REV,'' $Revision'\000a')||
      It would seem to be a PVCS parser problem. But how can it occur just some of the time?

      Has anyone had a similar problem using PVCS for CM of APEX?

      As I get time, I may rewrite the offending line so that it doesn't end with ')

      *****************************
      Howard