Browse all forums dedicated to the Rocket® COBOL product family.
Recently active
Problem: Running a job that has 14 sort steps and then a COBOL program that does delta reporting. The files range in size from 1 million to 3 million records with record sizes from 100 bytes to 400 bytes. The largest file in this test run is just under 2 gigabytes. The entire job takes One hour to run on a Windows Server 2003 machine with 2 gigabytes of memory One hour and twenty minutes on a Windows/XP, laptop with 2 gigabytes of memory Ten minutes on the ZOS mainframe. Have been experimenting with the following in the EXTFH CONFIG file. SEQDATBUF=4096, 32K, 132K READSEMA=OFF IGNORELOCK=ON Some things managed to get a 10% performance improvement but would like to get a lot more. Are there anymore directives (remember most of this is MFSORT, not COBOL)? What is the recommended setting for SEQDATBUF when using large sequential files? Resolution: Definitely defrag first, but also to set: TMP Tells the run-time syste
Problem: Passing a non-recognisable or non-existent date to the INTEGER-OF-DATE intrinsic function returns a value of 0. Example; C:\\>type Pro1.cbl DATA DIVISION. WORKING-STORAGE SECTION. 01 RET PIC 9(8). PROCEDURE DIVISION. MOVE FUNCTION INTEGER-OF-DATE(20060229) TO RET. DISPLAY RET. GOBACK. C:\\>runc Pro1 00000000 Is the function defined to return value 0 for any non-existent date? Resolution: Please refer to documentation. A search for 'intrinsic function' in the Index points to: 'Reference > COBOL Language > Part 2: Program Definition >
Problem: Cbllink executes three other programs: the Cobol Compiler; Cblnames; and Link. The parameter input to Cbllink, consisting of switches and filenames, determines the programs executed, the output files created, the output files retained and the Run time the program produced will utilize. The "Usage" for this program is documented as follows: usage: cbllink [-V] [-S] [-D] [-G] [-L] [-K] [-Boptions] [-Foption] [-Roption] [-Mname] [-Oname] file1 [file2,...] This can be simplified, and adjusted to improve the accuracy, as follows: usage: cbllink [switches] fileName1[.extension] [fileName2[.extension] ...] The switches you specify are actually a combination of Cbllink and Cblnames switches. The switch possibilities are covered in Cbllink & Cblnames Switches. The filename and file extension possibilities are covered in Cbllink File Types. Resolution: Cbllink & Cblnames Switches The following lists the Cbllink and C
Problem: Using the DataGridView .Net control it is possible to have cells that contain a Push Button Control. If you do this how can you detect when the button has been pressed ? Resolution: On the DataGridView you need to trap the CellContentClick event. This is generated when the button is pressed on the grid. However this event is also generated on any other cell types as well. You therefore need to check that it is also a button cell type (DataGridViewButtonCell .Net type). You can use the "instance of" operator in .Net COBOL to do this. Some example code to trap a button click would be:- method-id. "dataGridView1_CellContentClick" final private. 01 ls-row cDataGridViewRow. 01 ls-cell object. 01 ls-cellbutton S-W-F-DataG
Problem: This document gives an overview of how to get started with the Micro Focus Fileshare product on a simple Network system using the TCP/IP protocol, which uses a single Fileshare server on which all data files reside. Applications run on several client machines and access and share the data files on the server through Fileshare. Both Windows and UNIX Fileshare configurations are covered. For a more detailed explanation of setting up and running CCI and Fileshare please refer to the Net Express manuals "Configuring CCI" and "Fileshare User's Guide". Resolution: This document will assume the following is true: The Fileshare server name is fsserver1. The hostname of the server machine is TESTFS and its dotted IP address is 127.0.0.1. The appropriate Net Express or Server Express Application Server (run-time) files are installed on the client systems and on the Fileshare server. Please refer to your product documentation for a list of the files, which
Problem: Net Express with .NET Calling a user-created file handler in .NET gives error message when compiling: " Failed to find system program "aUserfh" " The CALLFH(aUserfh) directive is set and the file handler is in the project directory. The call to the file handler works if the DLL for the file handler is referenced in the project. However, what if there is the need to compile the source from a script with the directives in a .DIR file? Resolution: Make sure the ILREF"<your assembly name>" directive is also set or included in the .DIR file. This does the equivalent of adding a reference in the Visual Studio IDE. Old KB# 1266#COBOL#netexpress#ServerExpress#RMCOBOL#AcuCobol
Problem: The Opacity allows to get some translucent effect on Windows so that the underlying desktop or windows can be seen. If however the property set on a MDI Clhild Window, it is possible to get unexpected painting problems in the application. Resolution: This is a restriction imposed by Microsoft. Windows and WinForms do not support MDI Child Windows having opacity set. Setting this in the application on MDI the application may have issues and unexpected behaviour when Windows are painted. Old KB# 1244
Problem: Release: 5.0: Using the PROFILE directive, but how to get a different target directory for the IPF files? Resolution: Using the COBPRFDIR environment variable to specify an alternative directory. For example: SET COBPRFDIR=C:\\myipfdir Old KB# 1204
Problem: If an HTML "input" control (such text, radio button, etc) has "disabled" attribute, the value of this control doesn't return to CGI program. Resolution: All disabled controls on an HTML page return null/undefined values to the CGI script. A disabled text input field that contains text, for example, does not return any text to the CGI program. Likewise, a disabled radio button that is checked will not return the "on" value to the CGI. This is the default behaviour. Old KB# 1210
Problem: How does ADIS (DISPLAY) decide what colour to use for BLINK. Doing a DISPLAY "HELLO" WITH BLINK how does ADIS decide what colours to use? Resolution: BLINKing (Flashing) text isn't supported by Microsoft's console APIs, so instead getting high intensity background colour eg black becomes grey. Old KB# 1250
Problem: Using REVERSE-VIDEO to display:- display "Hello" at 1101 with REVERSE-VIDEO How does ADIS decide what colours to use? Resolution: ADIS will simple reverse the current backgound and foreground colours. It is not possible to specifically configure ADIS to use any another colour. Old KB# 1248
Problem: How to make what goes to the Application Output window printable? Resolution: Use the OUTDD compiler directive. Put the full path and filename in the OUTDD compiler directive, then you should be able to print that file. Old KB# 1212
Problem: When using CBL_ routines and setting flags, it says set bit 0, bit 1, bit 2 etc. Is bit 0 on the left or right end? Resolution: - go to Net Express v5.0 Online Help - type in CBL_OR - select the topic under it 'using to set the value of a bit' - click 'display' - under the 'Parameters' area, click on the link to 'Key' - you are taken to 'Library Routines - Key' - page down - notice the lines: On Exit: Indicates which of the parameters shown are returned on exit. Where bits of one or more bytes are referenced, bit 0 is the least significant (rightmost) bit. Old KB# 1214
Problem: When accessing Micro Focus files it is always good practice to check the file status returned after each I/O operation. Resolution: It is possible to create a general COBOL copybook that can be reused in all programs. The following is an example of just such a copybook: 01 (tag)-fstat. 03 (tag)-fs-values. 05 (tag)-fs-key1 pic x(1). 05 (tag)-fs-key2 pic x(1). 05 (tag)-fs-key2-bin redefines &nb
Problem: Compiling a program with mulitple entry points gave the error: 002-R Attempted to redefine symbol when the program was compiled. Resolution: This was caused by the following scenario:- aaaaa.cbl had a program-id of bbbbb aaaaa.cbl also had a an ENTRY POINT called aaaaa. The problem here was generated because the compiler was attempting to create duplicate entry point called aaaaa. Here the program id did not match the source name. The solution was to rename the source file to bbbbb.cbl. The program then compiled cleanly to obj code. Old KB# 1247
Problem: Net Express 5.0 with .NET (base release): System.MissingMethodException on MicroFocus.COBOL.Program.Edited.loadCheck64bitNumericEdited message when running a Net Express 5.0 .NET application Resolution: Net Express 5.0 with .NET (base release): Where there is a combination of a MOVE from an edited data item to a non-edited data item and the CHECKNUM directive. Removing the CHECKNUM directive is a work-around, but installing Net Express 5.0 WrapPack #2 (or higher) will resolve the problem. Old KB# 1235
Problem: Is there a possibility to interface COBOL vs Open Source databases, e.g. MySQL or PostgreSQL? Resolution: Yes, via an ODBC interface provided by Net Express Windows product also provided by Server Express Unix / Linux product (to find in doc files under:OpenESQL) and including a precompiler there is a possibility to interface Open Source databases, e.g. MySQL / PostgreSQL, using ODBC drivers delivered by this Open Source community: a) MySQL: http://www.mysql.org/downloads/connector/odbc/ b) PostgreSQL: http://pgfoundry.org/projects/psqlodbc Old KB# 1240
Problem: When compiled to GNT the application just terminated with no error being output. However when it was built to INT it worked successfully. The last event from a COBOL runtime Consolidated Trace output was an exit program event. Resolution: The top level program in this case was C and it used cobcall to invoke the COBOL. Errors such as this are usually down to the application exceeding stack size. Recursion and local storage all contribute to the stack usage. To increase the stack size by using the /STACK option of the Microsoft Linker. Using another linker then please see the documentation supplied with your linker. Old KB# 1231
Problem: What is the simplest way to set the default ADIS (DISPLAY) colours so that all DISPLAY statements would use the specified colour. Resolution: The simplest way to do this is is simply to clear the screen as follows: display spaces with foreground-colour 3 This sets the default Text colour to CYAN. The online documentation details the number that correspond to colours. Old KB# 1249
Problem: Environment variables can be set at several locations and there was an invisible setting of the environment variable EXTFH which got priority over other settings. The resolution is valid for all environment variables. A status 9/194: "File size too large" was reported even if the settings in EXTFH.cfg configuration file were correct. The EXTFH.cfg settings were: [XFH-DEFAULT] FILEMAXSIZE=8 which allow to access an IDXFORMAT"8" file larger than 4 GByte. But nevertheless the OPEN gives a file status code 9/194. The setting of the environment variable EXTFH in the environment does not change the behaviour. What can cause this? Resolution: The cause for the status is that the EXTFH.cfg could not be read or a false one was found. See also KB: 23553 for "Using Filemon to ensure that the correct version of a file is in use" The resolution here was to delete the <project-name>_RTECFG.obj, because it was no longer used. This obj is linked
Problem: Attempting to install Net Express 4.0 onto a machine that previously had Application server installed. However, the Application Server product was not listed in the 'Add/Remove Programs' in the Control Panel, to enable it to be removed. Error: Setup has detected an installation of Application Server for Net Express 4.0. Net Express 4.0 cannot be installed while Application Server for Net Express 4.0 is present. Resolution: Fully check that no Application Server or Net Express product is installed: - check 'Add/Remove programs' via the Control Panel - check via Windows Explorer for the following folders C:\\Program Files\\Micro Focus\\Net Express OR C:\\Program Files\\Micro Focus\\Application Server OR C:\\mfaslmf - In the Windows Explorer and click on the C
Problem: File and Filename Routines: CBL_CHANGE_DIR, CBL_CHECK_FILE_EXIST, CBL_COPY_FILE, CBL_CREATE_DIR, CBL_DELETE_DIR, CBL_DELETE_FILE, CBL_DIR_SCAN_BEGIN, CBL_DIR_SCAN_END, CBL_DIR_SCAN_READ, CBL_GET_CURRENT_DIR, CBL_JOIN_FILENAME, CBL_RENAME_FILE, CBL_SPLIT_FILENAME, PC_FIND_DRIVES, PC_PRINT_FILE PC_PRINTER_CLOSE, PC_PRINTER_CONTROL, PC_LOAD_BMP, PC_PRINTER_OPEN, PC_PRINTER_WRITE, PC_PRINTER_WRITE_BMP, PC_READ_DRIVE, PC_SET_DRIVE Example: 01 infile-name pic x(20) value '%TMP%/infile'. 01 outfile-name pic x(20) value '%TMP%/outfile'. call 'CBL_COPY_FILE' using infile-name outfile-name. Will fail unless a file with the literal name "%TMP%/infile" exists. Likewise for the outfile name. The CBL_ routines use system API calls, not the command shell, to do their work. Only the command shell "knows"
Problem: OFN-ALLOWMULTISELECT flag can be set from the WinAPI GetOpenFileName function to specify that the File Name list box allows multiple selections in the open file dialog box. This however causes dialog box to use the old-style user interface. Resolution: It is documented from the Microsoft MSDN site (http://msdn.microsoft.com) that you need to set also the OFN-EXPLORER flag to have the dialog box to use the Explorer-style user interface. If this flag is not set, then it will use the old-style user interface. Old KB# 1246
Problem: On occasions there is an issue whereby the majority of the COBOL WinForms Toolbox Icons are the same. Unloading the project and reloading it, rebooting the PC does not help. Resolution: Drop to a Visual Studio command prompt and run the command DEVENV /ResetSettings The result will be that the Toolbox Icons are reset to their correct settings. Old KB# 1224
Problem: Net Express 5.0. Is it possible to turn the newline x"0A" character off when writing an XML stream to :cgi:. Resolution: The Net Express 5.0 documentation includes the following: New syntax for select statement is: SELECT xmlfile ASSIGN TO [[NOT] LINE ADVANCING] FILE Of course if "NOT LINE ADVANCING" is specified then no line-feeds would be included in the output. How to write a newline character at the end of the XML stream? This can be achieved as follows: ... select xml-file assign to not line advancing file-name organization is xml document-type is "CompanyTrans.xsd"
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.