Home PC Games Linux Windows Database Network Programming Server Mobile  
           
  Home \ Database \ DB2 manually create a library     - Bash Automated Customization Linux belongs to its own CentOS system (Linux)

- AngularJS application unit testing started (Programming)

- Linux systems for entry-learning - Install Go language in Linux (Linux)

- Linux using TCP-Wrapper Service Management (Linux)

- OpenGL ES 3.0 vertex buffer (Programming)

- Debian installation (Linux)

- Linux environment MySQL master-slave synchronization (Database)

- MySQL Tutorial: Philosophical Reflections on the unauthenticated user (Database)

- Linux Kernel 4.2 Installation Instructions (Linux)

- Hadoop 0.23 compile common errors (Server)

- Manually generate AWR reports (Database)

- How to configure SNMPv3 on Ubuntu, CentOS and Cisco systems (Linux)

- Automatic and Manual Proxy Settings Switch GNOME Shell Extension Proxy Switcher Recommend (Linux)

- Linux Shell Scripting Interview Question (Linux)

- How dependent on Fedora, CentOS, RHEL check RPM packages (Linux)

- Git Rebase Tutorial: Using Git Rebase turn back the clock (Linux)

- Arrow keys, backspace key garbled in Python-2.7.5 Interactive Mode under CentOS 5.8 (Linux)

- CentOS / RedHat system partition essential requirements and partition scheme (Linux)

- Installation of JDK and Tomcat under Linux (CentOS) (Linux)

- Java by Spy Memcached to cache data (Programming)

 
         
  DB2 manually create a library
     
  Add Date : 2018-11-21      
         
         
         
  DB2 database manually create very simple.

Create a database example:
  1. Generate database storage directory, and the archive directory
      mkdir -p / demo / sample
      mkdir -p / demo / samplearc
 2. Generate sample database
    db2sampl -dbpath / demo / sample
 3. Specify the database archive directory
    - DISK: a magnetic disk TSM: refers to the IBM TSM VENDOR: refers to the third-party storage device
      db2 update db cfg for SAMPLE using LOGARCHMETH1 DISK: / demo / samplearc


Other database creation:

1. Find a database created by default path
  # ./db2 Get dbm cfg | grep "DFTDBPATH"
 Default database path (DFTDBPATH) = / home / db2inst1
Of course, you can manually specify when creating
  // Create database mydb on d: data


2. Create a database
  A simple example:
    create database xcldb using codeset gbk territory cn;


  Code pages and sort order parameters:
  All db2 character type (char varchar clob dbclob) has an associated character code page
  That table, the data stored in the database into a binary database.
    Chinese code page 1386 codeset is GBK, Territory of CN
  Generate a file:
  Creates three default table space, logs, configuration information, history files
    SYSCATSPACE data dictionary
    TEMPSPACE1 temporary table space
    USERSPACE1 store all user objects (tables, indexes).
  Before dbv9 default table space for the sms, then, in addition to the other default temporary table space for the table space dms


More complex example:
  create database xcldb
  DFT_EXTENT_SZ 4
  CATALOG TABLESPACE MANAGED BY DATABASE USING
  (FILE 'C: DATA CATALOG.DAT' 2000, FILE 'D: DATA CATALOG.DAT' 2000)
  EXTENTSIZE 8
  PREFETCHSIZE 16
  TEMPORARY TABLESPACE MANAGED BY SYSTEM USING
  ( 'C: TEMPTS', 'D: TEMPTS')
  USER TABLESPACE MANAGED BY DATABASE USING
  (FILE 'C: XCLDB USERTS.DATA' 1200)
  EXTENTSIZE 24
  PREFETCHSIZE 48
 
  --DFT_EXTENT_SZ 4 default extent size is 4 pages
  --CATALOG TABLESPACE MANAGED BY DATABASE USING cataloged by the database management space
  - ( 'C: TEMPTS', 'D: TEMPTS') Temporary table space will be split across two files.
  - (FILE 'C: TS USERTS.DATA' 1200) This space is only a container. The 1200 page composition
  --EXTENTSIZE 24 user table space is 24 pages EXTENTSIZE
  When --PREFETCHSIZE 48 inquiries, pre-read 48 pages
     
         
         
         
  More:      
 
- Talking about modern programming language syntax and standard library tightly bound phenomenon (Programming)
- Android Get App version number and version name (Programming)
- Cacti monitoring service Nginx (Linux)
- Hibernate in profile (Database)
- Graphic Git (Linux)
- Locale files under Ubuntu (Linux)
- Linux security settings Basics (Linux)
- JBoss7 configuration - Supports IPv4 and IPv6 dual-stack environment (Server)
- Windows Server 2012 R2 Datacenter install SQL Server 2016 CTP (Database)
- How to use secure FTP file transfer (Server)
- RHEL6 install Python and other packages from source (Linux)
- Install MATE desktop environment adjustment tools Mate Tweak 3.3.6 (Linux)
- VNC configuration detailed analysis under Linux (Linux)
- MariaDB phpMyAdmin installation and configuration issues to resolve under CentOS7 (Database)
- CentOS 7 RHEL 7 to reset the root password (Linux)
- Linux start the process (Linux)
- CentOS 7.0 Experience with previous versions (Linux)
- Compare several ways to transfer files between Linux hosts (Linux)
- How to restart after a crash Cinnamon (Linux)
- Ubuntu Tutorial: How to Upgrade a New Linux Kernel 3.12.7 on Ubuntu (Linux)
     
           
     
  CopyRight 2002-2020 newfreesoft.com, All Rights Reserved.