DB2 UDB Evaluation Guide for Linux and Windows
Total Page:16
File Type:pdf, Size:1020Kb
Front cover DB2 UDB Evaluation Guide for Linux and Windows Install and configure DB2 UDB V8.1 for Linux and Windows Build a Web-based application using DB2 UDB and PHP Explore the new features of DB2 UDB V8.1 Whei-Jen Chen Angus Beaton David Kline Glen Johnson ibm.com/redbooks International Technical Support Organization DB2 UDB Evaluation Guide for Linux and Windows April 2003 SG24-6934-00 Note: Before using this information and the product it supports, read the information in “Notices” on page xvii. First Edition (April 2003) This edition applies to DB2 Universal Database Version 8.1 for use with SuSE Linux Version 8.1, Red Hat Linux Version 8.0, and Windows 2000 operating systems. © Copyright International Business Machines Corporation 2003. All rights reserved. Note to U.S. Government Users Restricted Rights -- Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp. Contents Figures . .ix Tables . xv Notices . xvii Trademarks . xviii Preface . xix The team that wrote this redbook. xxi Acknowledgement. xxii Become a published author . xxii Comments welcome. xxiii Chapter 1. Introduction to DB2 . 1 1.1 DB2 UDB features. 2 1.2 Version 8 highlights . 4 1.3 DB2 database objects . 6 1.4 DB2 UDB architecture and processes. 10 1.5 Accessing and updating DB2 data . 12 Chapter 2. Installation. 15 2.1 Obtaining the DB2 trial code . 16 2.1.1 Downloading DB2 . 16 2.1.2 Downloading the DB2 documentation. 17 2.2 Installing DB2 on Linux . 18 2.2.1 Installation requirements . 19 2.2.2 Installation preparation . 20 2.2.3 Installing DB2 . 20 2.2.4 Installing the DB2 Application Development Client . 27 2.2.5 Post installation . 30 2.3 Installing DB2 on Windows . 32 2.3.1 Installation requirements . 33 2.3.2 Installation preparation . 33 2.3.3 Installation . 34 2.3.4 Post installation . 36 2.4 Advanced installation . 42 2.4.1 Using a generated response file . 43 2.4.2 Using db2_install. 45 2.4.3 RPM command . 46 © Copyright IBM Corp. 2003. All rights reserved. iii Chapter 3. Navigating DB2 with GUIs . 47 3.1 Introduction to GUI tools . 48 3.2 Control Center . 48 3.3 Command Center . 51 3.3.1 Interactive and Query Results tabs . 52 3.3.2 Script tab . 55 3.3.3 Access Plan tab . 62 3.4 Configuration Advisor . 64 3.5 Design Advisor . 66 3.6 Task Center. 68 3.7 Journal. 82 3.7.1 Task History tab . 83 3.7.2 Database History tab. 84 3.7.3 Messages tab . 89 3.7.4 Notification Log tab . 91 3.8 Health Center and Memory Visualizer. 91 3.8.1 Health Center . 93 3.8.2 Memory Visualizer. 103 3.9 Development Center . 104 3.10 Configuration Assistant . 106 3.11 Replication Center. 107 3.12 Information Center. 109 Chapter 4. DB2 Order Entry Web Application. 111 4.1 Application description . 112 4.1.1 The Apache Web Server. 112 4.1.2 Redbooks ordering - Web shopping cart application . 113 4.2 Application setup - Linux . 114 4.2.1 Preparation . 114 4.2.2 Setup database . 115 4.2.3 Setup Apache Web Server . 116 4.2.4 Verify Web Server setup . 118 4.3 Application setup - Windows . 122 4.3.1 Setup Apache Web Server . 122 4.3.2 Setup database . 123 4.3.3 Setup PHP . 125 4.3.4 Verify Web Server Setup. 127 4.4 Using the DB2 Web application. 130 4.4.1 Order Entry application . 131 4.5 Understanding the DB2/PHP Web application code . 139 Chapter 5. Application development . 147 5.1 Preparing for application development . 148 iv DB2 UDB Evaluation Guide for Linux and Windows 5.1.1 Creating a development environment . 148 5.1.2 Connecting DB2 applications . 149 5.2 DB2 Development Tools . 151 5.2.1 DB2 Development Center . 151 5.2.2 DB2 Project Deployment Tool. 151 5.2.3 DB2 Command Center . 152 5.2.4 SQL Assist . 152 5.2.5 Visual Explain . ..