Showing posts with label IBM Mainframes. Show all posts
Showing posts with label IBM Mainframes. Show all posts

How to Automate the process of importing file from IBM Mainframes to spreedsheet

Scenario:
I have a TAB Delimited and it contain 10 fields., and Presently this is downloading into testfile.txt importing into excel spreedsheet.
Now, I need to automate this process. by writing a program which sends this file to Spreadsheet.


Solution:
A spreadsheet is not a mainframe entity, so can not be created on the mainframe.

As far as I can remember, this could not be done by a mainframe process, and that the current way that this task is currently being performed is the only way.


Read More on this artcile from IBM Mainfarmes Forums

Mainframe vs. Client/Server

In a client/server architecture, multiple computers typically cooperate to do the same task. For example, in Figure 1.1 the application uses a Web server, a database server, and an LDAP server.
Figure 1.1 Figure 1.1 Client/server architecture
On a mainframe, the same computer does everything. One security package (RACF, in most cases) protects one operating system kernel. Mainframe subsystems do everything else, as you can see in Figure 1.2.
That's a little of the "why" of mainframes. Now let's get started with the "how."

How to find real memory in IBM AIX Unix,Commands to find real memory in IBM AIX

To display real memory in kilobytes (KB), run either one of the following commands:
bootinfo -r
lsattr -El sys0 -a realmem

Basic Framework of JCL



/name JOB parameters...
//name EXEC parameters...
//name DD parameters...

Each of this JCL Statements have a label – a symbolic name assigned to them. Its like naming kids. Well, there could be so many boys in your area, but how do distinguish them? Of course, by their names.

In the same way, a JCL may contain a bunch of DD Statements, one for Input file, one for the output file, one for the error file. How do you tell them apart, by naming them. As a good practice, we always give names to all our JCL Statements. Names kinda help you to refer back to these statements in the future. You want to point out a particular JCL Statement to your friend, just spell out its name.

But, notice carefully, each label(name) is preceded with two slashes //. The two slashes are a JCL Statement’s signature. They indicate that the statement is a JCL Statement(one of JOB, EXEC, DD). Every JCL Statement wear the two slashes //. A naked statement without // won’t be treated as a JCL Statement.

Now, every JOB, EXEC and DD Statement has got these whole lot of parameters. What you’ll be learning throughout these tutorials is mostly the parameters. Parameters add stuff and meaning to the JCL Statement. 

Now, let me give you a booster, that’s going to help you organise the way you think about this JCL.

- JCL is made up of mainly JOB, EXEC and DD.
- JOB is easy to learn and use.
- EXEC is easy and fun to use.
- DD Statements take three forms
   1. DD Statements to read a file.(easy)
   2. DD Statements to write to the logs.(easy)
   3. DD Statements to create a new file(hard!); you’d have to learn parameters such as DISP, UNIT, DCB, SPACE and several others to code this.

Have a good look at this chart :


Image99[1]

IBM Mainframes : COBOL Interview Questions and Answers

File Concept 
The Disposition Parameter in the JCL is Share ( DISP=SHR ) and Cobol program opens file in " Extend " mode. In this scenarion what will happen to that file?

If we open file in xtend mode then old data will not lose we append the new data without losing old data.

What is GETMAIN and FREEMAIN? What are the restrictions while using GETMAIN and FREEMAIN?

The concept of CICS GETMAIN is simply to provide the programmer the capacity of obtaining additional storage to augment storage acquired automatically by his program (e.g. WORKING-STORAGE in a COBOL program). The programmer may define certain fields (01 Levels) in the LINKAGE SECTION that may require the use of a GETMAIN to obtain the storage. These fields are usually output fields that are not passed to the program by another program (caller).

In the case of input fields the use of the SET can be used to point to the acquired area or a calling program can pass the address to the called program. The acquired area from a GETMAIN can be above or below the line. In addition storage acquired by a normal GETMAIN can be explicitly released by a FREEMAIN or automatically released when the task ends by CICS. However a program can acquire SHARED storage that comes out of the SDSA/ESDSA that requires an explict FREEMAIN as this type of storage is not automatically released at task end. The use of shared storage requires more control as incorrect use can quickly deplete the (E) DSA storage available.

What is the batch job and online job?

Question:
What is the batch job and online job?
Answer:
A batch job is a stand alone job (no human interaction) that is kicked off by a utility job(usaually at night)  and runs data in bulk streams, such as updating 1 million rows to a database nightly, online job is real time, such as a user updating their address via  an interface screen and it being applied to the database as soon as they have confirmed it.
Answer 2:
In batch input and output is file where as in online input and output is user interactive.
In batch start of job is done by JCL where as in online it is done by transaction.
Execution time is longer in batch where as less in case of online.

Basic Framework of Job Control Language-JCL

My head’s spinning around the 3 JCL Statements : JOB, EXEC and DD. Could you tell me something more about them?
So, you’ve got the gist of the concept behind JCL, all the JCL that you going to write from hereon, maybe for the next 10-20 years, would be composed of three main statements :





//nameJOBparameters...
//nameEXECparameters...
//nameDDparameters..

