View previous topic :: View next topic
|
Author |
Message |
Sundar V
New User
Joined: 25 Apr 2006 Posts: 5
|
|
|
|
Hi,
I am working on project contains RM COBOL running in Unix Platform. We have unix index files instead of database.
To read any content of the file, we have to write a dummy cobol program.
Please advise is there any other alternate way where i can read index files (in unix) using any rexx programs.
Also please let me know how to execute the rexx program in Unix?
Thanks.
Sundar |
|
Back to top |
|
|
enrico-sorichetti
Superior Member
Joined: 14 Mar 2007 Posts: 10872 Location: italy
|
|
|
|
Quote: |
We have unix index files instead of database. |
could You please elucubrate a bit on these index files
as far as executing a rexx script all the unix like systems have the so called she/bang
if the first line of Your_thing start with
(means that something called rexx residing in the bin directory will be used to process Your_thing)
and the source thing has been made executable oring the one bit in the attributes
Code: |
chmod 111 Your_thing |
just typing in shell the name of Your_thing it will be execute |
|
Back to top |
|
|
Sundar V
New User
Joined: 25 Apr 2006 Posts: 5
|
|
|
|
Hi enrico,
Thanks for your reply.
We create the index files in COBOL Program. example as below:
COBOL PGM1
Code: |
000000 E.
000000 OPEN OUTPUT LOG-FILE.
030610 FD LOG-FILE BLOCK 512 CHARACTERS
030611 RECORD 22 TO 62 CHARACTERS
030612 LABEL RECORD STANDARD.^
030613*^M
030614 01 LOG0-RECORD.^M
030615 05 LOGSA PIC X(01).^M
030616 05 LOG-KEY PIC X(21).
030616 01 LOG-RECORD PIC X(55).
030618 01 LOG1-RECORD PIC X(62). |
then we run this cobol program using a script - which executes in $DATA.
which creates the file in our $DATA (/psup/idms_sh/data/live)
Code: |
#!/bin/csh
[color=red]cd $DATA[/color]
#
# cs-ktodate *** KTODATES ***
#
#**********************************************************
#
EX runcob KTODATE -k
#
echo " ******************** END OF cs-ktodate ***************"
#
# ******************** END OF cs-ktodate *************** |
Regarding my second question (executing the rexx script in unix), i dont understand clearly. i am new to unix and rexx. it will be very much helpful if you please give me an example. My requirement is to read these index files using a universal rexx program.
For example, we have file aid tool in mainframe, through which we browse the content of the files. like this can i read index files using any universal rexx program. please advise.
i checked my bin (/psup/comms_sh/bin) directory i couldnt see any rexx residing there. if so what to do. please advise.
Sorry for bothering much.
Thanks.
Sundar |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Quote: |
Sorry for bothering much |
No bother
You might first check with your sysadmins to make sure rexx is available on your partixcular unix system and that you have the proper permissions to use it.
There are already tools on the system that allow you to read files. Again, if you ask the sysadmins, they can tell you which tools are available.
Depending on your files, you might try vi (an editor that has been on every unix system i've ever been issued a logon). |
|
Back to top |
|
|
|