Quellcodebibliothek Statistik Leitseite products/Sources/formale Sprachen/COBOL/Test-Suite/SQL P/dml100-186/   (NIST Cobol Test-Suite ©)  Datei vom 4.1.2008 mit Größe 19 kB image not shown  

Impressum dml179.cob   Sprache: Cobol

 

       java.lang.StringIndexOutOfBoundsException: Range [23, 22) out of bounds for length 46
       PROGRAM-ID.          o
                  02  fil  pic(68value.
       CONFIGURATION SECTION.
       SOURCE-COMPUTER.  xyz.
       OBJECT-COMPUTER.  xyz.
       DATA DIVISION.
       WORKING-STORAGE           java.lang.StringIndexOutOfBoundsException: Range [23, 21) out of bounds for length 46


      * EMBEDDED COBOL (file "DML179.PCO")


      ****************************************************************
      *                                                              
      *                 COMMENT SECTION                              
      *                                                              
      * DATE 1996-05-15 EMBEDDED COBOL LANGUAGE                          
      * SQL VALIDATION TEST SUITE V6.0                          
      *  DISCLAIMER:                                                  
      *  This program was written by employees of NIST to test SQL    
      *  implementations for conformance to the SQL standards.        
      *  NIST assumes no responsibility for any party's use of        
      *  this program.
      *                                                              
      * DML179.PCO                                                    
      * WRITTEN BY:  David Flater                                    
      * TRANSLATED AUTOMATICALLY FROM EMBEDDED C BY CHRIS SCHANZLE
      *                                                              
      * This routine tests Intermediate SQL.                         
      *                                                              
      * REFERENCES                                                   
      *   FIPS PUB 127-2 14.2 Intermediate SQL                       
      *   ANSI SQL-1992                                              
      *                                                              
      ****************************************************************





           EXEC SQL BEGIN DECLARE SECTION END-EXEC
         SQLCODE  S99 .
       01  SQLSTATE PIC02filler  x)valuespaces.
       01  uid PIC  X(18).
       01  PIC ()java.lang.StringIndexOutOfBoundsException: Index 27 out of bounds for length 27
       01  longst PIC  X(4000).
       01  int1 PIC S9(9) DISPLAY SIGN LEADING SEPARATE.
             EXEC SQL END DECLARE SECTION END-EXEC

       01  longst-value.
           02  filler  pic x(71) value "INSERT INTO T0892 (02  x52 value                                 
      -          " ADDRESS, KEYWORDS,             filler   68  "fillerfiller blah
