我们在项目开发时,有几个存储过程的脚本比较长有100K左右,在db2clp里执行“db2 -td@ -vf xxxx.sql”总是不成功,但通过其他工具如questcenter等是可以执行的,我也试过调节db2clp的客户端的缓存设置,但依然保存,各位老大,有啥办法可以使长脚本在db2clp里执行?
------解决方案--------------------------------------------------------
报什么错说下啊
------解决方案--------------------------------------------------------
up
------解决方案--------------------------------------------------------
顶
------解决方案--------------------------------------------------------
up
------解决方案--------------------------------------------------------
请看:
http://www-1.ibm.com/support/docview.wss?rs=71&context=SSEPGG&q1=sql+length&uid=swg21181258&loc
DB21006E The input command is too long. The maximum length is 65535.
Technote (FAQ)
Problem
DB2 v8.2 introduces a new feature that allows statements longer than 64 kilobytes to be processed by the database server. The limit has been increased to 2 megabytes. However, if you try to process a statement longer than 64 kilobytes via CLP or the Command Center, DB21006E is returned.
Cause
Although the database server now accepts statements up to 2 megabytes to be processed, this feature has not yet been propagated to CLP and the Command Center. For these tools, the maximum size a statement can have is still limited to 64 kilobytes.
Solution
The 64 kilobyte limit for statement size on DB2 tools such as CLP and the Command Center is planned to be lifted in an upcoming release of DB2. You can use another application that uses static or dynamic SQL to issue statements longer than 64 kilobytes.