This article mainly tells you about the notes for DB2 batch update. If you are interested in the actual operations related to the notes for DB2 batch update, you can click to view the following articles. The following is a detailed description of the main content of the article. I hope you will have a better understanding of it after browsing.
Batch update of the DB2 client seems that at most 64 kB SQL statements can be sent to the database at a time. The following error may occur:
Batch update of the DB2 client seems that at most 64 k characters of SQL can be sent to the database at a time.
The following errors may occur, for example:
- db2 ? sql954
- SQL0954C Not enough storage is available in the application heap
- to process the statement.
- Explanation:
- All available memory for the application has been used.
- The statement cannot be processed.
- User Response:
- Terminate the application on receipt of this message. Increase
- the database configuration parameter ( applheapsz ) to allow a
- larger application heap.
- sqlcode : -954
- sqlstate : 57011
You need to set the heap size of the DB2 application.
Http://fanqiang.chinaunix.net/db/db2/2005-07-20/3430.shtml
4.8 check which databases under this instance
- db2 LIST DATABASE DIRECTORY [ on /home/db2inst1 ]
4.9 view and modify the configuration of the database head
Note that, in most cases, after the data configuration is changed, it takes effect only after all connections are disconnected.
View DB2 batch update considerations head preparation
- db2 get db cfg for head
Change the value of a database head setting.
4.9.1 change the size of the sorting heap
- db2 update db cfg for head using SORTHEAP 2048
Change the size of the sorting heap to 2048 pages. It is better to set this value to a greater value for applications with more queries.
4.9.2 modify the transaction log size
- db2 update db cfg for head using logfilsiz 40000
The size of this item must be compatible with the transaction processing of the database. if the transaction is large, it should be changed to a larger value. Otherwise, it is easy to handle errors with full log files.
4.9.3 modify the program heap memory size when the program heap memory is insufficient
- db2 update db cfg for head using applheapsz 40000
The value cannot be too small, otherwise there will be insufficient memory to run the application.
4.10 view and modify database instance configurations
View DB2 batch update instance configurations
- db2 get dbm cfg
Change database instance Configuration
4.10.1 enable monitoring of lock conditions.
- db2 update dbm cfg using dft_mon_lock on
4.10.2 change the diagnostic error capture level
- db2 update dbm cfg using diaglevel 3
0 indicates that no information is recorded.
1 indicates that only errors are recorded.
2. Record service and non-service errors
The default value is 3, which records db2 errors and warnings.
4. Record all information, including information about successful execution.
Generally, do not use 4, which will lead to a very slow running speed of db2.
The above content is an introduction to the notes for DB2 batch update. I hope you will get some benefits.