View previous topic :: View next topic |
Author |
Message |
Beswar Beginner
Joined: 04 Feb 2003 Posts: 33 Topics: 15
|
Posted: Wed Feb 09, 2005 11:02 am Post subject: TOTAl/Supra datbase |
|
|
Hi
I need help to get some information regarding Total/Supra Database. Could you please let me know where I get some information on how to use in the COBOL to call Total/Supra Database.
Thanks
Eswar |
|
Back to top |
|
 |
kolusu Site Admin

Joined: 26 Nov 2002 Posts: 12383 Topics: 75 Location: San Jose
|
|
Back to top |
|
 |
hari_uss Beginner
Joined: 19 Dec 2002 Posts: 78 Topics: 6 Location: Trivandrum, India
|
Posted: Thu Feb 10, 2005 9:04 am Post subject: |
|
|
About 2 years back, I was part of a TOTAL to DB2 conversion project team. I remember some of the characteristics of the TOTAL database like Master files, variable files, calls like OPEN, READM, READV, READR, CLOSE etc. However I moved out from that company later. So it is not possible for me to see those programs again to refresh my memory. Let me know what you are looking for, if it is on top of my mind, I may be able to help you. |
|
Back to top |
|
 |
Beswar Beginner
Joined: 04 Feb 2003 Posts: 33 Topics: 15
|
Posted: Thu Feb 10, 2005 9:44 am Post subject: |
|
|
Hari,
Thanks for the information. I was looking predominatly on how to write calls using Total/supra database in COBOL programs. Also i would like to know whether it is a network database or not?
Thanks for your help
Thanks
Eswar |
|
Back to top |
|
 |
hari_uss Beginner
Joined: 19 Dec 2002 Posts: 78 Topics: 6 Location: Trivandrum, India
|
Posted: Thu Feb 10, 2005 3:45 pm Post subject: |
|
|
Eswar,
To be frank I forgot the syntax of the CALL statement. All I remember is, it was having some interface program which we have to call from COBOL with suitable parameters like operation, I-O area, status variable and all. Something like
CALL XXXXX READM, MREF-AREA, MREF-STAT where XXXX is the interface program (Again, I am not cent percent sure about this, I will try to search in my mail/doc repository and will let you know if I could find something).
It was neither network nor hirearchical, but somewhere in between. The concept was of master files and variable files. One master can have more than one variable file, I suppose. For each record in the master file, there could be one or more variable records. I.e., to read a master record and its corresponding variables, you will have to
1. open master file (command OPENM)
2. open variable file (OPENV)
3. read master (READM)
4. read variable (READV) in a loop till you get a rec-not-found condition.
It was funny to look at the variable files. If you browse them, you can see some unreadable characters at the start of each record and lot of unused blank lines between each record. It is not necessary that the records in the variable files to be stored in order. It can be in any order but the link is via the first 8 charaters (I think it was 8) at the start of each record. It had two parts, first part will tell you which is the previous record linked with it and the second part shows which is the next record. Because of this, it was possible to read in backward direction (READR was the command for it, I think). And it was difficult to implement this functionality in DB2 since we were in V5.0 (with out the cursor read previous facility).
Sorry, but I seldom keeps in syntax in mind since I always think it is written in the book and I can refer it always.. |
|
Back to top |
|
 |
Beswar Beginner
Joined: 04 Feb 2003 Posts: 33 Topics: 15
|
Posted: Thu Feb 10, 2005 9:50 pm Post subject: |
|
|
Hari,
Thank you very much for your information. I was able to get a brief overview of the Supra database. Is master is file similar to the root segement/(like IMS) and other variable files are child segments
Thanks
Eswar |
|
Back to top |
|
 |
hari_uss Beginner
Joined: 19 Dec 2002 Posts: 78 Topics: 6 Location: Trivandrum, India
|
Posted: Fri Feb 11, 2005 5:55 am Post subject: |
|
|
In a way, yes, you can compare like that with IMS. But as I mentioned in the last post, each of the variable record will have a pointer to the next record in chain and the previous record in chain. In that sense, you can compare it with a network database.
Another thing worth mentioning is, the blank lines in the variable file will get used up when you insert new records in to the database. It does not matter where it is getting inserted since all the chaining is happening via the pointers at the start of the record. When a new file is created, it should be defined with sufficient amount of storage - otherwise after so many inserts, all the space in the database will be used up and there won't be any more blank lines!
What kind of project you are doing? Is it maintanence or a conversion from TOTAL to something else? |
|
Back to top |
|
 |
Beswar Beginner
Joined: 04 Feb 2003 Posts: 33 Topics: 15
|
Posted: Fri Feb 11, 2005 10:51 am Post subject: |
|
|
hari,
thanks for your valuable info. our project is a data migration of supra database to db2 database. I am in the process of preparing a cook book for this, hence I would need as much info as possible.
is there any limit of varaibale files for each master file i
Thanks
Eswar |
|
Back to top |
|
 |
hari_uss Beginner
Joined: 19 Dec 2002 Posts: 78 Topics: 6 Location: Trivandrum, India
|
Posted: Fri Feb 11, 2005 2:29 pm Post subject: |
|
|
Quote: |
is there any limit of varaibale files for each master file
|
Hmm..thats a pure text book question. I am sorry but I don't have a TOTAL manual with me right now. And during a development you will never try to keep these kind of things in mind since normally no application will stretch the software to its limits (like using lot of variable files so that it will reach the limit).
Another point which I wanted to make clear is, I have worked only on TOTAL not on SUPRA. I know it is somewhat superior form of TOTAL but never had a chance to put my hand on it.
I think more important question is how you are planning to migrate to DB2? Analyzing the entire business logic, data, programs, process etc and designing a new application with back end as DB2?
Or
Putting one-to-one replacement for the existing database objects (like one DB2 table each for master and variable files) and touching the application programs to just replace the TOTAL calls with SQL queries? |
|
Back to top |
|
 |
|
|