Each of this JCL Statements have a label – a symbolic name assigned to them. Its like naming kids. Well, there could be so many boys in your area, but how do distinguish them? Of course, by their names.


In the same way, a JCL may contain a bunch of DD Statements, one for Input file, one for the output file, one for the error file. How do you tell them apart, by naming them. As a good practice, we always give names to all our JCL Statements. Names kinda help you to refer back to these statements in the future. You want to point out a particular JCL Statement to your friend, just spell out its name.

But, notice carefully, each label(name) is preceded with two slashes //. The two slashes are a JCL Statement’s signature. They indicate that the statement is a JCL Statement(one of JOB, EXEC, DD). Every JCL Statement wear the two slashes //. A naked statement without // won’t be treated as a JCL Statement.

Now, every JOB, EXEC and DD Statement has got these whole lot of parameters. What you’ll be learning throughout these tutorials is mostly the parameters. Parameters add stuff and meaning to the JCL Statement.

Now, let me give you a booster, that’s going to help you organise the way you think about this JCL.

JCL is made up of mainly JOB, EXEC and DD.
- JOB is easy to learn and use.
- EXEC is easy and fun to use.
- DD Statements take three forms
   1. DD Statements to read a file.(easy)
   2. DD Statements to write to the logs.(easy)
   3. DD Statements to create a new file(hard!); you’d have to learn parameters such as DISP, UNIT, DCB, SPACE and several others to code this.

Have a good look at this chart :
Image99[1]

10 Key Security Questions to Help Determine the Most Secure Platform


1. How well does it protect sensitive data?
Mainframe computers provide for complete protection of all data from unauthorized reading and writing. If you want a measurable standard of how good the security of a given computer is, you probably want to know how it scores on the Common Criteria, a set of standards supported by the International Standards Organization (ISO). They specify seven levels of security from Evaluation Assurance Level (EAL)-1 up to EAL-7. A computer system is granted an EAL certification only after rigorous independent testing. Levels EAL-1 to EAL-4 apply to commercial installations. Levels EAL-5 and higher are much more formal and are granted only after certification by the National Security Agency (NSA).
Mainframe computers with z/OS system software have been certified at EAL-4+. Mainframes with VM system software have been certified at EAL-3+. With Linux system software, mainframes have been certified at EAL-4+.
Mainframe computers are usually kept behind locked doors in a secure data center. This physical security provides a “secure zone,” and within that zone, the mainframe security software permits only authorized users to access data. Outside the security of the data center, access to data is restricted by means of encryption. Whether the data is sent over a network or shipped on a tape cartridge, encryption can prevent unauthorized data access. You’ve probably read f companies whose computer tapes containing sensitive data were stolen off delivery trucks. In cases where the data on the tapes had been encrypted, the loss was minimal.
Mainframe computer security provides several additional access control functions not commonly found on other types of computers. These include verification of tape access by means of tape labels, access control over printouts before they’re printed, and automated obliteration of data when disk data sets are erased.
Because of its large size and standardized processes, the mainframe can be said to offer more functions and more comprehensive protection of computerized data than most computing platforms.
Windows computers have received a Common Criteria rating of EAL-4+, the same as mainframes with the z/OS operating system. Unix computer ratings vary with the brand of Unix, but mainframes with Linux also have been rated EAL-4+.
Mainframes can provide more security functions than Windows or Unix, such as the tape and printout protection previously described, because of their greater processing power. Unlike mainframes, Windows and Unix systems aren’t always housed in locked data centers with strong physical security.
For any computer system you’re considering, ask how it ranks on the Common Criteria, which provides a consistent, independent evaluation of a given computer’s security. Also, ensure that your staff encrypts all sensitive data leaving your data center.

What is the EVALUATE Statement used for? How does it work?

When there are multiple options to choose from, the EVALUATE statement works best. When there are several choices to be made, IF-ELSE logic can become very complicated. To avoid writing complex nested IF Conditionals(condition-within-condition), the EVALUATE Statement can be used. The EVALUATE statement is the COBOL equivalent of switch-case in most conventional programming languages.

The general format of the EVALUATE Statement is as follows :

Syntax:

EVALUATE
   WHEN condition-1
     Statement-1
     ...

   WHEN condition-2
     Statement-2
     ...


   WHEN OTHER
     Statement-n
     ...

END-EVALUATE
STATEMENT-X

Interpretation:

The EVALUATE computes the value of the main expression.

1. If the value satisfies condition-1, then Statement-1 is performed, and after execution, control jumps to STATEMENT-X(Outside the EVALUATE Block).

2. Else If the value satisfies condition-2, then Statement-2 is performed, and after execution, control jumps to STATEMENT-X(Outside the EVALUATE Block).

...

n. If the values satisfies none of the above conditions, then by default WHEN OTHER case is executed(Statement-n), and then the control jumps to STATEMENT-X.(Outside the EVALUATE Block)

Thus, at each level of the EVALUATE block, the condition is checked, if it holds true, the case is executed, if it doesn’t hold true, you descend to the next lower level and so on... This is called a 
fall-through.

Example:

Image60[1] 
Upon running the above COBOL Program, you should get the following output-

Image61[1]