Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Zowe V2 team configuration #287

Merged
merged 7 commits into from
Dec 20, 2022
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -370,238 +370,181 @@ Three ‘Enterprise COBOL for z/OS” manuals are referenced throughout the chap

## Lab

In this lab exercise, you will connect to an IBM Z system, view a simple COBOL hello world program in VSCode, submit JCL to compile the COBOL program, and view the output. Refer to "Installation of VSCode and extensions" to configure VSCode if you have not already done so. You can either use Z Open Editor and Zowe Explorer, or Code4z.
In this lab exercise, you will connect to an IBM Z system, view a simple COBOL hello world program in VSCode, submit JCL to compile the COBOL program, and view the output. Refer to "Installation of VSCode and extensions" to configure VSCode if you have not already done so. You can either use IBM Z Open Editor and Zowe Explorer, or Code4z.

1. The lab assumes installation of VSCode with either Z Open Editor and Zowe Explorer extensions, as shown in Figure 2a, or the Code4z extension pack, as shown in Figure 2b.
1. The lab assumes installation of VSCode with either IBM Z Open Editor and Zowe Explorer extensions, as shown in Figure 2a, or the Code4z extension pack, as shown in Figure 2b.

Click the **Extensions** icon. If you installed Z Open Editor and Zowe Explorer, the list should include:
Click the **Extensions** icon. If you installed IBM Z Open Editor and Zowe Explorer, the list should include:

1. IBM Z Open Editor
2. Zowe Explorer

![](Images/image044.png)

*Figure 2a. The Z Open Editor and Zowe Explorer VSCode extensions*
*Figure 2a. The IBM Z Open Editor and Zowe Explorer VSCode extensions*

If you installed Code4z, the list should include:

1. COBOL Language Support
2. Zowe Explorer
3. Explorer for Endevor
4. HLASM Language Support
5. Debugger for Mainframe
6. COBOL Control Flow
If you installed Code4z, the list should include:

1. COBOL Language Support
2. Zowe Explorer
3. Explorer for Endevor
4. HLASM Language Support
5. Debugger for Mainframe
6. COBOL Control Flow

In these exercises, you will only use the COBOL Language Support and Zowe Explorer extensions.

![](Images/image044b.png)

*Figure 2b. The Code4z package of VS Code extensions.*
*Figure 2b. The Code4z package of VSCode extensions.*

**Note:** If your list contains both Z Open Editor and COBOL Language Support, disable one of them, by clicking on the **cog** icon next to the extension in the extensions list, and selecting **disable**.

2. Click the Zowe Explorer icon as shown in Figure 3.
2. Click the Zowe Explorer icon as shown in Figure 3. Zowe Explorer can list Data Sets, Unix System Services (USS) files, and Jobs output.

![](Images/image046.png)

*Figure 3. Zowe Explorer Zowe Explorer icon*

3. Zowe Explorer can list Data Sets, Unix System Services (USS) files, and Jobs output as shown in Figure 4. + will appear when hovering to the far right on the DATA SETS line. Click the + to define a VSCode profile.

![](Images/image048.png)

*Figure 4. Zowe Explorer*

4. A box appears to define a new profile. Click + to the left of Create a New Connection to z/OS as shown in Figure 5.

![](Images/image050.png)

*Figure 5. Create a new connection to z/OS*


5. Select a name to enter, then enter. Figure 6. used `LearnCOBOL` as the selected connection name.

![](Images/image053.png)

*Figure 6. Set connection name*


6. VSCode prompts for z/OSMF URL and port as shown in Figure 7. The z/OSMF URL and port will normally be provided by the z/OS System Administrator.
3. In order to connect to the lab system, get your team configuration zip file and extract it.

![](Images/image056.png)
![](Images/image0001.png)

*Figure 7. z/OSMF URL*
*Figure 4. Extract the ZIP file*

7. A sample z/OSMF URL and port is entered as shown in Figure 8.
4. Open the extracted folder. You will find the two configuration files as shown in Figure 5.

![](Images/image058.png)
![](Images/image0002.png)

*Figure 8. Specified z/OSMF URL*
*Figure 5. Inside the Team configuration file*

8. The connection prompts for Username as shown in Figure 9.
5. Now back on your VSCode window, select the Explorer tab and press the "Open folder" button in the left bar.

![](Images/image061.png)

*Figure 9. User name prompt*
![](Images/image0006.png)

