免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 1544 | 回复: 0
打印 上一主题 下一主题

显示和理解和理解库表 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2012-09-21 09:38 |只看该作者 |倒序浏览
本帖最后由 jiangjinsong 于 2012-09-21 09:46 编辑

Authoravid Mount

########## 请保留下面信息   ####################
出处:http://www.texas400.com/BSliblst.html
翻译:Eric Kong mail:eric_cc@qq.ccom
关键字: 葡萄牙语 Mainframe AS400 Java 广州 求职 招聘 猎头 www.puyufanyi.com
备注:本人Java高级工程师,初学AS400,有好的职位,可以跟我联系,文章如果翻译不正确,敬请提出
################################################

Display and understand your Library List
显示和理解库表

The library list on the AS/400 is similar to the "path" on PC's. Mainframe programmers may compare it to the "steplib" or "joblib". It defines the order of libraries that the operating system uses to find objects.
在AS/400中的库表就像PC的路径,Mainframe的程序员会拿steplib或者joblib来跟它做对比,它定义了操作系统寻找对象的顺序.


When you execute a command or call a program, the AS/400 must know where to find the command or program. Sometimes, you specify the library explicitly. But if you don't, the AS/400 will find your command or program but looking in each library in your library list. It will use the first one that it finds.

当你执行一个命令或者凋用一个程序的时候,AS400必须知道怎么样去寻找这个命令或者程序,有时侯,你必须显性地指出对应的库,假如你没有这样做,AS400会搜索你的库表中的所有的库,调用第一个它所找到的命令或程序.


This is very handy for testing. If you are testing a version of a program, you can put it in a test library which is at the top of your library list. Then, whenever you specify a program or refer to a file, the system will use any object it can find in the test library. If it can't find it there, it will look further through your library list until it finds it.

这对于测试来说非常方便,假如你测试某个版本的程序,你只需要将你测试的库放在你的库表的最上方就可以了,这样一来,当你调用程序的时候,系统就会调用调用测试库来运行,假如找不到,系统会进一步在库表里面找,直至找到.

So, setting up a test environment is as simple as:
1) Create a test library.
2) Put objects that you want to test in the library. These can be files, menus, programs or any AS/400 object.
3) Insert the test library name in your library list before your production libraries.

所以,建立一个测试环境是这样的简单:
1)建立一个测试的库.
2)将所有对象放入你所建的测试库里面,这些可以是文件,菜单,程序或者其他AS400的对象.
3)插入这个测试库到你的库表里面,位于所有生产环境库之前.


Now you can execute test programs and modify test data. The best part is that you don't need to copy production programs or files into the test library unless they will be affected by the test. That is, all those supporting database files that you need to run a program, but that are used for input only, do not need to be copied to the test library. Of course, if you are unsure if a file will be modified during your test procedure, copy it to the test library anyway.

现在你就可以执行程序和修改测试数据了,这里比较好的一点就是,你没有需要复制生产环境的程序或者文件到测试库,除非他们测试后需要被修改,当然了,假如你不能够肯定某些数据在你的测试过程中是否会被修改,那你还是把他们复制到测试库里面去吧.

Once you have inserted the test library name in your library list, you will want to make sure everything is in the proper order. Use the DSPLIBL command to see your library list. You will probably see three types of list entries:

一旦你把测试库放入你的库表中,你必须确定所有这些东西按照正确顺序排列,用DSPLIBL命令去看一下你的库表,你会看到下面3种类型的库

1) The SYS libraries have operating system objects. This is where the AS/400 commands and menus live.
2) The CUR library is your current library. This is your first user library and is where objects are created if you don't specify which library to use.
3) The USR libraries list your other user libraries.

1)SYS系统库,包含了操作系统的对象,AS400命令和菜单的对象就在里面
2)CUR当前库,默认的存放用户库的地方,假如你没有特别的指定,你所建立的库就是放在这里了.
3)USR用户库,列出了你用的其他用户库

Use EDTLIBL to change your USR libraries. You can rearrange the list, remove libraries or add libraries. Notice that you can't see the SYS or CUR libraries when you use EDTLIBL. The only way to change the current library is with the CHGCURLIB command.

用EDTLIBL来修改你的用户库,你可以重新排列这个表,删除库或者添加库,注意到你是不能用EDTLIBL查看系统库和当前库的,你想修改当前库的话,要用CHGCURLIB命令.
The WRKOBJ command will help see which object is being used. This command is similar to the directory ("dir" command on PC's. Use it to list objects in your library list.

WRKOBJ命令帮助你查看你正在使用那些对象,就像你用的PC的dir命令,用它来列出你库表所有的库
So, if you have three copies of a program, "AYCALC", in different libraries, use the command WRKOBJ PAYCALC to see which copy of "AYCALC" will be used. The command will list all objects named "AYCALC" in the sequence that the AS/400 finds them. If you ever say to yourself in frustration, "I know I changed the program but it looks like I'm still running the original program", it's a pretty good bet that you're executing a different copy of the program than you think. This is only a fraction of the power of the WRKOBJ command. It is the easiest way to navigate through an undocumented system.

这样,假如不同的库中,你有程序PAYCALC的三个副本,你可以用命令 WRKOBJ PAYCALC来查看你正在使用哪个库中PAYCALC,这个命令列出AS400按顺序所找到的PAYCALC的对象,假如有这样沮丧的经历,明明修改了某个程序,但是好像总是运行着旧的原来那个.那执行这个命令就十分有用了,这是WRKOBJ命令强大的作用之一,对于那些没有做好文档管理的系统是十分有用的

DSPLIBL - Display complete library list

EDTLIBL - Edit library list

CHGCURLIB - Change Current Library

WRKOBJ - Work with objects (similar to PC "dir"



您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

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

清除 Cookies - ChinaUnix - Archiver - WAP - TOP