IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Retrieve multiple records with metacobol from CA Datacom


IBM Mainframe Forums -> CA Products
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Jose Juan J

New User


Joined: 25 Jul 2020
Posts: 1
Location: Mexico

PostPosted: Sat Jul 25, 2020 1:36 am
Reply with quote

Hi,

Let's say there is a table in CA DATACOM having a primary key of 2 records one numeric of 3 positions and another numeric 5 positions, now the first one may be duplicated but in combination with the second one we get an unique key, example, imagine these are keys

Fld1 Fld2
001 00001
001 00002
002 00001
002 00002
002 00005
099 00234

The number of records is not fixed there might be only 10 or 100 we don't know.

Now if I want to retrieve let's say all the records where the first field (3 numeric positions) equals to 002.. if this was DB2 I would just simply declare a cursor and fetch as many times necessary.
If it was a file I would use maybe Easytrieve and retrieve the records.

But the requirement is to use CA DATACOM and Metacobol I cannot even use SQL
What I was thinking was maybe using the command 'GETIT' from Metacobol which is supposed to do read sequential and use a perform until to read one by one until I found Field1 != 002.

Does anyone can visualize another way to do it?
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> CA Products

 


Similar Topics
Topic Forum Replies
This topic is locked: you cannot edit posts or make replies. Sort to include records of file 2 int... Java & MQSeries 1
No new posts define 1 DCB parms for multiple outpu... JCL & VSAM 9
No new posts Multiple find/replace on the same dat... DFSORT/ICETOOL 4
No new posts Copy a DS Member to multiple users at... TSO/ISPF 8
No new posts Cobol program to determine the sequen... COBOL Programming 2
Search our Forums:

Back to Top