9. **Please enter the username assigned to you! Do not use the sample username of Z99998.** A sample username, is entered as shown in Figure 10. The ID is assigned by the System Administrator.
*Figure 6. Click the open folder button*

![](Images/image064.png)
6. A pop-up window would show up, select the folder containing the team configuration files.

*Figure 10. Specified user name*
![](Images/image0003.png)

*Figure 7. Select the team Configuration folder*

10. The connection prompts for the password as shown in Figure 11.
7. Your connection should be added automatically to the Data Sets list as shown in Figure 8a.

![](Images/image067.png)
![](Images/image0004.png)

*Figure 11. Password prompt*

11. Enter the password as shown in Figure 12.

![](Images/image070.png)
*Figure 8a. LearnCOBOL Connection*

*Figure 12. Specified password*
If the connection does not appear, hover to the far right of the Data Sets line and press the + icon. Afterwards, select the **LearnCOBOL** connection as shown in Figure 8b.

12. Select **False - Accept connections with self-signed certificates** to authorize workstation connection as shown in Figure 13.
![](Images/image0005.png)

![](Images/image073.png)
*Figure 8b. Adding LearnCOBOL Connection manually*

*Figure 13. Accept connections with self-signed certifications*
8. Press the LearnCOBOL connection.

13. Press **Enter** for the rest of the prompts to choose the default values
![](Images/image0007.png)

![](Images/image073-1.png)
*Figure 9. Pressing the LearnCOBOL Connection*

![](Images/image073-2.png)

![](Images/image073-3.png)

![](Images/image073-4.png)
9. The connection prompts for a username as shown in Figure 10.

![](Images/image061.png)

*Figure 10. User name prompt*

14. Your connection will be added automatically to the **DATASET** list under **Favorites** as shown in Figure 14.
10. **Please enter the username assigned to you! Do not use the sample username of Z99998.** A sample username, is entered as shown in Figure 11. The ID is assigned by the System Administrator.

![](Images/image078.png)
![](Images/image064.png)

*Figure 14. LEARNCOBOL connection*
*Figure 11. Specified user name*

- Note : *if you click on the + to the far right on the Data Sets selection, another prompt to Create a New Connection to z/OS will appear.*
- any other connections you have will be listed as shown in Figure 15.

![](Images/image080.png)

*Figure 15. connections list*
11. The connection prompts for a password as shown in Figure 12.

![](Images/image067.png)

15. Expansion of LEARNCOBOL reads “Use the search button to display datasets”. Click the search button as shown in Figure 16.
*Figure 12. Password prompt*

![](Images/image082.png)
12. Enter your assigned password as shown in Figure 13.

*Figure 16. Search button*
![](Images/image070.png)

*Figure 13. Specified password*

16. A prompt to "Select a filter" appears for your username. Select the + to "Create a new filter" as shown in Figure 17.
13. Expanding LearnCOBOL shows “Use the search button to display datasets”. Click the magnifying glass icon as shown in Figure 14.

![](Images/image084.png)

*Figure 17. Select a filter*


*Figure 14. Magnifying glass icon to set a filter*

17. A prompt appears to enter the filter name to be searched as shown in Figure 18.
14. A prompt to "Search Data Sets" will appear as shown in Figure 15.

![](Images/image086.png)

*Figure 18. Filter name to be searched*
*Figure 15. Filter name to be searched*



18. Each user has a high-level qualifier that is the same as their username. Therefore, enter your assigned username as the search criteria as shown in Figure 19. **Please use your username, not Z99998!**
15. Each user has a high-level qualifier that is the same as their username. Therefore, enter your assigned username as the search criteria as shown in Figure 16. **Please enter the username assigned to you! Do not use the sample username of Z99998.**

![](Images/image088.png)

*Figure 19. Entered filter name*
*Figure 16. Entered filter name*



19. A list of data set names beginning with your username from z/OS Connection LEARNCOBOL appears as shown in Figure 20.
16. A list of data set names beginning with your username will appear as shown in Figure 17.

![](Images/image090.png)

*Figure 20. Filtered data set names*


*Figure 17. Filtered data set names*

20. Expand **`<USERNAME>.CBL`** to view COBOL source members, then select member **HELLO** to see a simple COBOL ‘Hello World!’ program as shown in Figure 21.
17. Expand **`<USERNAME>.CBL`** to view COBOL source members, then select member **HELLO** to see a simple COBOL ‘Hello World!’ program as shown in Figure 18.

