Re: Not understanding COBOL diagnostic
On 16 Jul 2015 08:04:03 -0700, in bit.listserv.ibm-main you wrote: 1+2+3+4+5+6+7 DISPLAY ' YOU HAVE ACTIVATED STATISTICS WITH EXPLAIN' - ' BUT HAVE NOT CREATED THE PLAN_TABLE.' DISPLAY ' EXPLAIN HAS BEEN DEACTIVATED TO ALLOW THE' - ' PROGRAM TO RUN TO COMPLETION.' DISPLAY ' PLEASE CREATE THE PLAN_TABLE AND RESUBMIT' - ' THE PROGRAM FOR EXPLAIN INFORMATION.' Charles -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Lizette Koehler Sent: Thursday, July 16, 2015 7:24 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Not understanding COBOL diagnostic You don't need the continuation hyphen in column 7 because you are displaying two separate fields. If you wanted to display one field that was over the fixed COBOL reference format (there is now a second variable length format on many platforms) see the language reference format since I don't recall the rules for continuing literals even though I used to do it. Clark Morris Due to text wrap, I cannot tell what the original line looked like. Could you post the original code above the compiler output? Do you have ending single quotes? -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
Thank you. I should have known better but I somehow pictured the folding taking place somewhere in the SMTP, listserve or receive process. No, it's a sender configuration issue. I just changed mine from 76 characters to 85. =COLS +1+2+3+4+5+6+7-- Charles -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Jon Butler Sent: Friday, July 17, 2015 4:30 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Not understanding COBOL diagnostic Charles, Point taken. However, it is possible to show an eighty byte record in this forum without wrapping: =COLS +1+2+3+4+5+6+7-- -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
Charles, Point taken. However, it is possible to show an eighty byte record in this forum without wrapping: =COLS +1+2+3+4+5+6+7-- Cheers, Jon. -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
As suggested, you should change your font when writing to the form so the entire error message and the lines to which it refers are shown as displayed on your 3270 emulator. I think the rules for COBOL continuation lines have been pretty well covered. I would add only that since you want to include an apostrophe [aka single quote (')] in your displays, you should use the quote () [aka double quote] as the all COBOL manuals show. DISPLAY Use the apostrophe to 'HIGHLIGHT' a word Be aware, the Compiler option QUOTE has no effect on the usage of either the apostrophe or quote mark in this case; it only tells the compiler the symbol to insert if you were to use the word QUOTE as a figurate constant, similar to the use of ZERO or SPACE. -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
I haven't played with COBOL in a long while, but is the leading apostrophe needed on the continuation line? Charles (Chuck) Hardee Senior Systems Engineer/Database Administration EAS Information Technology Thermo Fisher Scientific 300 Industry Drive | Pittsburgh, PA 15275 Phone +1 (724) 517-2633 | Mobile +1 (412) 877-2809 | FAX: +1 (412) 490-9230 chuck.har...@thermofisher.com | www.thermofisher.com WORLDWIDE CONFIDENTIALITY NOTE: Dissemination, distribution or copying of this e-mail or the information herein by anyone other than the intended recipient, or an employee or agent of a system responsible for delivering the message to the intended recipient, is prohibited. If you are not the intended recipient, please inform the sender and delete all copies. -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Charles Mills Sent: Thursday, July 16, 2015 10:07 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Not understanding COBOL diagnostic Can somebody humor me? I am not a COBOL programmer - I just sometimes find myself with a COBOL problem. I am getting the following diagnostics. What the heck is the compiler talking about? I see lots of blanks before column 23. I verified with HEX ON. 5136 1DISPLAY ' YOU HAVE ACTIVATED STATISTICS WITH EXPLAI 5137 1- ' BUT HAVE NOT CREATED THE PLAN_TABLE.' 5137== IGYPS0001-W A blank was missing before character ' in column 23. A bl assumed. 5138 1DISPLAY ' EXPLAIN HAS BEEN DEACTIVATED TO ALLOW THE 5139 1- ' PROGRAM TO RUN TO COMPLETION.' 5139== IGYPS0001-W A blank was missing before character ' in column 23. A bl assumed. Ditto for this one. Does anyone know what the correct syntax should be? 4401 1DISPLAY FUNCTION DISPLAY-OF(W-TRACE-DETAIL) 4402 1'CEX Stmt=SELECT DBNAME, DDLSPACENAME FROM ' 4403 1'PSRECTBLSPC WHERE RECNAME = ''' 4404 1 FUNCTION DISPLAY-OF(RECNAME OF W-RUNSTAT-INF 4405 1 4406 1'AND DBTYPE = ' 4407 1'(SELECT MAX(DBTYPE)' 4408 1' FROM PSRECTBLSPC' 4409 1' WHERE DBTYPE IN (' ','1 ')' 4409== IGYPS0001-W A blank was missing before character 1 in column 48. A bl assumed. Charles -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
Due to text wrap, I cannot tell what the original line looked like. Could you post the original code above the compiler output? Do you have ending single quotes? Have you reviewed the COBOL Programming/Language Guides? Are there double quotes and single quotes in the appropriate places? ' is single to me is double to me But I do not know which is coded ''' or ' is coded Fortunately these are warnings and should not affect the execution of your program. Lizette -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Charles Mills Sent: Thursday, July 16, 2015 7:07 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Not understanding COBOL diagnostic Can somebody humor me? I am not a COBOL programmer - I just sometimes find myself with a COBOL problem. I am getting the following diagnostics. What the heck is the compiler talking about? I see lots of blanks before column 23. I verified with HEX ON. 5136 1DISPLAY ' YOU HAVE ACTIVATED STATISTICS WITH EXPLAI 5137 1- ' BUT HAVE NOT CREATED THE PLAN_TABLE.' 5137== IGYPS0001-W A blank was missing before character ' in column 23. A bl assumed. 5138 1DISPLAY ' EXPLAIN HAS BEEN DEACTIVATED TO ALLOW THE 5139 1- ' PROGRAM TO RUN TO COMPLETION.' 5139== IGYPS0001-W A blank was missing before character ' in column 23. A bl assumed. Ditto for this one. Does anyone know what the correct syntax should be? 4401 1DISPLAY FUNCTION DISPLAY-OF(W-TRACE-DETAIL) 4402 1'CEX Stmt=SELECT DBNAME, DDLSPACENAME FROM ' 4403 1'PSRECTBLSPC WHERE RECNAME = ''' 4404 1 FUNCTION DISPLAY-OF(RECNAME OF W-RUNSTAT-INF 4405 1 4406 1'AND DBTYPE = ' 4407 1'(SELECT MAX(DBTYPE)' 4408 1' FROM PSRECTBLSPC' 4409 1' WHERE DBTYPE IN (' ','1 ')' 4409== IGYPS0001-W A blank was missing before character 1 in column 48. A bl assumed. Charles -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
Also note from the manual Enterprise COBOL for z/OS Language Reference Version 4 Release 2 SC23-8528-01: Any sentence, entry, clause, or phrase that requires more than one line can be continued in Area B of the next line that is neither a comment line nor a blank line. The line being continued is a continued line; the succeeding lines are continuation lines. Area A of a continuation line must be blank. If there is no hyphen (-) in the indicator area (column 7) of a line, the last character of the preceding line is assumed to be followed by a space. -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Lizette Koehler Sent: Thursday, July 16, 2015 7:24 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Not understanding COBOL diagnostic Due to text wrap, I cannot tell what the original line looked like. Could you post the original code above the compiler output? Do you have ending single quotes? Have you reviewed the COBOL Programming/Language Guides? Are there double quotes and single quotes in the appropriate places? ' is single to me is double to me But I do not know which is coded ''' or ' is coded Fortunately these are warnings and should not affect the execution of your program. Lizette -Original Message- From: IBM Mainframe Discussion List [mailto:IBM- m...@listserv.ua.edu] On Behalf Of Charles Mills Sent: Thursday, July 16, 2015 7:07 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Not understanding COBOL diagnostic Can somebody humor me? I am not a COBOL programmer - I just sometimes find myself with a COBOL problem. I am getting the following diagnostics. What the heck is the compiler talking about? I see lots of blanks before column 23. I verified with HEX ON. 5136 1DISPLAY ' YOU HAVE ACTIVATED STATISTICS WITH EXPLAI 5137 1- ' BUT HAVE NOT CREATED THE PLAN_TABLE.' 5137== IGYPS0001-W A blank was missing before character ' in column 23. A bl assumed. 5138 1DISPLAY ' EXPLAIN HAS BEEN DEACTIVATED TO ALLOW THE 5139 1- ' PROGRAM TO RUN TO COMPLETION.' 5139== IGYPS0001-W A blank was missing before character ' in column 23. A bl assumed. Ditto for this one. Does anyone know what the correct syntax should be? 4401 1DISPLAY FUNCTION DISPLAY-OF(W-TRACE-DETAIL) 4402 1'CEX Stmt=SELECT DBNAME, DDLSPACENAME FROM ' 4403 1'PSRECTBLSPC WHERE RECNAME = ''' 4404 1 FUNCTION DISPLAY-OF(RECNAME OF W-RUNSTAT-INF 4405 1 4406 1'AND DBTYPE = ' 4407 1'(SELECT MAX(DBTYPE)' 4408 1' FROM PSRECTBLSPC' 4409 1' WHERE DBTYPE IN (' ','1 ')' 4409== IGYPS0001-W A blank was missing before character 1 in column 48. A bl assumed. Charles -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Not understanding COBOL diagnostic
Can somebody humor me? I am not a COBOL programmer - I just sometimes find myself with a COBOL problem. I am getting the following diagnostics. What the heck is the compiler talking about? I see lots of blanks before column 23. I verified with HEX ON. 5136 1DISPLAY ' YOU HAVE ACTIVATED STATISTICS WITH EXPLAI 5137 1- ' BUT HAVE NOT CREATED THE PLAN_TABLE.' 5137== IGYPS0001-W A blank was missing before character ' in column 23. A bl assumed. 5138 1DISPLAY ' EXPLAIN HAS BEEN DEACTIVATED TO ALLOW THE 5139 1- ' PROGRAM TO RUN TO COMPLETION.' 5139== IGYPS0001-W A blank was missing before character ' in column 23. A bl assumed. Ditto for this one. Does anyone know what the correct syntax should be? 4401 1DISPLAY FUNCTION DISPLAY-OF(W-TRACE-DETAIL) 4402 1'CEX Stmt=SELECT DBNAME, DDLSPACENAME FROM ' 4403 1'PSRECTBLSPC WHERE RECNAME = ''' 4404 1 FUNCTION DISPLAY-OF(RECNAME OF W-RUNSTAT-INF 4405 1 4406 1'AND DBTYPE = ' 4407 1'(SELECT MAX(DBTYPE)' 4408 1' FROM PSRECTBLSPC' 4409 1' WHERE DBTYPE IN (' ','1 ')' 4409== IGYPS0001-W A blank was missing before character 1 in column 48. A bl assumed. Charles -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
And one last comment on COBOL coding structure COBOL source text must be written in COBOL reference format. Reference format consists of the following areas in a 72-character line: Sequence number area Columns 1 through 6 Indicator area Column 7 Area A Columns 8 through 11 Area B Columns 12 through 72 Lizette -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Lizette Koehler Sent: Thursday, July 16, 2015 7:35 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Not understanding COBOL diagnostic Also note from the manual Enterprise COBOL for z/OS Language Reference Version 4 Release 2 SC23-8528-01: Any sentence, entry, clause, or phrase that requires more than one line can be continued in Area B of the next line that is neither a comment line nor a blank line. The line being continued is a continued line; the succeeding lines are continuation lines. Area A of a continuation line must be blank. If there is no hyphen (-) in the indicator area (column 7) of a line, the last character of the preceding line is assumed to be followed by a space. -Original Message- From: IBM Mainframe Discussion List [mailto:IBM- m...@listserv.ua.edu] On Behalf Of Lizette Koehler Sent: Thursday, July 16, 2015 7:24 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Not understanding COBOL diagnostic Due to text wrap, I cannot tell what the original line looked like. Could you post the original code above the compiler output? Do you have ending single quotes? Have you reviewed the COBOL Programming/Language Guides? Are there double quotes and single quotes in the appropriate places? ' is single to me is double to me But I do not know which is coded ''' or ' is coded Fortunately these are warnings and should not affect the execution of your program. Lizette -Original Message- From: IBM Mainframe Discussion List [mailto:IBM- m...@listserv.ua.edu] On Behalf Of Charles Mills Sent: Thursday, July 16, 2015 7:07 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Not understanding COBOL diagnostic Can somebody humor me? I am not a COBOL programmer - I just sometimes find myself with a COBOL problem. I am getting the following diagnostics. What the heck is the compiler talking about? I see lots of blanks before column 23. I verified with HEX ON. 5136 1DISPLAY ' YOU HAVE ACTIVATED STATISTICS WITH EXPLAI 5137 1- ' BUT HAVE NOT CREATED THE PLAN_TABLE.' 5137== IGYPS0001-W A blank was missing before character ' in column 23. A bl assumed. 5138 1DISPLAY ' EXPLAIN HAS BEEN DEACTIVATED TO ALLOW THE 5139 1- ' PROGRAM TO RUN TO COMPLETION.' 5139== IGYPS0001-W A blank was missing before character ' in column 23. A bl assumed. Ditto for this one. Does anyone know what the correct syntax should be? 4401 1DISPLAY FUNCTION DISPLAY-OF(W-TRACE-DETAIL) 4402 1'CEX Stmt=SELECT DBNAME, DDLSPACENAME FROM ' 4403 1'PSRECTBLSPC WHERE RECNAME = ''' 4404 1 FUNCTION DISPLAY-OF(RECNAME OF W-RUNSTAT-INF 4405 1 4406 1'AND DBTYPE = ' 4407 1'(SELECT MAX(DBTYPE)' 4408 1' FROM PSRECTBLSPC' 4409 1' WHERE DBTYPE IN (' ','1 ')' 4409== IGYPS0001-W A blank was missing before character 1 in column 48. A bl assumed. Charles -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
Great suggestion. Done. (I use it for JCL and Rexx all the time but as I said, IANACP -- I am not a COBOL programmer.) Nothing jumps out at me however in the hilited COBOL. Charles -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Lizette Koehler Sent: Thursday, July 16, 2015 8:11 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Not understanding COBOL diagnostic One trick I use is to EDIT the COBOL program (or VIEW) in ISPF and the set the HILITE to COBOL. It sometimes helps to point out areas to review. -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
Bill, That is my preference too and also with that approach it truncates any trailing spaces on the first line and concatenates the content from second line as if it is a single line. But when you code continuation character the trailing blanks are left as is. Thanks, Kolusu IBM Mainframe Discussion List IBM-MAIN@LISTSERV.UA.EDU wrote on 07/16/2015 08:18:56 AM: From: Bill Ashton bill00ash...@gmail.com To: IBM-MAIN@LISTSERV.UA.EDU Date: 07/16/2015 08:19 AM Subject: Re: Not understanding COBOL diagnostic Sent by: IBM Mainframe Discussion List IBM-MAIN@LISTSERV.UA.EDU I find that it is much easier to break the text into multiple, quote-delimited lines, and not bother with the continuation stuff. For example the lines above in my world would be as you have them, but without the dash in Col 7. It makes it much easier to work with... On Thu, Jul 16, 2015 at 11:12 AM, Sri h Kolusu skol...@us.ibm.com wrote: Charles, Remove the closing single quote on the DISPLAY statement line and you won't see that message. Here are the rules If you want to continue a literal such that the continued lines and the continuation lines are part of one literal: Code a hyphen in the indicator area of each continuation line. Code the literal value using all columns of each continued line, up to and including column 72. (Do not terminate the continued lines with a single quotation mark followed by a space.) Code a quotation mark before the first character of the literal on each continuation line. Terminate the last continuation line with a single quotation mark followed by a space. http://www-01.ibm.com/support/knowledgecenter/SS6SG3_4.2.0/ com.ibm.entcobol.doc_4.2/PGandLR/ref/rlfmtcon.htm?lang=en Thanks, Kolusu IBM Mainframe Discussion List IBM-MAIN@LISTSERV.UA.EDU wrote on 07/16/2015 08:03:52 AM: From: Charles Mills charl...@mcn.org To: IBM-MAIN@LISTSERV.UA.EDU Date: 07/16/2015 08:06 AM Subject: Re: Not understanding COBOL diagnostic Sent by: IBM Mainframe Discussion List IBM-MAIN@LISTSERV.UA.EDU 1+2+3+4+5+6+7 DISPLAY ' YOU HAVE ACTIVATED STATISTICS WITH EXPLAIN' - ' BUT HAVE NOT CREATED THE PLAN_TABLE.' DISPLAY ' EXPLAIN HAS BEEN DEACTIVATED TO ALLOW THE' - ' PROGRAM TO RUN TO COMPLETION.' DISPLAY ' PLEASE CREATE THE PLAN_TABLE AND RESUBMIT' - ' THE PROGRAM FOR EXPLAIN INFORMATION.' Charles -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU ] On Behalf Of Lizette Koehler Sent: Thursday, July 16, 2015 7:24 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Not understanding COBOL diagnostic Due to text wrap, I cannot tell what the original line looked like. Could you post the original code above the compiler output? Do you have ending single quotes? -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN -- Thank you and best regards, *Billy Ashton* -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
Thanks everyone for your help on the first diagnostic. How about the second one? Charles -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Charles Mills Sent: Thursday, July 16, 2015 7:07 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Not understanding COBOL diagnostic Can somebody humor me? I am not a COBOL programmer - I just sometimes find myself with a COBOL problem. snip Ditto for this one. Does anyone know what the correct syntax should be? 4401 1DISPLAY FUNCTION DISPLAY-OF(W-TRACE-DETAIL) 4402 1'CEX Stmt=SELECT DBNAME, DDLSPACENAME 4403 1'PSRECTBLSPC WHERE RECNAME = ''' 4404 1 FUNCTION DISPLAY-OF(RECNAME OF 4405 1 4406 1'AND DBTYPE = ' 4407 1'(SELECT MAX(DBTYPE)' 4408 1' FROM PSRECTBLSPC' 4409 1' WHERE DBTYPE IN (' ','1 ')' 4409== IGYPS0001-W A blank was missing before character 1 in column 48. -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
It looks to me like a right parenthesis was pushed beyond column 72. I reformatted your program listing from your original post to get these lines: DISPLAY FUNCTION DISPLAY-OF(W-TRACE-DETAIL) 'CEX STMT=SELECT DBNAME, DDLSPACENAME FROM ' 'PSRECTBLSPC WHERE RECNAME = ''' FUNCTION DISPLAY-OF(RECNAME OF W-RUNSTAT-INF 'AND DBTYPE = ' '(SELECT MAX(DBTYPE)' ' FROM PSRECTBLSPC' ' WHERE DBTYPE IN (' ','1 ')' Note the missing right parenthesis on the fourth line. The compiler will do this in the listing, which shows you where truncation at column 72 has occurred. With HILITE COBOL (or HILITE AUTO) the missing right parenthesis should show up in a different color from the rest of that line. HTH PEter -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Charles Mills Sent: Thursday, July 16, 2015 11:23 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Not understanding COBOL diagnostic Thanks everyone for your help on the first diagnostic. How about the second one? Charles -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Charles Mills Sent: Thursday, July 16, 2015 7:07 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Not understanding COBOL diagnostic Can somebody humor me? I am not a COBOL programmer - I just sometimes find myself with a COBOL problem. snip Ditto for this one. Does anyone know what the correct syntax should be? 4401 1DISPLAY FUNCTION DISPLAY-OF(W-TRACE-DETAIL) 4402 1'CEX Stmt=SELECT DBNAME, DDLSPACENAME 4403 1'PSRECTBLSPC WHERE RECNAME = ''' 4404 1 FUNCTION DISPLAY-OF(RECNAME OF 4405 1 4406 1'AND DBTYPE = ' 4407 1'(SELECT MAX(DBTYPE)' 4408 1' FROM PSRECTBLSPC' 4409 1' WHERE DBTYPE IN (' ','1 ')' 4409== IGYPS0001-W A blank was missing before character 1 in column 48. -- This message and any attachments are intended only for the use of the addressee and may contain information that is privileged and confidential. If the reader of the message is not the intended recipient or an authorized representative of the intended recipient, you are hereby notified that any dissemination of this communication is strictly prohibited. If you have received this communication in error, please notify us immediately by e-mail and delete the message and any attachments from your system. -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
Perfect! Thanks, Charles -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Sri h Kolusu Sent: Thursday, July 16, 2015 8:12 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Not understanding COBOL diagnostic Charles, Remove the closing single quote on the DISPLAY statement line and you won't see that message. -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
1+2+3+4+5+6+7 DISPLAY ' YOU HAVE ACTIVATED STATISTICS WITH EXPLAIN' - ' BUT HAVE NOT CREATED THE PLAN_TABLE.' DISPLAY ' EXPLAIN HAS BEEN DEACTIVATED TO ALLOW THE' - ' PROGRAM TO RUN TO COMPLETION.' DISPLAY ' PLEASE CREATE THE PLAN_TABLE AND RESUBMIT' - ' THE PROGRAM FOR EXPLAIN INFORMATION.' Charles -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Lizette Koehler Sent: Thursday, July 16, 2015 7:24 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Not understanding COBOL diagnostic Due to text wrap, I cannot tell what the original line looked like. Could you post the original code above the compiler output? Do you have ending single quotes? -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
One trick I use is to EDIT the COBOL program (or VIEW) in ISPF and the set the HILITE to COBOL. It sometimes helps to point out areas to review. Lizette -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Charles Mills Sent: Thursday, July 16, 2015 8:04 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Not understanding COBOL diagnostic 1+2+3+4+5+6+7 DISPLAY ' YOU HAVE ACTIVATED STATISTICS WITH EXPLAIN' - ' BUT HAVE NOT CREATED THE PLAN_TABLE.' DISPLAY ' EXPLAIN HAS BEEN DEACTIVATED TO ALLOW THE' - ' PROGRAM TO RUN TO COMPLETION.' DISPLAY ' PLEASE CREATE THE PLAN_TABLE AND RESUBMIT' - ' THE PROGRAM FOR EXPLAIN INFORMATION.' Charles -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Lizette Koehler Sent: Thursday, July 16, 2015 7:24 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Not understanding COBOL diagnostic Due to text wrap, I cannot tell what the original line looked like. Could you post the original code above the compiler output? Do you have ending single quotes? -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
Charles, Remove the closing single quote on the DISPLAY statement line and you won't see that message. Here are the rules If you want to continue a literal such that the continued lines and the continuation lines are part of one literal: Code a hyphen in the indicator area of each continuation line. Code the literal value using all columns of each continued line, up to and including column 72. (Do not terminate the continued lines with a single quotation mark followed by a space.) Code a quotation mark before the first character of the literal on each continuation line. Terminate the last continuation line with a single quotation mark followed by a space. http://www-01.ibm.com/support/knowledgecenter/SS6SG3_4.2.0/com.ibm.entcobol.doc_4.2/PGandLR/ref/rlfmtcon.htm?lang=en Thanks, Kolusu IBM Mainframe Discussion List IBM-MAIN@LISTSERV.UA.EDU wrote on 07/16/2015 08:03:52 AM: From: Charles Mills charl...@mcn.org To: IBM-MAIN@LISTSERV.UA.EDU Date: 07/16/2015 08:06 AM Subject: Re: Not understanding COBOL diagnostic Sent by: IBM Mainframe Discussion List IBM-MAIN@LISTSERV.UA.EDU 1+2+3+4+5+6+7 DISPLAY ' YOU HAVE ACTIVATED STATISTICS WITH EXPLAIN' - ' BUT HAVE NOT CREATED THE PLAN_TABLE.' DISPLAY ' EXPLAIN HAS BEEN DEACTIVATED TO ALLOW THE' - ' PROGRAM TO RUN TO COMPLETION.' DISPLAY ' PLEASE CREATE THE PLAN_TABLE AND RESUBMIT' - ' THE PROGRAM FOR EXPLAIN INFORMATION.' Charles -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Lizette Koehler Sent: Thursday, July 16, 2015 7:24 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Not understanding COBOL diagnostic Due to text wrap, I cannot tell what the original line looked like. Could you post the original code above the compiler output? Do you have ending single quotes? -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
I thought one of them had to be left out but I couldn't remember which one. Looks like I guessed at the wrong one. Charles (Chuck) Hardee Senior Systems Engineer/Database Administration EAS Information Technology Thermo Fisher Scientific 300 Industry Drive | Pittsburgh, PA 15275 Phone +1 (724) 517-2633 | Mobile +1 (412) 877-2809 | FAX: +1 (412) 490-9230 chuck.har...@thermofisher.com | www.thermofisher.com WORLDWIDE CONFIDENTIALITY NOTE: Dissemination, distribution or copying of this e-mail or the information herein by anyone other than the intended recipient, or an employee or agent of a system responsible for delivering the message to the intended recipient, is prohibited. If you are not the intended recipient, please inform the sender and delete all copies. -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Sri h Kolusu Sent: Thursday, July 16, 2015 11:12 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Not understanding COBOL diagnostic Charles, Remove the closing single quote on the DISPLAY statement line and you won't see that message. Here are the rules If you want to continue a literal such that the continued lines and the continuation lines are part of one literal: Code a hyphen in the indicator area of each continuation line. Code the literal value using all columns of each continued line, up to and including column 72. (Do not terminate the continued lines with a single quotation mark followed by a space.) Code a quotation mark before the first character of the literal on each continuation line. Terminate the last continuation line with a single quotation mark followed by a space. http://www-01.ibm.com/support/knowledgecenter/SS6SG3_4.2.0/com.ibm.entcobol.doc_4.2/PGandLR/ref/rlfmtcon.htm?lang=en Thanks, Kolusu IBM Mainframe Discussion List IBM-MAIN@LISTSERV.UA.EDU wrote on 07/16/2015 08:03:52 AM: From: Charles Mills charl...@mcn.org To: IBM-MAIN@LISTSERV.UA.EDU Date: 07/16/2015 08:06 AM Subject: Re: Not understanding COBOL diagnostic Sent by: IBM Mainframe Discussion List IBM-MAIN@LISTSERV.UA.EDU 1+2+3+4+5+6+7 DISPLAY ' YOU HAVE ACTIVATED STATISTICS WITH EXPLAIN' - ' BUT HAVE NOT CREATED THE PLAN_TABLE.' DISPLAY ' EXPLAIN HAS BEEN DEACTIVATED TO ALLOW THE' - ' PROGRAM TO RUN TO COMPLETION.' DISPLAY ' PLEASE CREATE THE PLAN_TABLE AND RESUBMIT' - ' THE PROGRAM FOR EXPLAIN INFORMATION.' Charles -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Lizette Koehler Sent: Thursday, July 16, 2015 7:24 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Not understanding COBOL diagnostic Due to text wrap, I cannot tell what the original line looked like. Could you post the original code above the compiler output? Do you have ending single quotes? -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
You can do it just as the programmer coded it by just removing the hyphen in column 7 of the continuation lines. I do this all the time. 1+2+3+4+5+6+7 DISPLAY ' YOU HAVE ACTIVATED STATISTICS WITH EXPLAIN' ' BUT HAVE NOT CREATED THE PLAN_TABLE.' DISPLAY ' EXPLAIN HAS BEEN DEACTIVATED TO ALLOW THE' ' PROGRAM TO RUN TO COMPLETION.' DISPLAY ' PLEASE CREATE THE PLAN_TABLE AND RESUBMIT' ' THE PROGRAM FOR EXPLAIN INFORMATION.' HTH Peter -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Charles Mills Sent: Thursday, July 16, 2015 11:21 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Not understanding COBOL diagnostic So then I have to run the text out to column 72? Kind of ugly. Can't split it logically like this programmer (not me!) has? Charles -- This message and any attachments are intended only for the use of the addressee and may contain information that is privileged and confidential. If the reader of the message is not the intended recipient or an authorized representative of the intended recipient, you are hereby notified that any dissemination of this communication is strictly prohibited. If you have received this communication in error, please notify us immediately by e-mail and delete the message and any attachments from your system. -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
On Thu, Jul 16, 2015 at 10:23 AM, Charles Mills charl...@mcn.org wrote: Thanks everyone for your help on the first diagnostic. How about the second one? Charles deleted 4408 1' FROM PSRECTBLSPC' 4409 1' WHERE DBTYPE IN (' ','1 ')' 4409== IGYPS0001-W A blank was missing before character 1 in column 48. To get a single quote within a single quoted string, use two single quotes. 'IN ('' '',''1 '')' -- Mike A Schwab, Springfield IL USA Where do Forest Rangers go to get away from it all? -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
Charles, If you need single quotes then enclose them in double quotes WHERE DBTYPE IN (' ','1 ') or if you want to go with single quote route then you need to enclose them in another single quote like this ( I have broken down individual pieces so that it is easier to understand) ' WHERE DBTYPE IN (''' ' ' ',' '1 ' ')' Thanks, Kolusu From: Charles Mills charl...@mcn.org To: IBM-MAIN@LISTSERV.UA.EDU Date: 07/16/2015 08:23 AM Subject:Re: Not understanding COBOL diagnostic Sent by:IBM Mainframe Discussion List IBM-MAIN@LISTSERV.UA.EDU Thanks everyone for your help on the first diagnostic. How about the second one? Charles -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Charles Mills Sent: Thursday, July 16, 2015 7:07 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Not understanding COBOL diagnostic Can somebody humor me? I am not a COBOL programmer - I just sometimes find myself with a COBOL problem. snip Ditto for this one. Does anyone know what the correct syntax should be? 4401 1DISPLAY FUNCTION DISPLAY-OF(W-TRACE-DETAIL) 4402 1'CEX Stmt=SELECT DBNAME, DDLSPACENAME 4403 1'PSRECTBLSPC WHERE RECNAME = ''' 4404 1 FUNCTION DISPLAY-OF(RECNAME OF 4405 1 4406 1'AND DBTYPE = ' 4407 1'(SELECT MAX(DBTYPE)' 4408 1' FROM PSRECTBLSPC' 4409 1' WHERE DBTYPE IN (' ','1 ')' 4409== IGYPS0001-W A blank was missing before character 1 in column 48. -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
I find that it is much easier to break the text into multiple, quote-delimited lines, and not bother with the continuation stuff. For example the lines above in my world would be as you have them, but without the dash in Col 7. It makes it much easier to work with... On Thu, Jul 16, 2015 at 11:12 AM, Sri h Kolusu skol...@us.ibm.com wrote: Charles, Remove the closing single quote on the DISPLAY statement line and you won't see that message. Here are the rules If you want to continue a literal such that the continued lines and the continuation lines are part of one literal: Code a hyphen in the indicator area of each continuation line. Code the literal value using all columns of each continued line, up to and including column 72. (Do not terminate the continued lines with a single quotation mark followed by a space.) Code a quotation mark before the first character of the literal on each continuation line. Terminate the last continuation line with a single quotation mark followed by a space. http://www-01.ibm.com/support/knowledgecenter/SS6SG3_4.2.0/com.ibm.entcobol.doc_4.2/PGandLR/ref/rlfmtcon.htm?lang=en Thanks, Kolusu IBM Mainframe Discussion List IBM-MAIN@LISTSERV.UA.EDU wrote on 07/16/2015 08:03:52 AM: From: Charles Mills charl...@mcn.org To: IBM-MAIN@LISTSERV.UA.EDU Date: 07/16/2015 08:06 AM Subject: Re: Not understanding COBOL diagnostic Sent by: IBM Mainframe Discussion List IBM-MAIN@LISTSERV.UA.EDU 1+2+3+4+5+6+7 DISPLAY ' YOU HAVE ACTIVATED STATISTICS WITH EXPLAIN' - ' BUT HAVE NOT CREATED THE PLAN_TABLE.' DISPLAY ' EXPLAIN HAS BEEN DEACTIVATED TO ALLOW THE' - ' PROGRAM TO RUN TO COMPLETION.' DISPLAY ' PLEASE CREATE THE PLAN_TABLE AND RESUBMIT' - ' THE PROGRAM FOR EXPLAIN INFORMATION.' Charles -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Lizette Koehler Sent: Thursday, July 16, 2015 7:24 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Not understanding COBOL diagnostic Due to text wrap, I cannot tell what the original line looked like. Could you post the original code above the compiler output? Do you have ending single quotes? -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN -- Thank you and best regards, *Billy Ashton* -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
So then I have to run the text out to column 72? Kind of ugly. Can't split it logically like this programmer (not me!) has? Charles -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Sri h Kolusu Sent: Thursday, July 16, 2015 8:12 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Not understanding COBOL diagnostic Charles, Remove the closing single quote on the DISPLAY statement line and you won't see that message. Here are the rules If you want to continue a literal such that the continued lines and the continuation lines are part of one literal: Code a hyphen in the indicator area of each continuation line. Code the literal value using all columns of each continued line, up to and including column 72. (Do not terminate the continued lines with a single quotation mark followed by a space.) Code a quotation mark before the first character of the literal on each continuation line. Terminate the last continuation line with a single quotation mark followed by a space. http://www-01.ibm.com/support/knowledgecenter/SS6SG3_4.2.0/com.ibm.entcobol. doc_4.2/PGandLR/ref/rlfmtcon.htm?lang=en Thanks, Kolusu IBM Mainframe Discussion List IBM-MAIN@LISTSERV.UA.EDU wrote on 07/16/2015 08:03:52 AM: From: Charles Mills charl...@mcn.org To: IBM-MAIN@LISTSERV.UA.EDU Date: 07/16/2015 08:06 AM Subject: Re: Not understanding COBOL diagnostic Sent by: IBM Mainframe Discussion List IBM-MAIN@LISTSERV.UA.EDU 1+2+3+4+5+6+7 DISPLAY ' YOU HAVE ACTIVATED STATISTICS WITH EXPLAIN' - ' BUT HAVE NOT CREATED THE PLAN_TABLE.' DISPLAY ' EXPLAIN HAS BEEN DEACTIVATED TO ALLOW THE' - ' PROGRAM TO RUN TO COMPLETION.' DISPLAY ' PLEASE CREATE THE PLAN_TABLE AND RESUBMIT' - ' THE PROGRAM FOR EXPLAIN INFORMATION.' -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
Due to wrapping, I'm not sure what you are seeing. An example of a continued string literal is on: http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/IGY3LR31/1.6.4.2.1 But, honestly, I _never_ do that in a DISPLAY. Because I can just do: DISPLAY 'THE FIRST PART OF A VERY LONG ' 'SENTENCE WHICH GOES ACROSS ' 'A LOT OF LINES.' UPON SYSOUT On Thu, Jul 16, 2015 at 9:06 AM, Charles Mills charl...@mcn.org wrote: Can somebody humor me? I am not a COBOL programmer - I just sometimes find myself with a COBOL problem. I am getting the following diagnostics. What the heck is the compiler talking about? I see lots of blanks before column 23. I verified with HEX ON. 5136 1DISPLAY ' YOU HAVE ACTIVATED STATISTICS WITH EXPLAI 5137 1- ' BUT HAVE NOT CREATED THE PLAN_TABLE.' 5137== IGYPS0001-W A blank was missing before character ' in column 23. A bl assumed. 5138 1DISPLAY ' EXPLAIN HAS BEEN DEACTIVATED TO ALLOW THE 5139 1- ' PROGRAM TO RUN TO COMPLETION.' 5139== IGYPS0001-W A blank was missing before character ' in column 23. A bl assumed. Ditto for this one. Does anyone know what the correct syntax should be? 4401 1DISPLAY FUNCTION DISPLAY-OF(W-TRACE-DETAIL) 4402 1'CEX Stmt=SELECT DBNAME, DDLSPACENAME FROM ' 4403 1'PSRECTBLSPC WHERE RECNAME = ''' 4404 1 FUNCTION DISPLAY-OF(RECNAME OF W-RUNSTAT-INF 4405 1 4406 1'AND DBTYPE = ' 4407 1'(SELECT MAX(DBTYPE)' 4408 1' FROM PSRECTBLSPC' 4409 1' WHERE DBTYPE IN (' ','1 ')' 4409== IGYPS0001-W A blank was missing before character 1 in column 48. A bl assumed. Charles -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN -- Schrodinger's backup: The condition of any backup is unknown until a restore is attempted. Yoda of Borg, we are. Futile, resistance is, yes. Assimilated, you will be. He's about as useful as a wax frying pan. 10 to the 12th power microphones = 1 Megaphone Maranatha! John McKown -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
Right. I think I'm good. Charles -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Lizette Koehler Sent: Thursday, July 16, 2015 9:24 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Not understanding COBOL diagnostic For ISPF Hilite, it is better to just enter HILITE on the command line. Then when the panel pops up, select COBOL then 3 (Color Both IF and DO) and / (Parentheses matching) in the next two entries. -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
Ha! RC=0. Thanks, all. Charles -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Farley, Peter x23353 Sent: Thursday, July 16, 2015 9:09 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Not understanding COBOL diagnostic I was wrong, see Sri Kolusu's response, he saw it before I did. It is this line giving you headaches: ' WHERE DBTYPE IN (' ','1 ')' The quotes inside of the parentheses should all be doubled. -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
It is a display statement simulating a DB2 Select Query. On Thu, Jul 16, 2015 at 10:54 AM, Charles Mills charl...@mcn.org wrote: I don't have a clue what kind of a statement or function this is. (INACP) There is nothing in columns 73 to 80. I agree there seems to be a missing right parenthesis. The HILITE is seeing it mostly as literal strings and so is not doing much to help. Hope this survives and does not fold. Wish I could paste the colors. +2+3+4+5+6+7+8 DISPLAY FUNCTION DISPLAY-OF(W-TRACE-DETAIL) No quotes (variable). OK. 'CEX Stmt=SELECT DBNAME, DDLSPACENAME FROM ' Beginning and ending quotes. OK. 'PSRECTBLSPC WHERE RECNAME = ''' Quote doubled and beginning and ending quotes. OK. FUNCTION DISPLAY-OF(RECNAME OF W-RUNSTAT-INFO) No quotes (variable). OK. Quotes doubled and beginning and ending quotes. OK. 'AND DBTYPE = ' Beginning and ending quotes. OK. '(SELECT MAX(DBTYPE)' Beginning and ending quotes. OK. ' FROM PSRECTBLSPC' Beginning and ending quotes. OK. ' WHERE DBTYPE IN (' ','1 ')' Beginning and ending quotes. OK. IMBEDED QUOTES NOT DOUBLED. Blank after 1 not needed (short literals will be padded with blanks). You need: ' WHERE DBTYPE IN ('' '',''1'')' 'AND RECNAME = ''' Quote doubled and beginning and ending quotes. OK. FUNCTION DISPLAY-OF(RECNAME OF W-RUNSTAT-INFO) No quotes (variable). OK. Quote doubled and beginning and ending quotes. OK. Charles -- Mike A Schwab, Springfield IL USA Where do Forest Rangers go to get away from it all? -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
I don't have a clue what kind of a statement or function this is. (INACP) There is nothing in columns 73 to 80. I agree there seems to be a missing right parenthesis. The HILITE is seeing it mostly as literal strings and so is not doing much to help. Hope this survives and does not fold. Wish I could paste the colors. +2+3+4+5+6+7+8 DISPLAY FUNCTION DISPLAY-OF(W-TRACE-DETAIL) 'CEX Stmt=SELECT DBNAME, DDLSPACENAME FROM ' 'PSRECTBLSPC WHERE RECNAME = ''' FUNCTION DISPLAY-OF(RECNAME OF W-RUNSTAT-INFO) 'AND DBTYPE = ' '(SELECT MAX(DBTYPE)' ' FROM PSRECTBLSPC' ' WHERE DBTYPE IN (' ','1 ')' 'AND RECNAME = ''' FUNCTION DISPLAY-OF(RECNAME OF W-RUNSTAT-INFO) Charles -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Farley, Peter x23353 Sent: Thursday, July 16, 2015 8:36 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Not understanding COBOL diagnostic It looks to me like a right parenthesis was pushed beyond column 72. I reformatted your program listing from your original post to get these lines: DISPLAY FUNCTION DISPLAY-OF(W-TRACE-DETAIL) 'CEX STMT=SELECT DBNAME, DDLSPACENAME FROM ' 'PSRECTBLSPC WHERE RECNAME = ''' FUNCTION DISPLAY-OF(RECNAME OF W-RUNSTAT-INF 'AND DBTYPE = ' '(SELECT MAX(DBTYPE)' ' FROM PSRECTBLSPC' ' WHERE DBTYPE IN (' ','1 ')' Note the missing right parenthesis on the fourth line. The compiler will do this in the listing, which shows you where truncation at column 72 has occurred. With HILITE COBOL (or HILITE AUTO) the missing right parenthesis should show up in a different color from the rest of that line. -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
I was wrong, see Sri Kolusu's response, he saw it before I did. It is this line giving you headaches: ' WHERE DBTYPE IN (' ','1 ')' The quotes inside of the parentheses should all be doubled. HTH Peter -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Charles Mills Sent: Thursday, July 16, 2015 11:54 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Not understanding COBOL diagnostic I don't have a clue what kind of a statement or function this is. (INACP) There is nothing in columns 73 to 80. I agree there seems to be a missing right parenthesis. The HILITE is seeing it mostly as literal strings and so is not doing much to help. Hope this survives and does not fold. Wish I could paste the colors. +2+3+4+5+6+7+8 DISPLAY FUNCTION DISPLAY-OF(W-TRACE-DETAIL) 'CEX Stmt=SELECT DBNAME, DDLSPACENAME FROM ' 'PSRECTBLSPC WHERE RECNAME = ''' FUNCTION DISPLAY-OF(RECNAME OF W-RUNSTAT-INFO) 'AND DBTYPE = ' '(SELECT MAX(DBTYPE)' ' FROM PSRECTBLSPC' ' WHERE DBTYPE IN (' ','1 ')' 'AND RECNAME = ''' FUNCTION DISPLAY-OF(RECNAME OF W-RUNSTAT-INFO) Charles -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Farley, Peter x23353 Sent: Thursday, July 16, 2015 8:36 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Not understanding COBOL diagnostic It looks to me like a right parenthesis was pushed beyond column 72. I reformatted your program listing from your original post to get these lines: DISPLAY FUNCTION DISPLAY-OF(W-TRACE-DETAIL) 'CEX STMT=SELECT DBNAME, DDLSPACENAME FROM ' 'PSRECTBLSPC WHERE RECNAME = ''' FUNCTION DISPLAY-OF(RECNAME OF W-RUNSTAT-INF 'AND DBTYPE = ' '(SELECT MAX(DBTYPE)' ' FROM PSRECTBLSPC' ' WHERE DBTYPE IN (' ','1 ')' Note the missing right parenthesis on the fourth line. The compiler will do this in the listing, which shows you where truncation at column 72 has occurred. With HILITE COBOL (or HILITE AUTO) the missing right parenthesis should show up in a different color from the rest of that line. -- This message and any attachments are intended only for the use of the addressee and may contain information that is privileged and confidential. If the reader of the message is not the intended recipient or an authorized representative of the intended recipient, you are hereby notified that any dissemination of this communication is strictly prohibited. If you have received this communication in error, please notify us immediately by e-mail and delete the message and any attachments from your system. -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: Not understanding COBOL diagnostic
For ISPF Hilite, it is better to just enter HILITE on the command line. Then when the panel pops up, select COBOL then 3 (Color Both IF and DO) and / (Parentheses matching) in the next two entries. It might help provide more details. ┌─┐ │ File Languages Colors Help │ ── │Edit Color Settings │ │ │ More: + │ Language: 11. Automatic Coloring: 3 1. Do not color program │2. Assembler 2. Color program │3. BookMaster 3. Both IF and DO logic │4. C 4. DO logic only │5. COBOL 5. IF logic only │6. HTML │7. IDL Enter / to select option │8. ISPF DTL Parentheses matching - │9. ISPF Panel/ Highlight FIND strings │ 10. ISPF Skeleton / Highlight cursor phrase │ 11. JCL │ 12. Pascal Note: Information from this panel is │ 13. PL/I saved in the edit profile. │ Command === │ F1=HelpF2=Split F3=ExitF7=BackwardF8=Forward │ F9=Swap F10=ActionsF12=Cancel └─┘ Lizette -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Mike Schwab Sent: Thursday, July 16, 2015 9:16 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Not understanding COBOL diagnostic It is a display statement simulating a DB2 Select Query. On Thu, Jul 16, 2015 at 10:54 AM, Charles Mills charl...@mcn.org wrote: I don't have a clue what kind of a statement or function this is. (INACP) There is nothing in columns 73 to 80. I agree there seems to be a missing right parenthesis. The HILITE is seeing it mostly as literal strings and so is not doing much to help. Hope this survives and does not fold. Wish I could paste the colors. +2+3+4+5+6+7+8 DISPLAY FUNCTION DISPLAY-OF(W-TRACE-DETAIL) No quotes (variable). OK. 'CEX Stmt=SELECT DBNAME, DDLSPACENAME FROM ' Beginning and ending quotes. OK. 'PSRECTBLSPC WHERE RECNAME = ''' Quote doubled and beginning and ending quotes. OK. FUNCTION DISPLAY-OF(RECNAME OF W-RUNSTAT-INFO) No quotes (variable). OK. Quotes doubled and beginning and ending quotes. OK. 'AND DBTYPE = ' Beginning and ending quotes. OK. '(SELECT MAX(DBTYPE)' Beginning and ending quotes. OK. ' FROM PSRECTBLSPC' Beginning and ending quotes. OK. ' WHERE DBTYPE IN (' ','1 ')' Beginning and ending quotes. OK. IMBEDED QUOTES NOT DOUBLED. Blank after 1 not needed (short literals will be padded with blanks). You need: ' WHERE DBTYPE IN ('' '',''1'')' 'AND RECNAME = ''' Quote doubled and beginning and ending quotes. OK. FUNCTION DISPLAY-OF(RECNAME OF W-RUNSTAT-INFO) No quotes (variable). OK. Quote doubled and beginning and ending quotes. OK. Charles -- Mike A Schwab, Springfield IL USA Where do Forest Rangers go
Re: Not understanding COBOL diagnostic
Changing your font has AFAIK *zero* effect on the appearance of IBMMAIN emails as received. They are in plain UTF-8 format and fonts are an artifact of HTML format. I did not write the program. IANACP. Charles -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Jon Butler Sent: Thursday, July 16, 2015 11:00 AM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Not understanding COBOL diagnostic As suggested, you should change your font when writing to the form so the entire error message and the lines to which it refers are shown as displayed on your 3270 emulator. I think the rules for COBOL continuation lines have been pretty well covered. I would add only that since you want to include an apostrophe [aka single quote (')] in your displays, you should use the quote () [aka double quote] as the all COBOL manuals show. -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN