问题描述
有来自DFSORT的多个消息,该消息由COBOL程序在内部使用,该程序具有多个排序操作.我想删除那些DFSORT消息,而只保留那些来自COBOL程序的消息.
There are several messages from DFSORT, which is internally used by the COBOL program that has several sort operations. I would like to remove those DFSORT messages and retain only those from the COBOL program.
推荐答案
您有三个选择.
使用OUTDD(ddname)Enterprise COBOL编译器选项来更改用于DISPLAY输出的DDName.
Use the OUTDD(ddname) Enterprise COBOL compiler option to change the DDName used for DISPLAY output.
使用您发现的DFSPARM来更改从程序调用(调用)时SORT用于其消息的DDName(例如在COBOL中使用SORT或MERGE动词时).
Use the DFSPARM as you have discovered, to change the DDName SORT uses for its messages when it is invoked (called) from a program (as when using the SORT or MERGE verbs in COBOL).
使用SORT-MESSAGE特殊寄存器.
Use the SORT-MESSAGE special-register.
如果SORT是独立的,则还可以使用OPTION控制语句OPTION MSGDDN=ddname
更改SORT消息文件. DFSPARM是允许为调用的SORT/MERGE提供OPTION的方法.
If your SORT was stand-alone, you could also change the SORT messages file with using the OPTION Control Statement, OPTION MSGDDN=ddname
. DFSPARM is the way to allow OPTION to be provided for an invoked SORT/MERGE.
您还具有语言环境,该语言环境可以在运行单元期间使用SYSOUT来接收来自语言环境的消息(运行时错误,异常终止,请求的信息).有一个MSGFILE(ddname)运行时选项,可让LE使用其他ddname.
You also have Language Environment which can use SYSOUT during the run-unit, for messages from Language Environment (run-time errors, abends, requested information). There is a MSGFILE(ddname) run-time option to get LE to use a different ddname.
解决您问题的最简单方法是使用OUTDD(ddname)编译器选项.然后,您不必担心DFSORT(或其他站点上的SyncSORT)或语言环境.
The easiest resolution to your problem is to use the OUTDD(ddname) compiler option. Then you don't have to worry about DFSORT (or SyncSORT at a different site) or Language Environment.
您可以使用MSGPRT选项禁止显示所有DFSORT消息.通过为每个调用指定一个带有FREE = CLOSE的DFSPARM DD,可以不同地对待DFSORT的多个调用.
You can suppress all DFSORT messages with the MSGPRT option. You can treat multiple invocations of DFSORT differently by specifying a DFSPARM DD with FREE=CLOSE for each invocation.
这篇关于如何从SYSOUT删除DFSORT消息的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!