DB2创建表空间是学习DB2数据库过程中必须要经过的一关,下文为您介绍的DB2创建表空间方法是在windows下实现的,希望对您学习DB2创建表空间方面有所帮助。
- db2set db2codepage=819
- db2 create database test03
- db2 connect to test03 user db2amdin using 1
- db2 CREATE Bufferpool USER8 SIZE 100000 PAGESIZE 8K
- db2 CREATE Bufferpool USER16 SIZE 1000 PAGESIZE 16 K
- db2 CREATE Bufferpool USER32 SIZE 1000 PAGESIZE 32 K
- db2stop force
- db2start
- db2 connect to test03 user easymis using easymis
- db2 "CREATE REGULAR TABLESPACE TS_USER8 PAGESIZE 8K MANAGED BY SYSTEM USING ('FSMS_8K_1') BUFFERPOOL USER8"
- db2 "CREATE REGULAR TABLESPACE TS_USER16 PAGESIZE 16K MANAGED BY SYSTEM USING ('FSMS_16K_1') BUFFERPOOL USER16"
- db2 "CREATE REGULAR TABLESPACE TS_USER32 PAGESIZE 32K MANAGED BY SYSTEM USING ('FSMS_32K_1') BUFFERPOOL USER32"
- db2 GRANT DBADM,CREATETAB,BINDADD,CONNECT ON DATABASE TO USER EASYMIS
- db2 GRANT DBADM,CREATETAB,BINDADD,CONNECT,LOAD ON DATABASE TO USER EASYMIS
- db2 connect to test03 user easymis using easymis
- db2 -f dbstruct.sql >kk.log
以上就是windows下DB2创建表空间的实现方法。
【编辑推荐】
B2常用函数详解大全