Browse all forums dedicated to the Rocket® COBOL product family.
Recently active
Problem: Message comes from linker (ld) command near end of cob -x or cob -z Resolution: It is not possible to link 32 bit objects to 64 bit code and vice-versa. Make sure all dependent modules are compiled under the same COBMODE setting. Make sure any compiled Cobol code is consistent with any object modules supplied by a third party. Old KB# 7167
Problem: Cannot load CMDLINE.SAV Resolution: If the COBDATA environment variable is set, this error can be resolved by unsetting COBDATA or adding a colon (:) to the end of the contents of the COBDATA variable. Old KB# 7182
Problem: cob64: bad magic number error when linking application cob32: bad magic number error when linking application Resolution: When using COBOL in conjunction with third party software, ensure that the COBOL working mode matches the environment settings for the third party software. For example, Oracle installations on UNIX typically provide both 32-bit and 64-bit shared objects in $ORACLE_HOME/lib and $ORACLE_HOME/lib64 . You would therefore need to ensure that LIBPATH/LD_LIBRARY_PATH/SHLIB_PATH was set correctly. See Knowledge Base article #22062 for further details. Old KB# 7183
Problem: Dialog System screensets are not found or loaded at run time Resolution: In order to use directories other than the directory containing the application program, the user needs to set COBDATA to point to the location containing the screensets - ie Dialog system treats the screenset files as data files to be read when the screenset is initialized. COPYFILES can be placed in other directories and the COBCPY variable is used to point to the locations to be searched by the COBOL compiler and Animator Old KB# 7164
Problem: Compiler errors reported becuase of * in first 6 columns of the source program Resolution: An asterick in column is treated as a comment compile using the directive NOMFCOMMENT Old KB# 7160
Problem: /usr/lib/cmplrs/cc/ld: Can't locate file for: -lclntst8 Just upgraded from Oracle 8 to Oracle 9 and trying to compile program with embedded Oracle SQL Resolution: The system loader (ld) is looking for libclntst8.so in $ORACLE_HOME/lib. The client-side library has a different name for each major release of Oracle, i.e. libclntst8.*, libclntst9.*, libclntst10.*. Update the cob command line accordingly for the Oracle client version in use. Old KB# 7210
Problem: Adis error messages are displayed at line 24 in Animator, Resolution: Issue caused by the fact that the Animator uses the MFDEBUG terminal description entry and this entry contains the definitions LINES=#24 this then limits the usable screen to 24 lines. This is not a defect and is documented as follows: Here is the information extracted from the Server Express documents; 2.2.6 Specifying Screen Size for Screen-swapping When Animator executes a program, the program might need to use the terminal for input and output. If you only have access to a single terminal, and both Animator and the executing program need access to it, Animator keeps a virtual image of the program's output in the background. This image is displayed, and Animator swapped to the background if you press F2=View, or if Animator itself displays the program's output (during Step or Zoom operations, for example). By default, the size of this virt
Problem: Using byte stream file handling and cbl_read_file is not returning any data. Return-code = 0 on the cbl_open_file and receives Return_Code = 0 on the cbl_read_file but no data is received into his input buffer- Resolution: One of the parameters for the cbl_read_file is flags. This parameter can take the following values: 0 Standard read 128 Return the current file size in file-offset Need to make sure after the initial read to obtain the size of the file that the flags is set to 0 to do a standard read. Setting the flags to 0 resolved the no data returned in the input buffer issue. Old KB# 7148
Problem: In the course of Cobol program execution, it would be desirable to issue a command to the Unix shell for processing and to work with the command's output. Is it possible. Resolution: The procedure division statement is: CALL 'SYSTEM' USING MY-COMMAND. where MY-COMMAND is: 01 MY-COMMAND. 10 MY-COMMAND-LINE PIC X(2048). 10 FILLER PIC X VALUE LOW-VALUES. MY-COMMAND-LINE may contain any valid system command line, e.g. ls -l > lsout.txt It is recommended that command output be redirected to a file if the Cobol program needs a
Problem: When Animator is invoked, the screen clears, some escape sequences are written including a 'bell' (this can be captured by redirecting stdout and stderr) then the process immediately exits back to the command prompt instead of animating as it should. This happens for all programs including the most simple "hello world" program (use $COBDIR/demo/debug/tictac.cbl to demonstrate). It occurs no matter how animator is invoked, including: regular "anim" From within tbox cross-session with "animsrv" cross-session with dynamic attachment CBL_DEBUGBREAK COBSW= A Animator is the only feature that's broken: tbox and dfed work fine, and any program can be compiled successfully and will execute successfully, as long as animator is not used. The COBDIR, LD_LIBRARY_PATH, and PATH environment variables are set correctly. The LMF and ASLMF licensing systems are working correct
Problem: When trying to update the Net Express product it states that the DSY (Dialog System) Websync cannot be run because Dialog System is not installed. Resolution: During the initial install of Net Express if "Custom install" was not choosen, then the Dialog System option does not install. The installation CD can be reinserted and run again - choose custom and it will determine which components have not been installed and let you choose them. After installation is complete the websync can be run again. Old KB# 7146
Problem: If you are linking a Cobsql application with the Cobsql CSTOP option specified, the following error will be returned : ld: 0711-317 ERROR: Undefined symbol: .oraprot Resolution: The CSTART and CSTOP Cobsql directives are not supported on UNIX. More recent versions of Server Express will reject these options at compile-time. Old KB# 7204
Problem: What is the 'mfdebug' terminal setting? Resolution: When running under the control of the Animator any screen output is cached in memory. If you swap to the user screen (i.e. by pressing F2 or by executing an ACCEPT), the contents of the cached screen are displayed. The program has no terminal of its own because it's under the control of the animator. So, when the program writes to the terminal, it is actually passing terminal sequences to the animator to be decoded and cached. The Animator uses a generic terminal definition called 'mfdebug', which defines all the capabilities required. Because of this it is not recommended that the screen-swap Animator be used if a non-COBOL sub-program is performing a lot of screen I/O. A better solution is to use cross-session animation. This is documented in the Debugging Handbook. Old KB# 7173
Problem: 198 load Failure with MQ Series Programs Resolution: Need to create a non-threaded verion of the MQ series module using the command: cob -z -e "" -Q -bE:mq.exp pgm.cbl -lpthread -L/usr/lpp/mqm/lib -lmqmcb to create a callable shared object for MQ series. Old KB# 7161
Problem: Why don't the keys ALT CTRL work when pressing them? Resolution: Unfortunately most UNIX terminals, by default, simply do not send a key sequence when the Alt or Ctrl key is pressed. You can see that no key sequence is sent from the ALT key by trying the following: > cat > test Then try pressing ALT, you will see that nothing appears in test, then try pressing ESC and you will see the key sequence ^[ being shown as this is what is sent when the ESC key is pressed. As nothing is sent when the ALT key is pressed then there is nothing for Server Express to respond to, therefore this is not a Server Express software issue, but a keyboard/Unix issue. In order to get around this to use our software, we recommend using /a for alt and /c for ctrl. To get a full list of key mappings you can use /m or see the COBOL User's Guide Appendix for Unix key usage chart Otherwise maybe
Problem: You get the following message on Sun Sparc Solaris with Server Express: /tmp/cobAAAmZaaPD/%cob0.s: Assembler messages: /tmp/cobAAAmZaaPD/%cob0.s:36: Error: Unknown segment type /tmp/cobAAAmZaaPD/%cob0.s:36: Warning: rest of line ignored; first ignored character is '"' cob32: error(s) in assembling /tmp/cobAAAmZaaPD/%cob0.s Resolution: Solution is copy the GNU Versions to another name like cp /usr/local/bin/as /usr/local/bin/as.gnu cp /usr/local/bin/ld /usr/local/bin/ld.gnu cp /usr/local/bin/make /usr/local/bin/make.gnu Then the cob command get the assembler of the Sun C Compiler Old KB# 7211
Problem: Earlier COBOL products for both Wiindows and Unix products contained a family of Call-by-number routines to read and write characters and attributes to and from the screen. These are not available in Server Express Resolution: A lot of the call-by-number routines were replaced by call-by-name routines many years ago, but the call-by-number routines were kept in the product to assist migration. They've now been removed entirely. The replacements for x'B7' and x'B8' are as follows: B7 0 cbl_read_scr_chars B7 1 cbl_write_scr_chars B7 2 cbl_read_scr_attrs B7 3 cbl_write_scr_chars B7 4 cbl_write_scr_n_char B7 5 cbl_write_scr_n_attr B8 0 cbl_read_scr_chattrs B8 1 cbl_write_scr_charrts Refer to the product documentation for full details of how to use these calls. Old KB# 7187
Problem: Using "cob -x" to rebuild an application that includes some C source code, a customer was getting error "cannot access cc". Resolution: The "cob -x" command, when given C source code (.c) as an argument, invokes the C compiler that comes with the UNIX operating system. In the case of Solaris, this is the Forte product from Sun. If the C compiler is not installed, or if the PATH environment variable is set such that the "cc" command cannot be found, then this error appears. The solution is to purchase and install the C compiler, or to update the PATH environment variable so the "cc" command can be found. Old KB# 7203
Problem: When executing a database client application, an error about libpthread, or thread-local storage appears, such as : * /usr/lib/dld.sl: Can't shl_load() a library containing Thread Local Storage: * OpenESQL Error: You must execute your application using the threaded COBOL run-time. * RTS198 (load failure) Resolution: Recent versions of database software are built using threaded C libraries. It's therefore imperative that user applications are compiled and executed with the threaded run-time, i.e. : * Compile, generate, and link the application using the -t cob flag * Ensure that you execute the app using cobrun_t, rather than cobrun On some Operating Systems, such as HP-UX PA-RISC, if you attempt to execute a database application with the non-threaded COBOL run-time, you will see an error from the dynamic loader : > cobrun myapp /usr/lib/dld.sl: Can't shl_loa
Problem: The only reason a process would continue to run when a terminal session is ended is when the terminal session is not shut down correctly, for example if a client machine is switched off unexpectadly or the network connection is lost. When a telnet session is 'killed' i.e. not shut down cleanly, it does not send any signal back to any child processes (cobol, C or vi for example) and therefore the child processes have no reason to die and they continue running. Resolution: The best option is to always close the Cobol application cleanly. The other option is to use the exec command so that the cobol process is not a child process. When you don't use "exec" you effectively have two processes running, the first one is the shell invoked from the telnet session the second is "cobrun xxxx". If you then switch off the PC or the connection is lost, only the shell is ki
Problem: Sometimes in COBOL applications there is a requirement for pausing execution of an application before continuing. Most techniques for doing this involve tying up the processor (e.g. performing a large 'perform varying'), to the detriment of other users. Resolution: One method worth trying is to use call "SYSTEM" and call a UNIX script containing a sleep statement. e.g. working-storage section. 01 w-call-sleep. 03 filler pic x(7) value "sleep 5". 03 filler pic x value x"00". procedure division. .......... ........... call "SYSTEM" using w-call-sleep ............ ............. The parameter for sleep is in whole seconds, and there may be OS discrepancies of up to one second
Problem: When compiling, you get the following error message: cob32: can not execute CC Resolution: Use the command "which cc" or "which CC" to find out whether there's a "cc" or "CC" command on the path and if found, what directory is it in. Also try the command "CC -V" or "cc -V" to give you some version information about your C or C compiler (respectively). If those commands cannot find it, then the "cob" command won't find it either. It is possible that the system has no C (or C compiler) installed, which would obviously cause the "CC" command to fail The least likely, but another possible cause, is that the "CC" (or "cc") command is present in a directory specified on PATH, but the user lacks permission to run it. Old KB# 7163
Problem: NOT SEEING PARAMETERS ON INPUT FILE defined as STDIN Resolution: set command_line_accept=true in the cobconfig file, which is a run-time configuration file. The run-time configuration file is a text file, which you can edit with your standard text editor. It is an optional file (no error will be issued if it does not exist) with the default name $COBDIR/etc/cobconfig. You can specify a filename for the configuration file by setting the environment variable COBCONFIG; for example: COBCONFIG=$HOME/myconfig export COBCONFIG command_line_accept Syntax: set command_line_accept={TRUE|FALSE} Value: TRUE or FALSE If TRUE, the first ACCEPT or READ from STDIN takes the input from the command line. Default: FALSE. The first ACCEPT or READ from STDIN takes the input from the user. This provides direct ANSI conformance. You should set this if you want to execute a program that has been generated from convert3 or convert5. Old KB# 717
Problem: A programmer uses the REMOVE compiler directive to take a reserved word out of action, and they do this generally (for all programs), but in one certain program, they would like to restore this reserved word. How can this be done? Resolution: Use the ADDRSV compiler directive, and put it in a $SET statement in the source code of the program in question. Even though the REMOVE directive is specified on the "cob" command line, $SET statements override settings made elsewhere, so $SET ADDRSV will restore the reserved word. Here is an example: --------------------- driving shell script --------------------------------- # compile the program with the reserved word SUBTRACT # removed from being a reserved word (compilation should # fail because the program uses SUBTRACT) cob -C REMOVE\\"SUBTRACT\\" -v addrsv_not_there.cbl echo; echo; # Now try a
Problem: How to specify SIGN=EBCDIC in cobopt Resolution: insert line containing: -C sign=ebcdic in the cobopt file using text editor of your choice Old KB# 7159
Already have an account? Login
No account yet? Create an account
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.