• 软件测试技术
  • 软件测试博客
  • 软件测试视频
  • 开源软件测试技术
  • 软件测试论坛
  • 软件测试沙龙
  • 软件测试资料下载
  • 软件测试杂志
  • 软件测试人才招聘
    暂时没有公告

字号: | 推荐给好友 上一篇 | 下一篇

tips:Record Locks

发布: 2007-6-08 22:43 | 作者: seanhe | 来源: | 查看: 21次 | 进入软件测试论坛讨论

领测软件测试网
by Barbara Morris

If you are processing records in a primary file and you want to just skip any records that get input errors, you can code an INFSR subroutine for the file. On the ENDSR of the subroutine, code '*GETIN'. That will cause control to go to the part of the cycle that gets the next record.
[code:1:cffb8a82d5]
Fmyfile    ip   e             disk    infsr(myinfsr)
C     myinfsr       begsr
C                   ... file error
C                       endsr     '*GETIN'[/code:1:cffb8a82d5]
If you also want to ignore program errors encountered when processing the data in a record, code a *PSSR subroutine the same way. If you don't have any file-specific processing in your INFSR subroutine, you can use the *PSSR as the INFSR.
[code:1:cffb8a82d5]
Fmyfile    ip   e             disk    infsr(*pssr)
C     *pssr         begsr
C                   ... general error
C                   endsr     '*GETIN'[/code:1:cffb8a82d5]
If you don't always want to just go straight to the next record, you can soft-code the return point on the ENDSR.
[code:1:cffb8a82d5]
Fmyfile    ip   e             disk    infsr(myinfsr)
D infsrEnd        s              6a
D recordLock      c                   1218
C     myinfsr       begsr
C                   eval      infsrEnd = '*CANCL'
C                   if        %status(myfile) = recordLock
C                   eval      infsrEnd = '*GETIN'
C                   endif
C                   endsr     infsrEnd
 [/code:1:cffb8a82d5]

【发表回复】【查看CU论坛原帖】【添加到收藏夹】【关闭】
 michael9406 回复于:2003-12-31 14:33:38
这么好的贴子是该设为精华了。

 yoyoage 回复于:2003-12-31 15:17:31
:oops: 没错,可是 :em06: ,不是原创阿 :em06: 。。。
多谢老大鼓励~

 stephenxie2003 回复于:2003-12-31 16:11:13
鼓励鼓励!
 :)

 riancy1106 回复于:2003-12-31 16:51:31
永远支持

 sean810 回复于:2004-01-02 09:21:54
Very Good!

 yj2yq 回复于:2004-01-02 09:43:28
支持!大家一起来!

 stephenxie2003 回复于:2004-01-02 14:38:34
建议:
用中文也写一下吧!
来个双语版的!

 yoyoage 回复于:2004-01-02 15:31:54
有时间写好了再给大家:----我担心的是,英文的海勉强可以看懂,被我一折腾成中文的,就没人看懂了HOHO~

 andrewleading_he 回复于:2004-01-03 16:16:23
支持!

延伸阅读

文章来源于领测软件测试网 https://www.ltesting.net/


关于领测软件测试网 | 领测软件测试网合作伙伴 | 广告服务 | 投稿指南 | 联系我们 | 网站地图 | 友情链接
版权所有(C) 2003-2010 TestAge(领测软件测试网)|领测国际科技(北京)有限公司|软件测试工程师培训网 All Rights Reserved
北京市海淀区中关村南大街9号北京理工科技大厦1402室 京ICP备2023014753号-2
技术支持和业务联系:info@testage.com.cn 电话:010-51297073

软件测试 | 领测国际ISTQBISTQB官网TMMiTMMi认证国际软件测试工程师认证领测软件测试网