[转]DB2 load参数
本文持续更新,LOAD如何提高parallelism。LOAD SHRLEVEL CHANGE的性能提高。
===========================
Every once in a while I completely miss a feature added to DB2. This time I missed what I would call a biggie; a way to significantly improve the performance of your DB2 UNLOAD and LOAD utilities.
Sometime the middle of last year, around May 2011, APAR PM19584 arrived for DB2 9 for z/OS and DB2 10 for z/OS that added the FORMAT INTERNAL keyword to both the DB2 UNLOAD and LOAD utilities.
If the DB2 UNLOAD utility is run with the FORMAT INTERNAL option, the data is unloaded in DB2’s internal format, nothing at all happens to the data during the unload process. No data or CCSID conversions are performed and any field specifications are ignored. There are additional warnings and restrictions listed in the “DB2 10 Utility Guide and Reference” (SC19-2984) product publication.
Using a file created by the UNLOAD utility that specified FORMAT INTERNAL as input to the LOAD utility, also specifying FORMAT INTERNAL as an option on the LOAD, has the potential of significantly improving the LOAD’s performance because there is no validation of the data performed on the input file. DB2 assumes the input is in DB2’s internal format and will perform no data conversions and ignores any field specifications. Again, additional detail about using the FORMAT INTERNAL option on the LOAD utility can be found in the “DB2 10 Utility Guide and Reference” (SC19-2984) product publication.
The DB2 catalog table SYSIBM.SYSCOPY will reflect that the LOAD used an input in a DB2 internal format. If ICTYPE is “Y” for LOAD LOG(NO) or “Z” for LOAD LOG(YES), TTYPE is set to an “I” to indicate that the FORMAT INTERNAL option was specified for that LOAD.
If you have a need to unload data from a table that will only be used to load a table that has the exact same structure, this could be the performance options you’re looking for.
Check it out. I think you’ll like it if it fits your situation.
BTW, the above APAR also introduced the LOAD utility option PRESORTED YES. When specified, the LOAD assumes the input is in clustering key order. Because the input is in clustering key order, LOAD can skip any sorts for the clustering index. This also has the potential for some significant performance improvements.
posted on 2014-12-03 14:47 hackergodness 阅读(955) 评论(0) 编辑 收藏 举报