免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
楼主: i400as
打印 上一主题 下一主题

RCVF的用法 [复制链接]

论坛徽章:
0
11 [报告]
发表于 2008-12-08 14:43 |显示全部楼层
9999 太长了,200就够了.

论坛徽章:
0
12 [报告]
发表于 2008-12-08 15:00 |显示全部楼层
直接把参数给ENDJOB

如果不活动,什么也没发生.

论坛徽章:
0
13 [报告]
发表于 2008-12-08 15:00 |显示全部楼层
我这里看到JOB NUMBER 是从29位开始的.

论坛徽章:
0
14 [报告]
发表于 2008-12-08 15:02 |显示全部楼层
wrkactjob 加NAME参数,

然后如果有数据就可以把这个JOB END掉?

论坛徽章:
0
15 [报告]
发表于 2008-12-08 15:07 |显示全部楼层
*LDA  不用,用 *PGA  试试.

论坛徽章:
0
16 [报告]
发表于 2008-12-08 15:20 |显示全部楼层
你DEBUG 看看LDA 和你的PF有多大差别. 估计是PF内容造成.

论坛徽章:
0
17 [报告]
发表于 2008-12-08 15:22 |显示全部楼层
WRKACTJOB JOB(jobname)


如果为空就表示你要的JOB不是ACTIVE,
反之就可以删除, 而且这样做得到的PF内容比较规整.

论坛徽章:
0
18 [报告]
发表于 2008-12-08 15:34 |显示全部楼层
The Retrieve Data Area (RTVDTAARA) command is used in a CL program or REXX procedure to retrieve all or part of a specified data area and copy it into a variable. RTVDTAARA does not retrieve any other attributes of the data area. Existence of the data area is not required at the time the CL program is compiled.

If the job is a group job, the data area specified may be the group data area (*GDA). This data area is automatically associated with the group, and it is inaccessible from jobs outside the group. The length of this character data area is 512 bytes.

A local data area (*LDA) is a character data area that is 1024 bytes in length, and it is automatically associated with the job. Another job cannot access the local data area.

If the job is a prestart job, the data area specified may be the data area that contains program initialization parameter data (*PDA). This data area is automatically associated with the prestart job and is inaccessible from other jobs. The length of this character data area is 2000 bytes.

When a data area other than a local data area, group data area, or program initialization parameter data area must be retrieved during the processing of the RTVDTAARA command, the data area is locked during the retrieval operation so that commands in other jobs cannot change or destroy it until the operation is complete. If the data area is shared with other jobs and is updated in steps involving more than one command in a job, the data area should be explicitly allocated to that job until all the steps have been performed. A data area other than a local data area, group data area, or program initialization parameter data area can be explicitly allocated with the Allocate Object (ALCOBJ) command. No allocation is necessary for a local data area, group data area, or program initialization parameter data area.

Restrictions

1. To use this command, the user must have *USE authority for the data area and *EXECUTE authority for the library where the data area is located. No specific authority is required to retrieve the value of a local data area or group data area.

2. This command is conditionally threadsafe. The following restrictions apply:
   a. Retrieving DDM data areas in a job that allows multiple threads is not threadsafe.
   b. Retrieving DDM data areas will fail when more than one thread is active in a job.


是不是你的WRKACTJOB 得到的结果太长了? *LDA 只有1024字节.

论坛徽章:
0
19 [报告]
发表于 2008-12-08 15:37 |显示全部楼层
Assume data area DA1 has been created by the following command:

CRTDTAARA DTAARA(DA1) TYPE(*CHAR) LEN(3) VALUE(ABC)

and variable &CLVAR1 has been declared as:

DCL VAR(&CLVAR1) TYPE(*CHAR) LEN(5) VALUE(VWXYZ)



Example 1: Retrieving a Character Data Area

RTVDTAARA DTAARA(DA1) RTNVAR(&CLVAR1)

results in: &CLVAR1 = ’ABC ’


Example 2: Retrieving a Subset of a Character Data Area

RTVDTAARA DTAARA(DA1 (2 1)) RTNVAR(&CLVAR1)

results in: &CLVAR1 = ’B   ’



Example 3: Retrieving a Decimal Data Area Assume data area DA2 has been created with the following attributes:

CRTDTAARA DTAARA(DA2) TYPE(*DEC) LEN(5 2) VALUE(12.39)

and variable &CLVAR2 has been declared as:

DCL VAR(&CLVAR2) TYPE(*DEC) LEN(5 1) VALUE(4567.

Running this command:
RTVDTAARA DTAARA(DA2) RTNVAR(&CLVAR2)

results in: &CLVAR2 = 0012.3

Note: Fractional digits are truncated instead of rounded.

希望对你有帮助.

论坛徽章:
0
20 [报告]
发表于 2008-12-08 15:43 |显示全部楼层
Example 3: Changing Specific Characters of the Local Data Area

CHGDTAARA DTAARA(*LDA (5 4)) VALUE(’TWO’)

This command changes characters 5 through 8 of the user’s local data area.
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP