You create a channel by naming it on one of the following commands:
If the channel doesn't already exist, within the current program scope, it is created.
The most straightforward way to create a channel, and populate it with containers of data, is to issue a succession of EXEC CICS PUT CONTAINER(container-name) CHANNEL(channel-name) FROM(data_area) commands. The first PUT command creates the channel (if it doesn't already exist), and adds a container to it; the subsequent commands add further containers to the channel. If the containers already exist, their contents are overwritten by the new data.
An alternative way to add containers to a channel is to move them from another channel. To do this, use the following command:
EXEC CICS MOVE CONTAINER(container-name) AS(container-new-name)
CHANNEL(channel-name1) TOCHANNEL(channel-name2)
You can use MOVE CONTAINER, instead of GET CONTAINER and PUT CONTAINER, as a more efficient way of transferring data between channels.
If the channel named on the following commands doesn't already exist, within the current program scope, an empty channel is created: