Search found 20 matches

by chaat
Fri Dec 14, 2018 3:00 am
Forum: COBOL
Topic: vmate
Replies: 1
Views: 4606

Re: vmate ==> how is this related to COBOL ?

how is this related to COBOL ?

this appears to be spam and should be removed.
by chaat
Sat Sep 24, 2016 11:44 am
Forum: COBOL
Topic: Cobol program to get data from Large table
Replies: 2
Views: 7436

declare grade_count cursor for
select grade, count(*)
from db2.table
where grade between 1 and 100
group by grade


this cursor will return 100 rows with the grade and the count for that grade.
by chaat
Tue Nov 10, 2015 10:52 am
Forum: DFSORT , ICETOOL & Utilities
Topic: SORT card needed to exclude record set
Replies: 18
Views: 19534

JOINKEYS with the same dataset for both inputs. Specofy the key as the first byte (ie will be A) and use a JOIN UNPAIRED,F1,ONLY In JNF2CNTL, INCLUDE for that value at that position and also a data-record. If there are no records to include, your entire main file will be "unmatched", meaning you wa...
by chaat
Mon Apr 20, 2015 7:35 am
Forum: COBOL
Topic: COBOL Program performance tuning tips
Replies: 22
Views: 76909

I've had good results converting programs to be sort exit programs. for example pgm 1 writes an output file A which is then sorted and the output is input to pgm 1 after converting pgm 1 to an E15 sort exit and pgm 2 to an E35 sort exit three steps are replaced by a single sort step. caveat... these...
by chaat
Sun Feb 08, 2015 2:49 am
Forum: JCL
Topic: How to unzip a mainframe file ..
Replies: 1
Views: 4306

i've done this many times it should work.

did you remember to ftp the zip file as BINARY ? if not that is the problem.
by chaat
Mon Sep 08, 2014 5:46 am
Forum: COBOL
Topic: HOW TO FIND LINKAGE LENGTH
Replies: 4
Views: 7442

Dhiraj, the most common practice in most shops is to require that all areas that are used to communicate between programs must be in copy members that are used by both the calling and called programs. This is a tried and true method of ensuring that length in the linkage section of the called progra...
by chaat
Tue Jan 01, 2013 1:13 pm
Forum: COBOL
Topic: using Index other than subscript
Replies: 12
Views: 17153

from the Enterprise COBOL performance manual i quoted above. One of the factors which affect these results is how many times subscripted / indexed items are referenced in the code. The more references, the greater the savings. Also muliple dimensioned arrays will also show a greater savings. ps.. th...
by chaat
Tue Jan 01, 2013 12:48 pm
Forum: COBOL
Topic: OCCURS DEPENDING ON
Replies: 10
Views: 13450

William, I did post that hand coded binary search logic some time back. we are still using it in production. The reason we had to code it by hand is that we were emulating the START verb used against a VSAM file which we have loaded into memory and the key value which we are searching for is NOT in ...
by chaat
Tue Jan 01, 2013 12:27 am
Forum: COBOL
Topic: OCCURS DEPENDING ON
Replies: 10
Views: 13450

William, moving zero to the subscript works exactly the same way with the exception that if you use a SEARCH or SEARCH ALL verb, then the array must be initialized properly in order for those verbs to work correctly with a fixed length array. using an ODO variable length array eliminates the need to...
by chaat
Tue Jan 01, 2013 12:00 am
Forum: COBOL
Topic: using Index other than subscript
Replies: 12
Views: 17153

William, on an IBM Mainframe system using the Enterprise COBOL V4.2 compiler, the use of an index will generate more efficient code. it should be pretty easy to create two small programs which each loop thru the array a million times and then compare the cpu time of the two. see this manual... http:...
by chaat
Sun Dec 30, 2012 8:54 am
Forum: DFSORT , ICETOOL & Utilities
Topic: To copy the matched records data from two files.
Replies: 6
Views: 6633

Krunal,

if you have DFSORT available, then look at the JOINKEYS functionality to accomplish what you are attempting. I think that it would work.
by chaat
Sun Dec 30, 2012 8:49 am
Forum: JCL
Topic: Addin USER= xxx to all JCL in a PDS at onc
Replies: 3
Views: 4796

Tom, if you have File-Aid available, there is a way to have it process in JCL format. Check the manual on how to do that. There may be an easy way to do this with File-Aid. ps... don't try to update the existing pds, rather copy it to a new pds and make the changes as you're doing the copy member fu...
by chaat
Sun Dec 30, 2012 8:42 am
Forum: FILE-AID
Topic: Replace all but multiple times in a single record
Replies: 5
Views: 9285

$$dd01 COPYALL IN=0, *** *** this will replace starting in column 1 for the length *** of the entire input record *** EDITALL=(1,0,C'A',C'X'), CHANGE ALL 'A' TO 'X' EDITALL=(1,0,C'C',C'Z'), CHANGE ALL 'C' TO 'Z' DUMP=10,OUT=0 note that you can include comments much like jcl any line starting with an...
by chaat
Sun Dec 30, 2012 8:29 am
Forum: DB2 SQL - DB2 PROGRAMMING
Topic: Need a clarification on -811
Replies: 4
Views: 5459

Guru, if you only need the data from the first row which meets your criteria, then add a "FETCH FIRST ONE ROW ONLY" to the bottom of your select statement as it will execute faster. hint --> this causes DB2 to quit searching once it finds a row which meets your criteria, so you will never get a -811...
by chaat
Sun Dec 30, 2012 8:25 am
Forum: COBOL
Topic: DB2 Varchar Column to Cobol variable
Replies: 3
Views: 7162

Mohan, it is possible to process that data in cobol but you need to use some pretty tricky logic with pointers to accomplish that. another option is to list the columns in the db2 unload job and put the varchar column at the end so it is the last column on the output file. Then it is much simpler to...