![](Images/image093.png)

*Figure 21. `<USERNAME>.CBL`*
*Figure 18. `<USERNAME>.CBL`*



21. Expand **`<USERNAME>.JCL`** to view JCL and select member HELLO which is the JCL to compile and execute simple ‘Hello World!’ COBOL source code as shown in Figure 22.
18. Expand **`<USERNAME>.JCL`** to view JCL and select member HELLO which is the JCL to compile and execute simple ‘Hello World!’ COBOL source code as shown in Figure 19.

![](Images/image095.png)

*Figure 22. `<USERNAME>.JCL`*


*Figure 19. `<USERNAME>.JCL`*

22. Right-click on JCL member **HELLO**. A section box appears. Select **Submit Job** for the system to process HELLO JCL as shown in Figure 23. The submitted JCL job compiles the COBOL HELLO source code, then executes the COBOL HELLO program.
19. Right-click on JCL member **HELLO**. A section box appears. Select **Submit Job** for the system to process HELLO JCL as shown in Figure 20. The submitted JCL job compiles the COBOL HELLO source code, then executes the COBOL HELLO program.

![](Images/image097.png)

*Figure 23. Submit Job*


*Figure 20. Submit Job*

23. Observe the ‘Jobs’ section in Zowe Explorer as shown in Figure 24.
20. Observe the ‘Jobs’ section in Zowe Explorer as shown in Figure 21.

![](Images/image098.png)

*Figure 24. JOBS section*
*Figure 21. JOBS section*



24. Again, click on the + to the far right on the Jobs selection. The result is another prompt to ‘Create new’. Select **LearnCOBOL** from the list as shown in Figure 25.
21. Again, click on the + to the far right on the Jobs selection. The result is another prompt to ‘Create new’. Select **LearnCOBOL** from the list as shown in Figure 22.

![](Images/image100.png)

*Figure 25. + Select LEARNCOBOL connection*


*Figure 22. Select LearnCOBOL connection*

25. As a result, the JCL jobs owned by your username appear. HELLOCBL is the JCL job name previously submitted. Expand **HELLOCBL** output to view sections of the output as shown in Figure 26.
22. As a result, the JCL jobs owned by your username appear. HELLOCBL is the JCL job name previously submitted. Expand **HELLOCBL** output to view sections of the output as shown in Figure 23.

![](Images/image102.png)

*Figure 26. HELLOCBL output*
*Figure 23. HELLOCBL output*



26. Select **COBRUN:SYSPRINT(101)** to view the COBOL compiler output. Scroll forward in the COBOL compile to locate the COBOL source code compiled into an executable module as shown in Figure 27. Observe the Indicator Area in column 7, A Area beginning in column 8, and B Area beginning in column 12. Also, observe the period (.) scope terminators in the COBOL source.
23. Select **COBRUN:SYSPRINT(101)** to view the COBOL compiler output. Scroll forward in the COBOL compile to locate the COBOL source code compiled into an executable module as shown in Figure 24. Observe the Indicator Area in column 7, A Area beginning in column 8, and B Area beginning in column 12. Also, observe the period (.) scope terminators in the COBOL source.

![](Images/image104.png)

*Figure 27. COBOL compiler output*


*Figure 24. COBOL compiler output*

27. View the COBOL program execution by selecting **COBRUN:SYSOUT(104)** from the LEARNCOBOL in the Jobs section of Zowe Explorer as shown in Figure 28.
24. View the COBOL program execution by selecting **COBRUN:SYSOUT(104)** from the LEARNCOBOL in the Jobs section of Zowe Explorer as shown in Figure 25.

![](Images/image106.png)

*Figure 28. COBOL program execution*


*Figure 25. COBOL program execution*

28. The following URL is another excellent document describing the above VSCode and Zowe Explore details with examples:
25. The following URL is another excellent document describing the above VSCode and Zowe Explore details with examples:
[https://marketplace.visualstudio.com/items?itemName=Zowe.vscode-extension-for-zowe](https://marketplace.visualstudio.com/items?itemName=Zowe.vscode-extension-for-zowe)

## Lab - Zowe CLI & Automation
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file modified COBOL Programming Course #2 - Learning COBOL/Images/image084.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified COBOL Programming Course #2 - Learning COBOL/Images/image100.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.