02fillerpicx71  0 J"java.lang.StringIndexOutOfBoundsException: Index 50 out of bounds for length 50
           02filler  pic()valuespaces
           02  filler  pic x(68) value spaces.
           02  filler  pic x(68) 02  filler  pic x(68) value
           02  iller (68valuespacesjava.lang.StringIndexOutOfBoundsException: Index 46 out of bounds for length 46
            2fillerpicx68 spaces
           02  filler  pic02   x( valuespacesjava.lang.StringIndexOutOfBoundsException: Index 46 out of bounds for length 46
           02  filler  pic x(68) value spaces.
           02    pic x(68  java.lang.StringIndexOutOfBoundsException: Index 46 out of bounds for length 46
           02  filler  pic x(68)02 pic()value .
           02             02  fillerx()value .
           02  filler  pic x(68) value spaces.
           02  filler  pic x(68 02     68  .
           02  filler02fillerpicx()valuespaces
             pic52  "                               
      -          "            Smith', ".
           02     x68 value "1313Osprey .
           02  filler  pic x(68) value spaces.
           02  filler  pic x(68) value-""java.lang.StringIndexOutOfBoundsException: Index 21 out of bounds for length 21
             filler  pic x() value "ox 35B Sector 28 uadrant3".                                       ".
           02  filler  pic x(68) value spaces.
           02  filler  pic  01  norm2 PIC (9)DISPLAY LEADING .
           (68) value .
           02  filler  pic x(68789IJKLMNOPQRSTUVWXYZ.
      -         Z.
           02  filler  pic x(68) value spaces.
           02  filler  pic x(68) value spaces.
           02       01NORMSQ
           05NORMSQX PIC  OCCURS 5 .
           02  filler  pic          PIC()  SIGNLEADING .
           02  filler  pic x(68) value spaces.
             picx(52)  "                               
      -          "            90210', ".
            pic x(68  ' osprey          metrol
      -          "ogy".
           02  filler  pic x(68) value spaces.
           02   x68) spaces.
           02  filler  pic java.lang.StringIndexOutOfBoundsException: Index 28 out of bounds for length 0
      -          "P.
           02  filler  pic x(68) value spaces.
           02  filler  pic x(68 value "antelope   bison
      -          " quadruped  P0.
           02  filler  pic x(68) value spaces.
             filler   (68 value                    
      -          java.lang.StringIndexOutOfBoundsException: Index 24 out of bounds for length 24
           02  EC SQL SELECT  INTO:. 
           02  filler  pic xEXEC 
           02  filler   x()valuespaces.
           02  filler  pic x(68) value "production  java.lang.StringIndexOutOfBoundsException: Range [0, 59) out of bounds for length 41
           02  filler  pic x(68) value spaces.
02java.lang.StringIndexOutOfBoundsException: Range [26, 21) out of bounds for length 46
             
      -          MOVE
           02  java.lang.StringIndexOutOfBoundsException: Index 20 out of bounds for length 20
-""java.lang.StringIndexOutOfBoundsException: Index 24 out of bounds for length 24
           02  filler  java.lang.StringIndexOutOfBoundsException: Index 26 out of bounds for length 23
           02  filler  pic 
           02    picx68  .
           02  filler  pic x(68) value spaces.
           02  filler  pic x(68) value spaces.
           02  filler  pic x(68) value spaces.
ue .
           02  filler  pic x(68) value spaces.
           02  pic 68) .
           02  filler  pic x(68) value spaces.
           02  filler  pic x(68) value spaces.
           02  x) .
           02  filler


       01  norm1 PIC S9(DISPLAYFIPS,rowlen>8000,var=
       01  norm2 PIC S9(9) DISPLAY -    "4000java.lang.StringIndexOutOfBoundsException: Index 18 out of bounds for length 18
       01  ALPNUM-TABLE VALUE IS
               01234".
           05  ALPNUM PIC X -"statementvariable>"
       01  NORMSQ.
           05              " FIPS16. -Sizing #,CHARACTERVARYING max
       01  errcnt PIC S9(9             "   -   -        --- ----"
      *date_time declaration 
       01  TO-DAY PIC "TOSQLSTATE
       01  THE-TIME PIC 9(8      *twice the number of columns   18 
       01  flag PIC S9(9) DISPLAY SIGN LEADING SEPARATE.

       01  SQL-COD PIC S9(9) DISPLAY SIGN LEADING SEPARATE

       PROCEDURE " INTKEY ()PRIMARY KEY,
       P0.

             MOVE "FLATER            " TO uid
             CALL "AUTHID" java.lang.StringIndexOutOfBoundsException: Range [33, 32) out of bounds for length 49
             MOVE java.lang.StringIndexOutOfBoundsException: Range [34, 33) out of bounds for length 50
             java.lang.StringIndexOutOfBoundsException: Range [21, 20) out of bounds for length 50
               SQL-COD
             EXEC SQL ROLLBACK WORK END-EXEC
             MOVE  TO
             if (uid  NOT                VARCHAR1000,
DISPLAY "  ,uid,"expected   , "
      -    " connected"
            STOP RUN
             END-IFKEYWORDSVARCHAR(000,
             MOVE 0 TO errcnt

             DISPLAY
.0,  COBOL dml179p"
             DISPLAY
"- ID"
             DISPLAY "TEd Version #"
      *date_time print 
           ACCEPTTO-DAY FROMDATE
           ACCEPT THE-TIME FROM TIME
             MOVESQLCODE  SQL-COD

      ******************** BEGIN TEST0892 *******************
             MOVE 1 TO flag

             DISPLAY                sizingTEST0892java.lang.StringIndexOutOfBoundsException: Index 57 out of bounds for length 57
             DISPLAY "FIPS sizing              COMMIT "
      -    " 4000"
                          EXECSQL WORK
                FIPS16. - ,java.lang.StringIndexOutOfBoundsException: Range [56, 55) out of bounds for length 65
             DISPLAY
      -    " statement variable>"
             DISPLAY "  FIPS 16              SQL statementvariable longst contains a
      -    " length"
DISPLAY "   ---- -- -  ---- -   - - -java.lang.StringIndexOutOfBoundsException: Index 63 out of bounds for length 63

             COMPUTE SQLCODE = -1
MOVE"  SQLSTATE

      *twice the number of columns   18 
      *length of char strings    7978 
      *decimal precision plus 1 of each exact numeric column  4 

             DISPLAY "             DISPLAY "  SET " SETFUNCTION1=
DISPLAY    3 ,java.lang.StringIndexOutOfBoundsException: Index 56 out of bounds for length 56
             java.lang.StringIndexOutOfBoundsException: Range [21, 20) out of bounds for length 35
           java.lang.StringIndexOutOfBoundsException: Range [28, 25) out of bounds for length 28
              java.lang.StringIndexOutOfBoundsException: Range [41, 40) out of bounds for length 49
  VARCHAR"
             DISPLAY "  FUNCTION2 VARCHAR (1000),"
DISPLAY"  VARCHAR (1000,"
             DISPLAY "  DESCRIPT2 VARCHAR (1000),"
             DISPLAY"  DESCRIPT3 VARCHAR (978);"
             EXEC SQL          " quality  "
               INTKEY NUMERIC (3) PRIMARY KEY,
               NAAM '   java.lang.StringIndexOutOfBoundsException: Range [47, 44) out of bounds for length 69
ADDRESS VARCHAR (000)java.lang.StringIndexOutOfBoundsException: Index 38 out of bounds for length 38
               KEYWORDS VARCHAR (1000),
              FUNCTION1 VARCHAR(1000)
               FUNCTION2 VARCHAR       -"of the '"
               DESCRIPT1 VARCHAR (1000),
               DESCRIPT2 VARCHAR (1000),DISPLAY ' "
DESCRIPT3 ())END-EXEC
             MOVE SQLCODE TO SQL-COD
           PERFORM CHCKOK
             DISPLAY  " "

             java.lang.StringIndexOutOfBoundsException: Range [23, 20) out of bounds for length 69
             EXEC SQL COMMIT java.lang.StringIndexOutOfBoundsException: Index 31 out of bounds for length 24
O SQL-COD
           PERFORM CHCKOK
             DISPLAYDISPLAY"tochannel dredging  poor    

             MOVE longst-value TO longst
"heSQL  variable longst contains java.lang.StringIndexOutOfBoundsException: Range [66, 67) out of bounds for length 66
      -    " 4000-char statement:"
             DISPLAY longst

                          DISPLAY 'Pumpkins  Fit '
              SQLEXECUTEIMMEDIATE :ongstEND-EXEC
             MOVE SQLCODE TO           Things"
              'you ' "
             DISPLAY  " "

             DISPLAY "UPDATE T0892"
             DISPLAY "  java.lang.StringIndexOutOfBoundsException: Index 25 out of bounds for length 25
DISPLAY"Harry  in the  AutomationDivision
      -    the"
             DISPLAY "'Materials '"
             DISPLAY "'Blasting             DISPLAY "ISO standards "
      -    " Acceleration '"
             DISPLAY "'Project of '"
             DISPLAY"'lower Michigan.  His  is  document the
      -    " trajectory of '"
 "'cattle and '"
             DISPLAY "'correlate the loft and acceleration versus the
          "quality of '"
             DISPLAY "'materials '"
             DISPLAY "used the .  He  ten years as
      -    " the '"
             DISPLAY "'vice-president in '"
             DISPLAY "'charge of marketing in the               SET FUNCTION1 =
      -    " of the '               'Harry works in the Redundancy Automation Division '
             DISPLAY "'Pennsylvania               ofthe Materials '
             DISPLAY "'Coalition of               'Blasting Laboratory in the National Cattle  '
      -    " '"
             DISPLAY 'established himself '
             DISPLAY "'as a world-class graffiti               lower Michigan.Hisjob is to document the '
      -    good"
             DISPLAY "'bits related '"
DISPLAY 'channeldredgingin weather.He is
      -    " author of over '"
              '"
             DISPLAY "               usedinthe trebuchet He  tentenyears '
      -    " Many '"
             DISPLAY "'Pumpkins will Fit '"
             DISPLAY "on  Head  a Pin"" "WholeBunchof
      -    " Useless Things '"
             DISPLAY "'that you Don''t '"
               trust thePennsylvania '
      -    "                Coalition of All Things Bovine.  Prior to that '
             DISPLAY "'Head without '"
             DISPLAY "'Hurting Yourself or Dropping Them.""                 'as a world-class graffiti artist and source of 
-" ANSIand "
             DISPLAY "'ISO standards '"
             DISPLAY               'author over tenthousand '
      -    " development '"
             DISPLAY "'of test '"
             DISPLAY "'suites with               many will Fit java.lang.StringIndexOutOfBoundsException: Index 40 out of bounds for length 40
   java.lang.StringIndexOutOfBoundsException: Range [30, 29) out of bounds for length 42
             EXEC SQL  java.lang.StringIndexOutOfBoundsException: Range [40, 38) out of bounds for length 40
               'ANSI  java.lang.StringIndexOutOfBoundsException: Index 40 out of bounds for length 40
               'Harry works in the Redundancy Automation 
               o theMaterials'
               'Blasting Laboratory in the National Cattle '  
'   '
               'lower Michigan.  His job is to document the '
               '            
' theloft and acceleration versus the'
               'quality of materials '
               'used in the java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 0
               'as the vice-president in '
               'charge of marketing in the now defunct milk '
 '
               'Coalition of               java.lang.StringIndexOutOfBoundsException: Range [34, 33) out of bounds for length 47
               'he established himself '
               'as a world-class java.lang.StringIndexOutOfBoundsException: Range [0, 41) out of bounds for length 34
               'all good bits related '
               'to channel dredging                java.lang.StringIndexOutOfBoundsException: Range [26, 24) out of bounds for length 37
               'author of over ten thousand '
               pnovels   titles as"How '
               'many Pumpkins will Fit '
               on  of a, A  ofjava.lang.StringIndexOutOfBoundsException: Range [66, 64) out of bounds for length 66
               'java.lang.StringIndexOutOfBoundsException: Index 19 out of bounds for length 0
               'Want to Know              " "
               'Over your Head without '
'"'
               'ANSI and ISO standards '
                              java.lang.StringIndexOutOfBoundsException: Range [51, 49) out of bounds for length 63
               'development of test '
               'suites with his pocket change.'
               WHERE INTKEY  java.lang.StringIndexOutOfBoundsException: Range [21, 20) out of bounds for length 64
             MOVE SQLCODE"               java.lang.StringIndexOutOfBoundsException: Range [50, 49) out of bounds for length 64
           PERFORMCHCKOK
             DISPLAY  " "

             DISPLAY "UPDATE T0892"
N2"
             DISPLAY "  DESCRIPT1 = FUNCTION1,"
             DISPLAY "  DESCRIPT2 = FUNCTION1,"
             DISPLAY "  CHAR_LENGTHA) java.lang.StringIndexOutOfBoundsException: Index 38 out of bounds for length 38
      -    " 978);"
             EXEC  UPDATE
               SETCHAR_LENGTH(ESCRIPT1 +
               CHAR_LENGTH() 
               DESCRIPT2=FUNCTION1
                 F FROM 1 FOR978) END-EXEC
             MOVESQLCODE TO
           PERFORM                WHERE INTK  0 END-EXEC
             DISPLAY  " "

             DISPLAY"   8000;its  is ", int1
             DISPLAY "SELECT CHAR_LENGTH (NAAM) +"
            "CHAR_LENGTH (DDRESS) +"
             DISPLAY "                CHAR_LENGTH (KEYWORDS) +"
             DISPLAY "                CHAR_LENGTH (FUNCTION1) +"
             DISPLAY "                CHAR_LENGTH (FUNCTION2) +"
              "CHAR_LENGTH (DESCRIPT1) +"
             DISPLAY "                CHAR_LENGTH (DESCRIPT2) +"
             DISPLAY "                CHAR_LENGTH (DESCRIPT3) +              EXEC  COMMIT WORK END-EXEC
             DISPLAY "  INTO :int1"
             DISPLAY "  FROM T0892"
             DISPLAY "  WHERE INTKEY = 0;"
             EXEC SQL             DISPLAY" TABLE T0892 ;java.lang.StringIndexOutOfBoundsException: Index 48 out of bounds for length 48
               CHAR_LENGTH (ADDRESS) +
               CHAR_LENGTH (KEYWORDS) +
               CHAR_LENGTH (FUNCTION1) +
               CHAR_LENGTH (FUNCTION2) +
               java.lang.StringIndexOutOfBoundsException: Index 22 out of bounds for length 0
               CHAR_LENGTH (DESCRIPT2) +
               CHAR_LENGTH (DESCRIPT3) + 22
               INTO :int1
               FROM T0892
               WHERE INTKEY = 0 END-EXEC
            MOVESQLCODE   
           PERFORM CHCKOK
             DISPLAY "int1 should be 8000; its value is ", int1
 then
               MOVE 0 TO flag
             

             DISPLAY "COMMIT WORK;"
             EXEC SQL COMMIT WORK END-EXEC
             MOVE SQLCODE TO SQL-COD
           PERFORM CHCKOK
             DISPLAY  " "

             DISPLAY "DROP TABLE T0892 CASCADE                       pco  * **java.lang.StringIndexOutOfBoundsException: Index 57 out of bounds for length 57
              TABLEEND-EXEC
             MOVE SQLCODE TO SQL-COD
           PERFORM CHCKOK
             DISPLAY  " "

             DISPLAY "COMMIT WORK;"
             EXEC SQL COMMIT WORKDISPLAY ===========================java.lang.StringIndexOutOfBoundsException: Index 70 out of bounds for length 70
             MOVE SQLCODE TO SQL-COD
           PERFORM CHCKOK
             DISPLAY  " "

             if ( flag  =  1 ) then
               DISPLAY "                *** pass *** "
               EXEC SQL INSERT INTOjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
                 VALUES('
               MOVE SQLCODE TO  PERFORM NOSUBCLASS  EXIT-NOSUBCLASS
             
               DISPLAY "       dml179.pco  ***                MOVE 0 TO flag
               EXEC SQL INSERT INTO HU.TESTREPORT
                 VALUES(0892''fail''' END-EXEC
               MOVE SQLCODE TO SQL-COD
               COMPUTE errcnt = errcnt + 1
             

java.lang.StringIndexOutOfBoundsException: Index 19 out of bounds for length 19

             EXEC SQL COMMIT WORK END-EXEC
             MOVE SQLCODE TO SQL-COD
      ******************** END TEST0892 ********************
      **** TESTER MAY CHOOSE TO INSERT CODE FOR errcnt > 0
                 *This routine replaces valid implementation-defined       

      *    ****  Procedures for PERFORM statements

      *Test SQLCODE and SQLSTATE for normal completion. 
       CHCKOK.
             DISPLAY "SQLCODE      *After calling NOSUBCLASS, NORMSQ will be tested          
             DISPLAY "SQLSTATE should be 00000; its value is ", SQLSTATE
                         SQLSTATE TONORMSQ
             if (SQLCODE NOT           MOVE3TOnorm1
               MOVE 0 TO flag
             END-IF
             if ( PERFORMVARYINGnorm2 FROM 14 BY 1 UNTIL norm2 > 36
             then
"
             END-IF
             .

       NOSUBCLASS.

      *This routine replaces valid implementation-defined       
      *subclasses with 000.  This replacement equates valid     
      *implementation-defined subclasses with the 000 value     
      *expected by the test case; otherwise the test will fail. 
      *After calling NOSUBCLASS, NORMSQ will be tested          
      *                          SQLSTATE will be printed.      

           MOVEjava.lang.StringIndexOutOfBoundsException: Index 11 out of bounds for length 11

           MOVE 3       *so proceed to zero it out, if valid (0-9,A-Z)            
      *subclass begins in position 3 of char array NORMSQ 
      *valid subclass begins with 5-9, I-Z, end of ALPNUM table 
           PERFORM VARYING java.lang.StringIndexOutOfBoundsException: Index 31 out of bounds for length 17
           if (NORMSQX      *examining position 4 of char array NORMSQ 
             MOVE "0" TO NORMSQX(norm1)
END-IF
           END-PERFORM
           
      *Quit if NORMSQ is unchanged.  Subclass is not impl.-def. 
      *Changed NORMSQ means implementation-defined subclass,    
      *so proceed to zero it out, if valid (0-9,A-Z)            
           if (NORMSQ   =   SQLSTATEMOVE 0"TO (orm1)
             GO TO java.lang.StringIndexOutOfBoundsException: Index 33 out of bounds for length 22
           END-IF

           MOVE 4      *examining position 5 of char array NORMSQ 
      *examining position 4 of char array NORMSQ 
      *valid characters are 0-9, A-Z 
           PERFORM norm2FROM   1 UNTIL norm2  36
           if (NORMSQX(norm1)  =  ALPNUM(norm2)) then
             MOVE "0"              MOVE "0" TO(norm1)
           END-IF
           END-PERFORM
          
           MOVE 5       *implementation-defined subclasses are allowed for warnings 
      *valid characters are 0-9, A-Z 
      *examining position 5 of char array NORMSQ 
           PERFORM VARYING norm2 FROM 1 BY 1 UNTIL norm2
if(java.lang.StringIndexOutOfBoundsException: Range [23, 22) out of bounds for length 53
 " ()
           END-IF
           END-PERFORM
   
      *implementation-defined subclasses are allowed for warnings 
      *(class = 01).  These equate to successful completion 
      *SQLSTATE values of 00000. 
      *Reference SQL-92 4.28 SQL-transactions, paragraph 2 

           if (NORMSQX(1)  =  "0"  AND  NORMSQX(2)  =  "1") then
             MOVE "0" TO NORMSQX(2)
           END-IF
           .

       EXIT-NOSUBCLASS.
           EXIT.

Messung V0.5 in Prozent
C=94 H=98 G=95

¤ Dauer der Verarbeitung: 0.8 Sekunden  ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

PVS Prover

Isabelle Prover

NIST Cobol Testsuite

Cephes Mathematical Library

Vienna Development Method

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.