IBM(R) DB2(R) Universal Database у`N i) Copyright International Business Machines Corporation 2000 - 2003. All rights reserved. ϓ i) ii) wъ DB2 Universal Database у 7 FixPak у`NI I Ѳ у 7 у`N ~`N Aъ Solaris @~ DB2 у 7 CPU Red Flag Linux Ճyєʡѓ{ ծM Linux DB2 for Linux [yєʐ]w PTX Wա Microsoft Internet Explorer W񋛦D \Ӽy Netscape CD H DB2 UDB XML Readme ~ DB2 у 7.2 sW Business Intelligence [j\ FixPak 2A Psуb IBM DB2 OLAP Server oсD ъ WebSphere 3.5.5 񔛤qHW Veritas AIX Volume Manager AIX V4 W Java ъ{ѝnѓ{ Ю NFS DAdb2stop b AIX 5 @~tWݥ uWѾ]HTMLBPDF PujMv^ Windows 2000 @~t Web s b Solaris @~UjM DB2 uWۛT 񙗽 NetQuestion for OS/2 Hъ TCP/IP ʛ Netscape с~T UNIX tW Adobe Acrobat Reader [cD SQL Reference „@ PDF II wP[c @٪wB[cۛT Uʪ DB2 qw۫] Linux on S/390 is DB2 EE DB2 Connect EE wM L DB2 Connect ۛT b SuSE Linux Ww DB2 Solaris @~ʖB~nΩh b AIX Ww DB2 Enterprise-Extended Edition AIX CICS ъB~wBJ Netscape LDAP ϓ XR Netscape LDAP Windows MEBWindows XP M Windows 2000 Datacenter Edition ѡx Windows XP Windows ME Windows 2000 Datacenter Server b Windows 95 w DB2 b Windows 2000 Ww DB2 b Windows 2000 Terminal Server ̝zʪU DB2 Microsoft SNA Server M SNA hs (ѼqTw) Windows NT (CS/NT) IBM Communications Awqъ ID Mq X `Iwq pGi퀤хsAh DB2 w|_ b Windows 2000 Wъ CLP oс~ SQL1035N HSOswqӛD Windows 2000 IPX/SPX qHw 񂻚 DB2 e@eѲ DB2 { YwwѪ DB2 ~Abw DB2 ߛ db2iupdt ]w Linux H DB2 DB2 Universal Database Enterprise Edition DB2 Connect Enterprise Edition for Linux on S/390 Linux for S/390 WiӬ۫y Linux W DB2 Gnome M KDE ӡҪX Solaris {[cЅ (ϑ) DB2 Universal Database Enterprise - Extended Edition for UNIX ͐tJ HP-UX shmseg Ѕ IBM Visual x۫w ъ db2uiddl Oӛ@ 64 AIX уw~ ъ SMIT ӗoс~ IBM(R) DB2(R) Connect vʛ ъuvvwzvX]wv ъ db2licm OwzvX]wv 񔗝wv`N sx۫w b AIX 5 Wъ IBM e-server p690 DB2 UDB у 7 Enterprise Edition UNIX CD-ROM ъ~ DB2 Connect Enterprise Edition UNIX CD-ROM ъ~ UNIX W Merant Driver Manager DB2 UDB у 7 ODBC X{ w Web ۛTeѝn[[c rXyۛT - ѓ DB2 Data Links Manager ͐tJ AIX 5.1 W Dlfm ʛЛTGo afsfid roс~ ]wѸOs Tivoli Storage Manager O DFS qʛ{탦D b AIX ۫΀̝z{߀{ wM[c DB2 Data Links Manager for AIXG DCE-DFS ʩB~w `N Ь "dlfm add_prefix" O ͿѾGs`n{b dlfm 񯫂S wM[c DB2 Data Links Manager for AIXGъ db2setup ъ{b AIX Ww DB2 Data Links Manager wM[c DB2 Data Links Manager for AIXGDCE-DFS ߩmw@~ wM[c DB2 Data Links Manager for AIXGъ Smit ԛw DB2 Data Links Manager wM[c DB2 Data Links DFS qʛ{ wM[c DB2 Data Links Manager for Solaris @~t b Windows NT W۫ Administrator sMъv N Data Links File System Filter (DLFF) wO bwߛOT N Sun Solaris tWO@~Yp DATALINK _m Data Links Manager ъ SMIT Лw DLFM Ѿi|hB~› }le/MwDqW ъ DB2 Data Links File ManagerGq DB2 ۫w DB2 Data Links Manager ߬M@ dlfm Client_conf 󫑫ъ@ DLFM1001E (s~T) DLFM ]w[c _mΫioсD b AIX W Data Links/DFS Script dmapp_prestart oс~ Tivoli Space Manager P Data Links ҪX \ӡ 4 wM[c DB2 Data Links Manager for AIX @٪w`N 6 . AIX Ww NFS 񬀩пMޫ wP[cR۫ 5 b UNIX @~tWw DB2 q HP-UX {[cЅ 12 zvъ{ ъ Run-Time Client s۫wъ{ UNIX qъ ODBC s DB2 24 ]mpXt˪sh۫ pXt pGъ DB2 у 8 ۫Ahn FixPak 8 sу w DB2 Relational Connect 24 ]mpXt˪sh۫ 26 s Oracle ۫ Ѿ~ ъ LOB nκKD s Sybase ۫ sW Sybase ۫pXA w Sybase rX ъ ODBC s Microsoft SQL Server ۫]sW`^ sW Microsoft SQL Server ۫pXA d Microsoft SQL Server rX („Aъ Windows NT) s Informix ۫]sW`^ sW Informix ۫pXA III ̝z Administration Guide Update Available Administration Guide: Planning (Lլ) Chapter 8. Physical Database Design Table Space Design Considerations Partitioning Keys Appendix D. Incompatibilities Between Releases Error SQL30081N Not Returned When Lost Connection Is Detected Export Utility Requires FixPak 7 or Later to Properly Handle Identity Attributes Appendix E. National Language Support (NLS) Country/Region Code and Code Page Support Import/Export/Load Considerations -- Restrictions for Code Pages 1394 and 5488 Datetime Values Administration Guide: Implementation (Lլ) New Method for Specifying DMS containers on Windows 2000 and Later Systems Example for Extending Control Center Administration Guide: Performance (Lլ) System Temporary Table Schemas Chapter 8. Operational Performance Block- Based Buffer Pool Chapter 10. Scaling Your Configuration Through Adding Processors Problems When Adding Nodes to a Partitioned Database Chapter 13. Configuring DB2 Log Archive Completion Now Checked More Frequently Correction to Collating Information (collate_info) Section DB2 Registry and Environment Variables Corrections to Performance Variables New Parameters for Registry Variable DB2BPVARS Corrections and Additions to Miscellaneous Registry Variables Corrections and Additions to General Registry Variables Administering Satellites Guide and Reference (Lլ) Setting up Version 7.2 DB2 Personal Edition and DB2 Workgroup Edition as Satellites Prerequisites Configuring the Version 7.2 System for Synchronization Installing FixPak 2 or Higher on a Version 6 Enterprise Edition System Upgrading a Version 6 and P̝z Command Reference (Lլ) Update Available db2updv7 - Update Database to Version 7 Current Fix Level Additional Context for ARCHIVE LOG Usage Note REBIND RUNSTATS db2inidb - Initialize a Mirrored Database Usage Information db2relocatedb (new command) db2relocatedb - Relocate Database db2move Database Movement Tool Additional Option in the GET ROUTINE Command GET ROUTINE CREATE DATABASE Data Recovery and High Availability Guide and Reference (Lլ) Data Recovery and High Availability Guide and Reference Available Online New Archive Logging Behavior How to Use Suspended I/O for Database Recovery New Backup and Restore Behavior When LOGRETAIN=CAPTURE Incremental Backup and Recovery - Additional Information NEWLOGPATH2 Now Called DB2_NEWLOGPATH2 Choosing a Backup Method for DB2 Data Links Manager on AIX or Solaris Operating Environment Tivoli Storage Manager -- LAN Free Data Transfer Data Movement Utilities Guide and Reference (Lլ) Extended Identity Values Now Fully Supported by Export Utility Change to LOB File Handling by Export, Import, and Load IXF Considerations Code Page Support for Import, Export and Load Utilities Chapter 2. Import Using Import with Buffered Inserts Chapter 3. Load Pending States After a Load Operation Load Restrictions and Limitations totalfreespace File Type Modifier Chapter 4. AutoLoader AutoLoader Restrictions and Limitations Using AutoLoader rexecd Required to Run AutoLoader When Authentication Set to YES AutoLoader May Hang During a Fork on AIX Systems Prior to 4.3.3 Appendix C. Export/Import/Load Utility File Formats Replication nPЪU gD IBM A b Windows 2000 Wg xs SQL Ϋw~ ъ{񊜜OW DB2 @ Web W Data Difference Utility 3 . ۫㺍gۛd gۛ 5 . gW ݫ񊬢W DATALINK g LOB Wg 6 . ]wg HBs (Update-anywhere) ѲMѾ ]wg 8 DP_ 9 AS/400 ^{Mъ{ 10 OS/390 ^{Mъ{ DB2 DataPropagator for OS/390 ѲMѾ OS/390 W UNICODE M ASCII sXެk 11 UNIX ѡx^{Mъ{ b UNIX M Windows W]wu^{vMuъ{vʚ 14 ݫc 15 ^{Mъ{T A. qъ{ʛ^{Mъ{ System Monitor Guide and Reference (Lլ) db2ConvMonStream Maximum Database Heap Allocated (db_heap_top) Troubleshooting Guide (Lլ) Starting DB2 on Windows 95, Windows 98, and Windows ME When the User Is Not Logged On Chapter 1. Good Troubleshooting Practices Problem Analysis and Environment Collection Tool Chapter 2. Troubleshooting the DB2 Universal Database Server Chapter 8. Troubleshooting DB2 Data Links Manager Chapter 15. Logged Information Gathering Stack Traceback Information on UNIX-Based Systems b 64 񩬀ѡxWъ DB2 Universal Database 5 [c LOCKLIST shmsys:shminfo_shmmax 6 XML Extender Administration and Programming (Lլ) MQSeries DB2 MQSeries 㬀wP[c w MQSeries w MQSeries AMI ъ DB2 MQSeries Function MQSeries ÛT Tc MQSeries \[ ~X ъkۛU уÛT ÛeT ^T ъ{퇴ъ{s enable_MQFunctions enable_MQFunctions disable_MQFunctions disable_MQFunctions IV ̝zu ueѪ]m ъ Linux WBI| Linux ʃnSw Java h sV_miz_m۫w ̝z DB2 Server for VSE & VM AO Java 1.2 b Windows @~tUъuWuL«|v~ ͐tL OS/2 tU Java b Windows @~t񺝺ڃxwu@uήsv~ hmss DB2 for OS/390 OS/390 ѝnѓ{ uыhvϬ DB2 񋬀 UNIX t񋬀 OS/2 iӬ Infopop D jdk11_path [cЅ㬀 ъuScript vuڃxvoс Solaris t~ (SQL10012N) DPREPL.DFT ά ʛh˜ applet H Applet uW b Applet ʪ (Windows 95) U ъjqdG RO {bROѵiHٖАzr ۛT ѓ Java dѾ b Windows @~tUuL«|v~ Netscape w}ʫAb Netscape Navigator }~ Web (UNIX t) ʛuۛTvD xs{ýϩm z/OS OS/390 Java xs{ z/OS OS/390 SQL xs{ z/OS OS/390 Ѿxs{ýϩm˺s ]wG›e b Windows NT Wq DB2 ۫w{ F bы۫wF]wXRjp MQSeries UF OLE DB UF V Business Intelligence Business Intelligence ý gLΡq Business Intelligence ý DB2 Universal Database ͐t ۫㡌x Administration Guide iъs xA[j\ ъ OS/390 Nz{훧 Trillium ժt JCL ۫㡌xGsd{ ъ DB2 Warehouse Manager ˀ̝z ETI.Extract(R) ӗ{ws ъ Common Warehouse Metadata Interchange (CWMI) JXyz۫ Jyz۫ bJъ{ߺsyz۫ Xyz۫ ьyїyz۫J/Xъ{ wq BJP{Ü{ SAP BJۛT iӽыb̓W@Pݫ SAP Connector ۛT SAP Connector w GetDetail BAPI Web Connector ۛT WebSphere Site Analyzer у DB2 OLAP Starter Kit OLAP Server @~tA{ѻ DB2 OLAP Starter Kit b UNIX Ww Solaris @~ʬ[[c ʪ@~t[[c [c OLAP Starter Kit ODBC b UNIX tW[c۫ b UNIX tW[c OLAP yz۫㽼 b Windows tW[c۫ b Windows tW[c OLAP yz۫㽼 bz[c۫ q OLAP Starter Kit W̝z{nJ Starter Kit nJd ы[c OLAP Starter Kit dʩ۫w Ӕъ{ OLAP Starter Kit у 7.2 wDP OLAP Ԭ݅Wq› EQD Γ ۛT̝z{̝zU ۛT̝z{_l]wъ{ vD wD ۛT̝z{[j\ b Windows uۛT̝z{v Sybase e H DB2 у 7 ۛT̝z{s DB2 у 5 ۛT ]mۛT PѪ~ѵyz۫ ъ flgnxoln Oѵyz۫ ъ MDISDGC Oѵyz۫ Is{ Information Catalog Manager Programming Guide and Reference (Lլ) Information Catalog Manager Reason Codes ۛT̝z{ъU ۛT̝z{GuWT ѓ FLG T T FLG0260E T FLG0051E T FLG0003E T FLG0372E T FLG0615E ۛT̝z{GuW Web ۛT̝z{ DB2 Warehouse Manager wU iHъ DB2 Warehouse Manager wUs xӗ{nڃD SAP R/3 Connector wѲMѾ Web Connector wѲMѾ iSeries Nz{ߩmw`N ъӗ{P iSeries xNz{e Query Patroller Administration Guide (Lլ) DB2 Query Patroller Client is a Separate Component Changing the Node Status Migrating from Version 6 of DB2 Query Patroller Using dqpmigrate Enabling Query Management Location of Table Space for Control Tables New Parameters for dqpstart Command New Parameter for iwm_cmd Command New Registry Variable: DQP_RECOVERY_INTERVAL Starting Query Administrator User Administration Data Source Administration Creating a Job Queue Job Accounting Table Using the Command Line Interface Query Enabler Notes DB2 Query Patroller Tracker may Return a Blank Column Page Additional Information for DB2 Query Patroller Tracker GUI Tool Query Patroller and Replication Tools Improving Query Patroller Performance Lost EXECUTE Privilege for Query Patroller Users Created in Version 6 Query Patroller Restrictions Appendix B. Troubleshooting DB2 Query Patroller Clients VI ъ{}o Administrative API Reference (Lլ) db2ArchiveLog (new API) db2ArchiveLog db2ConvMonStream db2DatabasePing (new API) db2DatabasePing - Ping Database db2HistData db2HistoryOpenScan db2Runstats db2GetSnapshot - Get Snapshot db2XaGetInfo (new API) db2XaGetInfo - Get Information for Resource Manager db2XaListIndTrans (new API that supercedes sqlxphqr) db2XaListIndTrans - List Indoubt Transactions Forget Log Record sqlaintp - Get Error Message sqlbctcq - Close Tablespace Container Query sqleseti - Set Client Information sqlubkp - Backup Database sqlureot - Reorganize Table sqlurestore - Restore Database Documentation Error Regarding AIX Extended Shared Memory Support (EXTSHM) SQLFUPD locklist SQLEDBDESC ъ{}oU iъs S/390 zSeries W Linux Linux Rexx es SQL {ì[`N Application Development Guide (Lլ) Update Available Precaution for registering C/C++ routines (UDFs, stored procedures, or methods) on Windows Correction to "Debugging Stored Procedures in Java" New Requirements for executeQuery and executeUpdate JDBC Driver Support for Additional Methods JDBC and 64-bit systems IBM OLE DB Provider for DB2 UDB CLI Guide and Reference (Lլ) ъ Run-Time Client s۫wъ{ Using Static SQL in CLI Applications Limitations of JDBC/ODBC/CLI Static Profiling ADT Transforms Chapter 1. Introduction to CLI Differences Between DB2 CLI and Embedded SQL Chapter 3. Using Advanced Features Writing Multi-Threaded Applications Writing a DB2 CLI Unicode Application Microsoft Transaction Server (MTS) as Transaction Monitor Scrollable Cursors Using Compound SQL Using Stored Procedures Chapter 4. Configuring CLI/ODBC and Running Sample Applications Configuration Keywords Chapter 5. DB2 CLI Functions SQLBindFileToParam - Bind LOB File Reference to LOB Parameter SQLColAttribute -- Return a Column Attribute SQLGetData - Get Data From a Column SQLGetInfo - Get General Information SQLGetLength - Retrieve Length of A String Value SQLNextResult - Associate Next Result Set with Another Statement Handle SQLSetEnvAttr - Set Environment Attribute SQLSetStmtAttr -- Set Options Related to a Statement Appendix C. DB2 CLI and ODBC ODBC Unicode Applications Appendix D. Extended Scalar Functions Date and Time Functions Appendix K. Using the DB2 CLI/ODBC/JDBC Trace Facility TЪU iъs Ts uWTժr SQL Reference (Lլ) SQL Reference Update Available Enabling the New Functions and Procedures SET SERVER OPTION - Documentation Error Correction to CREATE TABLESPACE Container-clause, and Container-string Information Correction to CREATE TABLESPACE EXTENTSIZE information GRANT (Table, View, or Nickname Privileges) - Documentation Error MQSeries Information Scalar Functions Table Functions CLOB data now supported in MQSeries functions Data Type Information Promotion of Data Types Casting between Data Types Assignments and Comparisons Rules for Result Data Types Rules for String Conversions Expressions Predicates Unicode Information Scalar Functions and Unicode GRAPHIC type and DATE/TIME/TIMESTAMP compatibility String representations of datetime values Casting between data types Assignments and comparisons Datetime assignments DATE GRAPHIC TIME TIMESTAMP VARGRAPHIC Larger Index Keys for Unicode Databases ALTER TABLE CREATE INDEX CREATE TABLE ALLOCATE CURSOR Statement Notes Section Incorrect Additional Options in the GET DIAGNOSTICS Statement GET DIAGNOSTICS Statement ORDER BY in Subselects fullselect subselect order-by-clause select-statement SELECT INTO statement OLAP Functions (window-order-clause) New Input Argument for the GET_ROUTINE_SAR Procedure Required Authorization for the SET INTEGRITY Statement Appendix N. Exception Tables Unicode s DB2 Unicode ۫w񊔐ъ{ Ѿs VII sDqt DB2 Connect User's Guide (Lլ) Increasing DB2 Connect data transfer rate Extra Query Blocks RFC-1323 Window Scaling DB2 Connect Support for Loosely Coupled Transactions Kerberos support sʩR۫ b VM Uwъ{A CLI/ODBC/JDBC [c PATCH1 M PATCH2 ]w VIII [ۛT [ۛT DB2 Everywhere w DB2 Everyplace DB2 UDB у 7 sS LJM ޽KьS iь ̐Ne isѾ ㇽD q DB2 Run-time Client sPusv~ Search (Search Discovery) HP-UX 11 O Лw DB2 DFS qʛ{ Windows NT q pXt MPP 񔐊ݫpX DataJoiner Windows NT BթۛT̝z{ ʛ Windows Lkʛ DB2 SNA SPM Windows NT Windows 2000 W DB2 Ab߃D nTwʪ|b۫㡌x(DWC)ъъwq{ Windows NT WqͿ Life Sciences Data Connect s~h `N- SQL U{[j\ ѸP_mO "Warehouse Manager" "DB2 Warehouse Manager" IX g . `N ˅ ii) wъ DB2 Universal Database у 7 FixPak у`NI : ժrANr]wZH޽Kuу`NvC DB2 Universal Database P DB2 Connect |wsC𩧪G http://www.ibm.com/software/data/db2/udb/winos2unix/supportAHos ۛTC у]tUC~ۛTFb DB2 ULsA|LkooѸۛTG IBM DB2 Universal Database Personal EditionAу 7.2 IBM DB2 Universal Database Workgroup EditionAу 7.2 IBM DB2 Universal Database Enterprise EditionAу 7.2 IBM DB2 Data Links ManagerAу 7.2 IBM DB2 Universal Database Enterprise - Extended EditionAу 7.2 IBM DB2 Query PatrollerAу 7.2 IBM DB2 Personal Developer's EditionAу 7.2 IBM DB2 Universal Developer's EditionAу 7.2 IBM DB2 Data Warehouse ManagerAу 7.2 IBM DB2 Relational ConnectAу 7.2 IBM DB2 Connect Personal EditionAу 7.2 IBM DB2 Connect Enterprise EditionAу 7.2 t@uу`Nvμ READCON.TXTAo˔ΗUC~ۛTG IBM DB2 Connect Personal EditionAу 7.2 IBM DB2 Connect Enterprise EditionAу 7.2 ziHq IBM nڀ www.ibm.com/software/data/db2/lifesciencesdataconnect/library.html U DB2 Life Sciences Data Connect ~ѾC ziHqhttp://www.ibm.com/software/data/db2/lifesciencesdataconnect u Woу~ۛTC FixPak 4 UCБywsAziHq http://www.ibm.com/software/data/db2/udb/winos2unix/support uWU s PDFG Administration Guide ъ{}oU Application Development Guide Command Reference Data Recovery and High Availability Guide and Reference ۫㡌x Administration Guide TЪU SQL Reference DB2 Warehouse Manager wU oì`N񬀩ۛTOъHRsCz]iHb CD 񿷜oʪw sѾCzL DB2 Aъ PTF X U478862AYiq CDCziHq http://www.ibm.com/cgi-bin/db2www/data/db2/udb/winos2unix/support/help.d2w/report opuDB2 AvۛTC usSv@]tѸ DB2 у 7.2 DnW[[CpGzS usSv@Ь 7.2 уAiHq http://www.ibm.com/software/data/db2/udb/winos2unix/support UC p DB2 ~tCsۛTAziHq\KO DB2 MagazineCuW xi http://www.db2mag.com oFbW]q\xьC : bҡuу`NvAZAъ Windows NT Ъʩ۫|Aъ Windows 2000Co˪b" Windows MEBWindows XP M Windows 2000 Datacenter Edition ѡx"CX~ʮwqA]]t Windows XP (Dtw)C : b¡ѬΡqC (|) Oь˪uу`Nv@ߪsW κC I g Ѳ у 7 у`N ouу`Nvws FixPak 8C]tۛTs FixPak ъ񗼛CуCьuOnDnѾICѝ\ Pzu@ʪʪу`N`AHxss۫CХ\ FixPak ReadmeAHo FixPak 8 ߇у 7 ʪsW\Ӭȝ˩ۛTC * "Ю NFS DAdb2stop b AIX 5 @~tWݥ" * " Linux on S/390 is DB2 EE DB2 Connect EE wM" * "L DB2 Connect ۛT" * "b SuSE Linux Ww DB2" * "b AIX 5 Wъ IBM e-server p690 DB2 UDB у 7" * "pGъ DB2 у 8 ۫Ahn FixPak 8 sу" * "BJ 1G]wʚ㿖s]wn" * "Correction to Collating Information (collate_info) Section" * "db2updv7 - Update Database to Version 7 Current Fix Level" * "RUNSTATS" * "AutoLoader Restrictions and Limitations" * "Using AutoLoader" * "ъ{񊜜OW" * "Maximum Database Heap Allocated (db_heap_top)" * "Web Connector ۛT" * "db2Runstats" * "Precaution for registering C/C++ routines (UDFs, stored procedures, or methods) on Windows" * "JDBC and 64-bit systems" * "Correction to CREATE TABLESPACE Container-clause, and Container-string Information" * "Correction to CREATE TABLESPACE EXTENTSIZE information" ~`N Aъ Solaris @~ DB2 у 7 CPU UltraSparc e CPU уC Red Flag Linux Ճyєʡѓ{ pGzъuռX Linux Aу 1.1vAuXvHo Ճyєʡѓ{CSу 1.1 Ճyєʡѓ{A DB2 NLkٖИլrX¼O 1386C ծM Linux DB2 for Linux [yєʐ]w ݜznbծ Linux tWъ Java GUI u]ʪpu v^AhnB~yєʐ]wCYSo]whLkѓTьծ ժrCbzъ]w[JUC]wAbCuvI seqRO]wC wտtG export LC_ALL=ja_JP wտtG export LC_ALL=zh_CN PTX Wա pGzOb PTX tWլ DB2 UDBAh DB2 ъѸBzi| ~ѓTyєʩۛTCYnκKpA𪍪]w DB2CODEPAGE P DB2COUNTRY nHzyєC Microsoft Internet Explorer W񋛦D oO Internet Explorer wю]wʐyDCuvъх p jarA]stۛTQwю̝z{훜ъFC Yno˛DAstm IE wюApUьG 1. \Ӭ (IE4) u\Ӭ (IE5) W Internet C 2. buwюv¡AHѶC 3. @UsW...C 4. Nu Web AvsWHѶMCpG Web A bPAiunN Web AW[JYi (tW )CʪpG http://ccWebServer.ccWebServerDomain http://ccWebServer : bJ URL Azѝъ https:// rA񀬀 nA (https:) AHsW 5. @UTwC 6. @U]w...(IE4)A@Uqh... (IE5)C 7. Uެ Java --> Java vAAqC 8. @U Java q]w...C 9. usސ\ivv¡C 10. VUuхWe --> хWe --> ѪхW\iv --> tۛTvAMߓъC 11. @UC}TwC \Ӽy b DB2 у 7.2 Auvqу 6 FixPak 6 HeуAH qу 7 FixPak 2 eуAYP DB2 у 7.2 @_ъAXG| hʪ\CFѓDANу 6 q񂻚 FixPak 6 s уANу 7 q񂻚 FixPak 2 sуC iN FixPak 2 ъ DB2 AAhqA| BʗyzDC Netscape CD H DB2 UDB Netscape CD AH DB2 UDBCq http://www.netscape.comA Netscape ~C XML Readme ~ b DB2 XML Extender у 7.1 README.TXT u`NvG 3. DB2 UDB w]уO DB2 UDB у 7.1CYznb AIX P Solaris tWъ DB2 UDB у 6.1AzˡnTwzOft DB2 UDB у 6.1 ο DB2 UDB у 6.1 Ϋw@_C oOѓTCDB2 XML Extender „b DB2 у 7.1 P 7.2 QC readme.aixBreadme.nt P readme.sun ʪCьnڃDG * DB2 UDB 6.1 (FP1_U465423) HW (AIX) * DB2 Universal Database у 6.1 HW (w FixPak 3) (NT) * DB2 UDB у 6.1 (FixPak FP1_U465424) HW (Sun) oOѓTCDB2 XML Extender n DB2 у 7.1 7.2C DB2 у 7.2 sW Business Intelligence [j\ busSvу 7.2 @ЃPLѾAs Business Intelligence [j\ӬЪʩ۫wsWу 7.2 Co[j\|b iъC FixPak 2A Psуb IBM DB2 OLAP Server oсD pGzb UNIX Wъ IBM DB2 OLAP ServerAhbwF DB2 Universal Database V7 FixPak 2A A DB2 OLAP Server i|oсDC FixPak 2A 񊺾sу FixPaks |w Unicode s ODBC X{A DB2 OLAP Server osX{C DB2 OLAP Server пMެkO񙗽 z ODBC AVD UNICODE ODBC X{C D UNICODE X{wgWAbW[F "_36"C ʪpAY uSolaris @~vAX{ libdb2.so wW libdb2_36.soCp ODBC X{ۛTAХ\ OLAP Setup and User's Guide @A 4 Installing on AIXBSolaris Operating Environment and HP-UX Loading and Configuring ODBC for the SQL InterfaceC ъ WebSphere 3.5.5 񔛤qHW pGzb Linux390 Wъ DB2 V7.2 FixPak 4 sу˛ WebSphere 3.5.5 ъ]wdAzi| SIGSEGV 11 (*) 񔛤qHWqCo ˛DP JDK W@~AJDK 1.2.2 M JDK 1.3 |oсo˛DC o˛DiӅvTѪ JDBC ъ{C JDK 1.2.2 11 ٬A|ѓo˛DCJDK 1.3 1 ٬A]N ѓ JDK 1.3C YnпMo˛DAziHъUCO˖ JITG export JAVA_COMPILER=NONE Veritas AIX Volume Manager DB2 UDB Enterprise Edition FixPak 7 sуAiHb AIX 5.1 ML 2 sуWAft Veritas AIX Volume Manager у 3.2 ъCϽe N Veritas AIX Volume Manager PѶѪу DB2 UDB (]A Enterprise Extended Edition) ftъC AIX V4 W Java ъ{ѝnѓ{ pG{픂› bos.mp bos.up O 4.3.3.77Ahb AIX 4.3.3 W Java ъ{i|`C 𛧪O lslpp -l bos.ip bos.mp HTw{ѓhC ϑ AIX 4.3.3 ʪ Java ߐ񂻚 4.3.3.78CziHъѓ {AHN{sϑhCzѝouvDRi (APAR)v IY25282 ѓ{C w IY25282 ѓ{N|ѓ Java 񯬼pCi@Bѓ{Nb 2000 ~@uXA APAR s IY26149C `N:P IY25377 @_Xf AIX 5.1C tPѓ{C pi@BۛTPϑApuAIX vC Ю NFS DAdb2stop b AIX 5 @~tWݥ pGzъ AIX 5 BtWjq۫w񔐊A db2stop ROi Co˛DпMެkOAъ db2stop RO NODENUM A˺O C@񔐊C AIX APAR IY32512 пMDC uWѾ]HTMLBPDF PujMv^ Windows 2000 @~t Web s ϑzb Windows 2000 Wъ Microsoft Internet ExplorerC Yzъ NetscapeA`NUCG * ъ Netscape | Windows 2000 W DB2 uWۛTjM˫C Netscape Nъʪiъ CPU ABGOTaC ݐ ê^jMGAϑzbXjMAbt@W@UH JIC |bXzqê^jMGC * zi|`NANetscape s@}l|ѓTьuWAY хsAKquvLaުsuWAѪi |X{CYsAnDAN|X{ѓTC ziz L"ʛ Netscape с~T"UCBJˡѓo˛DCz]i HbnDuvesAHκKo˛DC * nDuvAuۛTvDDAzi|~T C nѓo˛DAݗ`"ʛ Netscape с~T"BJC b Solaris @~UjM DB2 uWۛT pGzb Solaris @~UjM DB2 uWۛTDA𔈼dtb /etc/system 񀬀{ЅCHUO DB2 jMtʃ{Ѕ㬀p A NetQuestionG semsys:seminfo_semmni 256 semsys:seminfo_semmap 258 semsys:seminfo_semmns 512 semsys:seminfo_semmnu 512 semsys:seminfo_semmsl 50 shmsys:shminfo_shmmax 6291456 shmsys:shminfo_shmseg 16 shmsys:shminfo_shmmni 300 ]w{ЅAb /etc/system sWUCOG set = value ѶsϮсAzѝsʛtC 񙗽 NetQuestion for OS/2 Hъ TCP/IP 񙗽g NetQuestion Hb OS/2 tWъ TCP/IP ьC oýь *.cfg mO NetQuestion wϓ۫㪩ϓCziHJUC@ O˿Mw NetQuestion wϓG echo %IMNINSTSRV% //Aъ SBCS w echo %IMQINSTSRV% //Aъ DBCS w ʛ Netscape с~T ݜzʛ Netscape ApGzo{UC~TG <Ω|>񺔂 (OѾ)C dTw|MWѓTAHʪѝnΫwC Lk} "D:\Program Files\SQLLIB\CC\..\doc\html\db2help\XXXXX.htm" z˛UCBJAHѓb Windows NTB95 98 Wo˛D (Х\ HUBJAHFЪpb Windows 2000 W)G 1. qu}lv\ӬAu{›v-->uWindows Ι`vCYi} uWindows Ι`vC 2. quWindows Ι`vuv-->u۫㺿vCYi}u۫ vOуC 3. @UΖC}uΖvC 4. bnΖ񓴿 Netscape Hypertext DocumentA@Uus vCYi}usvΖC 5. @}C 6. @Us޽sCsޛ@}C 7. ъ DDE 񑓴C 8. bъ˛@ъ{푵ATw "%1" X{br۬ߡ (]A ̩H񊝑@̩e)C Yb Windows 2000 Wo{~TAz˛UCBJG 1. q}l\ӬA Windows Ι`CYi}uWindows Ι`vC 2. quWindows Ι`vAu --> ۫㺿CYi}u۫㺿 vOуC 3. @UΖC 4. buΖvWBwnΖ AjьGHTM Netscape Hypertext DocumentAA@Ui CYi}usޔΖvC 5. jь@u}vC 6. @Us޽sCYi}usޖ@vC 7. ъ DDE 񑓴C 8. bъ˛@ъ{푵ATw "%1" X{br۬ߡ (]A ̩H񊝑@̩e)C 9. @UTwC 10. w HTML Netscape Hypertext Document M SHTML Netscape Hypertext Document ΖBJ 4 8C UNIX tW Adobe Acrobat Reader [cD b UNIX ѡxAAcrobat Reader uС^լCH^H~yє} PDF At|ê^~TCTX PDF άrsДYс ~AOAۃWO]^լ Acrobat Reader LkbD^Ճyєʬ UNIX 񛧪C PDF Aʛ^լ Acrobat Reader eAѲUC@B JA񙗽^լyєG * s Acrobat Reader ʛ scriptAbʛ script A #!/bin/sh z sWUCOG LANG=C;export LANG oA Acrobat Reader QѪъ{ʛApQ Netscape ̥ъ{\ӬݜʛA|сѓTC * bROьJ LANG=CAN Acrobat Reader ъ{픶ʐ]w^C i@BۛTAsu Adobe t (http://www.Adobe.com)C SQL Reference „@ PDF CуБyuъ DB2 ΫwvAX SQL Reference PDF B UCoOѓTC MCLБyUABUЩѓTAOu@ PDF AѪ]tFUCPDF WO db2s0x70C II g wP[c @٪wB[cۛT Uʪ DB2 qw۫] Ynwʪ DB2 q (]Aʪу 7 eq) Uw ]As IBM DB2 FixPaks and Clients G http://www.ibm.com/ cgi-bin/db2www/data/db2/udb/winos2unix/support/download.d2w/reportC Linux on S/390 is DB2 EE DB2 Connect EE wM u͐tJvБywьAiweAъ tar -cvf R OA CD eы tar AMߜN tar ήb S/390 is WC L DB2 Connect ۛT uDB2 Connect ͐tJv "CьBs۫]" A Y MѡxMDѝnAziѪC b SuSE Linux Ww DB2 LDB2 Universal Database for UNIX ͐tJA|ub SuSE Linux Ww DB2 v@`Cу`ʡzѝ㜰ѾAAOѝnC Solaris @~ʖB~nΩh FCьbDB2 for UNIX ͐tJU񀬀Ω{~ACьFAъ uSolaris @~vу 2.6 DB2 Universal Database у 7 ʃn 106285-02 sΩ{C b AIX Ww DB2 Enterprise-Extended Edition uDB2 Enterprise-Extended Edition for UNIX ͐tJv@Ьuwv `ABJ 4 zJUCO˛tm CD-ROM οtG crfs -v cdrfs -p ro -d cd0 YnOºQAzѝъ --m OHPwIC crfs -v cdrfs -p ro -d cd0 -m /cdrom buwvq񓏀|F@˿BJCbBJ 5Gbu@W CD-ROM οtAbz񔐊۫wtʺtC@˩`Iq CD-ROM οtC] /cdrom |хsbЃP`IAъUCOHbu @WX /cdrom οtG exportfs -i -o ro /cdrom dsh mkdir /cdrom dsh mount cws_hostname: /cdrom /cdrom cws_hostname Ou@DqWC AIX CICS ъB~wBJ Yznb AIX CICS tWw DB2 UDB Ѷ DB2 UDB FixPakAzѝbw ߛUCB~BJwCoÿBJȝ˃ CICS/6000 Administration Guide "Configurarion steps for Database 2" p`G 1. q libdb2.a Ϋwы@ DB2 UDB for AIX @ъѾC 2. ϩm DB2 switchload οNѪb۫w XA wqʽwϓC 3. YznbQъ COBOLAhs cocsmkcobol uC Netscape LDAP ϓ DB2 ъ LDAP ϓAH›̝zPXͩ۫w`IϓCbe DB2 A„ Microsoft Active Directory P IBM SecureWay DirectoryC DB2 {b]UC LDAP AGNetscape Directory Server у 4.12 sуBiPlanet(TM) Directory Server 5.0 sу XR Netscape LDAP UCьAъ Netscape Directory Server 4.1G Netscape Directory Server iHъ{bUCԡ˔sW񊬽Ѿ OwqAHXRGslapd.user_oc.conf slapd.user_at.confCoԡ μO \slapd-\config ϓC ѝsW DB2 slapd.user_at.confApUьG : o˔ʮwq binBcisBces M dnAONGiBjpg rBjpgrۮMкOWC : ############################################################################ # # IBM DB2 Universal Database V7.2 # wq # ############################################################################ attribute binProperty 1.3.18.0.2.4.305 bin attribute binPropertyType 1.3.18.0.2.4.306 cis attribute cesProperty 1.3.18.0.2.4.307 ces attribute cesPropertyType 1.3.18.0.2.4.308 cis attribute cisProperty 1.3.18.0.2.4.309 cis attribute cisPropertyType 1.3.18.0.2.4.310 cis attribute propertyType 1.3.18.0.2.4.320 cis attribute systemName 1.3.18.0.2.4.329 cis attribute db2nodeName 1.3.18.0.2.4.419 cis attribute db2nodeAlias 1.3.18.0.2.4.420 cis attribute db2instanceName 1.3.18.0.2.4.428 cis attribute db2Type 1.3.18.0.2.4.418 cis attribute db2databaseName 1.3.18.0.2.4.421 cis attribute db2databaseAlias 1.3.18.0.2.4.422 cis attribute db2nodePtr 1.3.18.0.2.4.423 dn attribute db2gwPtr 1.3.18.0.2.4.424 dn attribute db2additionalParameters 1.3.18.0.2.4.426 cis attribute db2ARLibrary 1.3.18.0.2.4.427 cis attribute db2authenticationLocation 1.3.18.0.2.4.425 cis attribute db2databaseRelease 1.3.18.0.2.4.429 cis attribute DCEPrincipalName 1.3.18.0.2.4.443 cis ѝsW DB2 ѾO slapd.user_oc.conf ApUьG ############################################################################ # # IBM DB2 Universal Database V7.2 # ѾOwq # ############################################################################ objectclass eProperty oid 1.3.18.0.2.6.90 requires objectClass allows cn, propertyType, binProperty, binPropertyType, cesProperty, cesPropertyType, cisProperty, cisPropertyType objectclass eApplicationSystem oid 1.3.18.0.2.6.8 requires objectClass, systemName objectclass DB2Node oid 1.3.18.0.2.6.116 requires objectClass, db2nodeName allows db2nodeAlias, host, db2instanceName, db2Type, description, protocolInformation objectclass DB2Database oid 1.3.18.0.2.6.117 requires objectClass, db2databaseName, db2nodePtr allows db2databaseAlias, description, db2gwPtr, db2additionalParameters, db2authenticationLocation, DCEPrincipalName, db2databaseRelease, db2ARLibrary sW DB2 ϮwqAsʛ Directory Server ~ӚʪсC Windows MEBWindows XP M Windows 2000 Datacenter Edition ѡx {b DB2 Microsoft Windows MEBWindows XP M Windows 2000 Datacenter Edition ѡxCUѡxSѪۛTC Windows XP UC~MуYOH FixPak 4 sуwAYi 32 Windows XPG * IBM DB2 UDB Personal Edition у 7.2 * IBM DB2 Personal Developer's Edition у 7.2 * IBM DB2 Universal Developer's Edition у 7.2 * IBM DB2 Connect Personal Edition у 7.2 * IBM DB2 Connect Enterprise Edition у 7.2 * IBM DB2 UDB Workgroup Edition у 7.2 * IBM DB2 UDB Enterprise Edition у 7.2 * IBM DB2 Run-Time Client у 7.2 * IBM DB2 Administration Client у 7.2 * IBM DB2 Application Development Client у 7.2 DB2 b Windows XP tW۫ayAPѪуPC ݜzbwJъ ID MqXAi|@hTXzbwe WJъbLAWOCoсoϜO]qWw gzJъ IDCpGzJqWSъWAN|oсo DC pGzQb db2admin H~ѪъbUw DB2AѲTwbߪWX DB2 RWWhCn@IOAWӪѶCʪpAmy_name O ѓTAmy name O~C pGzbw~~ 1052A𛧪UCBJG 1. ~O}C 2. }ʽOC 3. O db2start.exeC 4. ъROWьъqXA˛~񽳮wOC 5. ^~AM߽@UTwC{bAziH~wC pGzo{uvLkѓTьzъuvrAκ sqllib\java\java12\jdk\jre\lib\font.properties.zhAެkONn filename.\u5b8b\u4f53=simsun.ttf filename.\u5b8b\u4f53=simsun.ttcC Windows ME UC~MуYOH FixPak 2 sуwAYi Windows MEG * IBM DB2 UDB Personal Edition у 7.1 * IBM DB2 Personal Developer's Edition у 7.1 * IBM DB2 Universal Developer's Edition у 7.1 * IBM DB2 Connect Personal Edition у 7.1 * IBM DB2 Run-Time Client у 7.1 * IBM DB2 Administration Client у 7.1 * IBM DB2 Application Development Client у 7.1 Ͻe Window ME |хuHTML jMAv\C ݜzЛw DB2 Azi|@h~TX MFC42U.DLL C YnюЛw DB2AbЛw훉AԛR sqllib ϓC Windows 2000 Datacenter Server UC DB2 ~wgo Windows 2000 Datacenter ServerBWindows 2000 Advanced Server M Windows 2000 Server {G * IBM DB2 Universal Database Enterprise - Extended Edition у 7.2 * IBM DB2 Universal Database Enterprise Edition у 7.2 * IBM DB2 Database Workgroup Edition у 7.2 * IBM DB2 Connect Enterprise Edition у 7.2 b Windows 95 w DB2 pGzOnbD^լ Windows 95 tWw DB2Ahѝbw DB2 UDB eAѲN Winsock уs Winsock 2CziHq Microsoft o Winsock 2 񂻚ъ{C b Windows 2000 Ww DB2 b Windows 2000 WAwbe DB2 WAOsw{уAT wNʪ DB2 A^_]wuTake No ActionvC b Windows 2000 Terminal Server ̝zʪU DB2 DB2 UDB Version 7.1AFixPak 3 񊺾уADB2 ib Windows 2000 Terminal Server ̝zʪUCboeADB2 u Windows 2000 Terminal Server uъ{AvʪC Microsoft SNA Server M SNA hs (ѼqTw) Microsoft SNA Server Oъ SNA ~ADqM AS/400 ъ{ Lksъ SNA ѼqTw DB2 UDB ACѶьHW\Ӭ DB2 UDB X~OѓTCѝn IBM Communications Server for Windows NT 5.02 HWуC : ъ DB2 UDB for Windows ˪sDq AS/400 ۫wAъ{ iHъ Microsoft SNA Server у 4 Service Pack 3 HWу ˿ъ SNA ѼqTwC Windows NT (CS/NT) IBM Communications Awqъ ID MqX pGzъ APPC @ DB2 qP DB2 AsqTwAPA z CS/NT ݪ SNA ~ъATwzwb CS/NT [cѓT]wFU CrCq`ziHb x:\ibmcs\private ϓUb˔C `Iwq TG_SECURITY_BEHAVIOR Ѕe\ъMwApG TP OKO@[cA`IOpB zX{b ATTACH 񀬀wюۛTC IGNORE_IF_NOT_DEFINED Ѕe\ъMwO_KO@ЅX{b ATTACH APA Y TP OKO@[ciѪC Yzъ IGNORE_IF_NOT_DEFINEDAhL CS/NT wqъ ID MqXC VERIFY_EVEN_IF_NOT_DEFINED Ѕe\ъMwO_KO@ЅX{b ATTACH A ѪAY TP х[cKO@CoOw]C Yzъ VERIFY_EVEN_IF_NOT_DEFINEDAhѝ CS/NT wqъ ID MqXC wq CS/NT ъ ID MqXA𛧪UCBJG 1. }l --> {› --> IBM Communications Server --> SNA Node ConfigurationC Y}uwъ Communications Server [cvC 2. znκ[cC@UuU@BvCʓ[cۛd} C 3. jь CPI-C, APPC 5250 ʔ{C@UuvCYi} Communications Server SNA `IC 4. @U CPI-C M APPC Ö [+] C 5. @U LU6.2 KO@Ö [+] C 6. k@UъqXAыCwqъ ID qX}C 7. ±gъ ID MqXC@UTwC@UHC pGi퀤хsAh DB2 w|_ bw DB2 ApGqi퀤хsAhbw Aw{i|_C YnпMDAbw{w -a G setup.exe -a b Windows 2000 Wъ CLP oс~ SQL1035N pGw DB2 uYÿъ (ʪpA̝z) ~ҪgJvϓA@ٿ ъ|bъ DB2 ROBz~ SQL1035NC YnпMDAbʪъҪgJvϓw DB2C HSOswqӛD ۫wApGSOs USER CURRENT SCHEMA Qъˮwq Ah|LkъC ʪpG create view v1 (c1) as values user bу 5AUSER M CURRENT SCHEMA ۫㖎O CHAR(8)Cу 6 _AѪ Qwq VARCHAR(128)C уdApGݼOЬу 5 ʽыA cl ۫㖎h CHARC ߿ъAѪ|bsAOAѪ |]۫㖎C пMޫμOsыC beAd SYSCAT.VIEWS ݿ˘^ъ˽ыݬykC ʪpG select text from syscat.views where viewname='<>' Windows 2000 IPX/SPX qHw ۛTOu͐tJv@Ьuwvo@uiӬDqsۛvo @`C wGqHwݿюѓTC ъ IPX/SPX s OS/2 UNIX A Windows 2000 qC ]ъ IPX/SPX s Windows 2000 A OS/2 UNIX qC 񂻚 DB2 e@eѲ DB2 { ۛTOuDB2 for Windows ͐tJv@񬀝өۛTC Yzn񂻚b Windows We@ DB2Aw{ʗЬi]tF N DB2 DLL OdbOڬ{êCьC bAziHNCь{Hԛ ު훜Aw{o{Cϑzbweԛʪ DB2 {AHκKy۫C nTw DB2 {b񬀐ުOzL uWindows Ave˔t{C buWindows AveATw S DB2 AB OLAP AB۫㡌xAC : Windows ѡxW@uӛ@Ϭу DB2C ʪpAzLkbP Windows WP DB2 у 7 M DB2 у 6CYznN DB2 у 7 wbww DB2 у 6 WAw{|bwR DB2 у 6C˥Aݬ͐tJUAHoq DB2 e@˝Ӭ ۛTC YwwѪ DB2 ~Abw DB2 ߛ db2iupdt UCۛTbzu͐tJvwѾwC b UNIX tWw DB2 UDB у 7 AYww DB2 ~Azn db2iupdt OAHsznъу~sSοCûSnbo˽ O~ӿъC ]w Linux H DB2 ۛTtu͐tJv@Ьuw DB2 vo@C } Linux DB2 w{^΀AJUCOB]wѓ TAH DB2uvG su -l <οʪW> export JAVA_HOME=/usr/jdk118 export DISPLAY=:0 MA}t@˝΀JG su root xhost + ˝΀A^znJοʥͪ ID ΀AJOG db2cc HʛuvC DB2 Universal Database Enterprise Edition DB2 Connect Enterprise Edition for Linux on S/390 DB2 Universal Database Enterprise Edition DB2 Connect Enterprise Edition {bib Linux/390 WъFC bw Linux S/390 WeA zˡnNпnwڬDG w S/390 9672 Generation 5 HWAMultiprise 3000C n * SuSE SLES-7 (tHUʪCΩ{) Turbolinux Server 6 * h 2.2.16At S/390 Ω{ (Uz) * glibc 2.1.3 * libstdc++ 6.1 (t compat.rpm ۫]) Linux/390 nUCΩ{G * SLES-7-PatchCD-1-s390-20020522.iso p S/390 Linux tn񺐆ss{A𜗐X http://www.ibm.com/db2/linux/validateC : 1. u 32 񩬀 Intel-based Linux Linux/390C 2. Linux/390 DB2 у 7 хUCG * DB2 UDB Enterprise - Extended Edition * DB2 Extenders * DB2 Data Links Manager * DB2 Administrative Client * qX * LDAP * TSM * ъlm Linux for S/390 WiӬ۫y Yb Linux for S/390 (ww 2.2 tC{) ъ DB2A Linux q Wiъ RAM qN|p 1 GBC RAM 1 GB әκK] Linux {퓨~yiӮ DB2 ۫yC ouoс DB2 b Linux for S/390Aoс Linux on IntelC ziHq IBM developerworks oΩ{AHKӿъ 1 GB HW RAMC Linux W DB2 Gnome M KDE ӡҪX DB2 {b@ъ{˽ы DB2 W̝z{۫㺿MьAъHb Gnome M KDE W̝z{Wʛ`ъ DB2 uAH Intel Linux e{ъCˇw]ADB2 у 7.2 |woъ{ABbw iъѪ˽ыh@h˓wъW̝z{퇤ьC sW@W̝z{퇤ь@h˿ъAъUCOG db2icons [ ...] : `NAYb Gnome KDE W̝z{픶ʛсьAъi Ӄnԛ_sW̝z{~ӼsьC h@h˿ъ@W̝z{퇤ьAъUCOG db2rmicons [ ...] : zѝҐ㿼v~ӝсhLъьCq`ApGzO @ٿъAdb2icons M db2rmicons iъ˽ыhzv ьAzO root ъOҪvgJw񺿤ъ_lϓ t@˿ъAz~ӛъoԡ˽O˽ыhOHьC Solaris {[cЅ (ϑ) b DB2 for UNIX ͐tJM DB2 Enterprise - Extended Edition for UNIX ͐tJ@uSolaris tvo@u}levo@`A Solaris {[cЅF@ýϑCUݼOۃO 512 MB HWtA @ÿѪ{[cЅϑC 1. Solaris {[cЅ (ϑ) +-----------------+-----------------+----------------+----------------+ | {Ѕ | 512 MB-1 GB | 1 GB-4 GB | 4 GB+ | +-----------------+-----------------+----------------+----------------+ | msgsys:msginfo_ | 65,535 | 65,535 | 65,535 | | msgmax | | | | +-----------------+-----------------+----------------+----------------+ | msgsys:msginfo_ | 65,535 | 65,535 | 65,535 | | msgmnb | | | | +-----------------+-----------------+----------------+----------------+ | msgsys:msginfo_ | 514 | 1,026 | 2,050 | | msgmap | | | | +-----------------+-----------------+----------------+----------------+ | msgsys:msginfo_ | 512 | 1,024 | 2,048 | | msgmni | | | | +-----------------+-----------------+----------------+----------------+ | msgsys:msginfo_ | 16 | 32 | 64 | | msgssz | | | | +-----------------+-----------------+----------------+----------------+ | msgsys:msginfo_ | 1,024 | 2,048 | 4,096 | | msgtql | | | | +-----------------+-----------------+----------------+----------------+ | msgsys:msginfo_ | 32,767 | 32,767 | 32,767 | | msgseg | | | | +-----------------+-----------------+----------------+----------------+ | shmsys:shminfo_ | 483,183,820 - | 966,367,641 - | 3,865,470,566- | | shmmax | 966,367,641 | 3,865,470,566 | 4,294,967,296 | +-----------------+-----------------+----------------+----------------+ | shmsys:shminfo_ | 50 | 100 | 200 | | shmseg | | | | +-----------------+-----------------+----------------+----------------+ | shmsys:shminfo_ | 300 | 1,024 | 2,048 | | shmmni | | | | +-----------------+-----------------+----------------+----------------+ | semsys:seminfo_ | 1,024 | 2,048 | 4,198 | | semmni | | | | +-----------------+-----------------+----------------+----------------+ | semsys:seminfo_ | 1,026 | 2,050 | 4,096 | | semmap | | | | +-----------------+-----------------+----------------+----------------+ | semsys:seminfo_ | 2,048 | 4,096 | 8,192 | | semmns | | | | +-----------------+-----------------+----------------+----------------+ | semsys:seminfo_ | 2,048 | 4,096 | 8,192 | | semmnu | | | | +-----------------+-----------------+----------------+----------------+ | semsys:seminfo_ | 50 | 50 | 50 | | semume | | | | +-----------------+-----------------+----------------+----------------+ : 1. 32 t shmsys:shminfo_shmmax Ѕ㡡O 4 GBC 2. msgsys:msginfo_msgmnb M msgsys:msginfo_msgmax Ѕѝ]wj Ѯ 65,535C 3. msgsys:msginfo_msgseg Ѕѝ]wj 32,767C 4. shmsys:shminfo_shmmax Ѕ㔐ː]wWzݫ񬀽ϑOۚڛO 90% (H񩝞)AjCʪpApGztۚڛO 196 MBAN˜N shmsys:shminfo_shmmax Ѕ]w 184,968,806 (196*1024* 1024*0.9)C DB2 Universal Database Enterprise - Extended Edition for UNIX ͐tJ 5 ub Linux WwM[c DB2 Universal DatabasevX Linux EEE O›񬀿C@ˇۚک`IѝҐ㼍P kernelBglibc libstdc++ hC DB2 EEE for Linux ъiqUCUG http://www6.software.ibm.com/dl/db2udbdl/db2udbdl-p HP-UX shmseg Ѕ zu͐tJv@Ъs HP-UX [cЅ㬀ۛTѓTC HP-UX shmseg Ѕ㬀ϑC ъw] HP-UX (120)C IBM Visual x۫w DB2 Universal Database for Windows ͐tJЪ Windows NT M Windows 2000 i DB2 Universal Database у 7 սwAp @ъ񡌔x۫wۛTCpGn@HWx۫wAhѝ ъx۫w̝zi[۫wC@uӪ@ˡx ۫w@ъCsnJ۫㡌x񋫂ApGW@˩۫wOznъ۫ wAhѝъx۫w̝zinOzʡnъ۫wC ъ db2uiddl Oӛ@ buDB2 ͐tJvUuDB2 ߩmwӺ@~v@Abuъߩm u@vUzѝъ db2uiddl OA DB2 у 5.x DB2 у 6 񝥘ӛ@CoOѓTCubzOqу 5 e DB2 уӫA ~nъ db2uiddl Oӛ@C 64 AIX уw~ ъ db2setup b{s AIX @~tWw 64 AIX DB2 MA TwzъOe AIX уA_hw|C AIX у 5 DB2 M Ӫwb{s AIX у 4 @~tWCPaAb{s AIX у 5 @~ tWw 64 AIX у 4 DB2 M]|yw~C we 64 AIX уAdb2setup ъ{|bѲMѾd o{уA]oX~TApUьG DBI1009E wCڃP AIX у YnκK~ATwzwOѓT 64 AIX уC ъ SMIT pGzъ SMITAh| AIX у 4 DB2 Q AIX у 5 DB2 N~A YL˗N|oс~C]A 64 AIX у 5 ъTwL wуOѓTCpGiHʛ db2setupABSѶ~TAh ь AIX уedºQC : e~Aъ 32 AIX уC ӗoс~ ӗAYºQA|b db2diag.log X{~ (۫ wх)AAiH˓~C ъux۫w̝zvA~|Ob SQLLIB\LOGGING ϓC IWH2RGn.LOG κtʪ~ۛTCpGoсzѝѓ~~AR ۫wsʛCpGOb{s۫wAoьzѝъ ѸC IBM(R) DB2(R) Connect vʛ DB2 Connect Enterprise EditionBDB2 Connect Unlimited Edition DB2 Connect Web Starter Kit w{|w~vCwAЮoÝ ~SnڿъvA]|HъR (Try-and-Buy) ʪB@ 90 C90 нADzʛAݬvA_hzw~N|B@C Ynʛ~vAziHъuDB2 vv db2licm OC ъuvvwzvX]wv 1. ʛuDB2 vAMߜqu\Ӭ񓴿vC 2. znwvtCww~|ьzww~WC 3. qv\Ӭ񓴿sWC 4. busWvvAqsAMߓnڿъvG * b Windows AWGx:\db2\license\connect\license_filenameA x: ьt DB2 Connect ~ CD ѷC * b UNIX AWG/db2/license/connect/license_filename license_filename ь DB2 Connect Enterprise Edition B DB2 Connect Unlimited Edition O db2conee.licA DB2 Connect Web Starter Kit hO db2consk.licC 5. @UъHsWvXC 6. ]wvC * Y DB2 Connect Unlimited Edition DB2 Connect Web Starter KitG buvvAqv\Ӭ񓴿CbuvvA qъk񑓴C@UTwHuvvA^u vvC : Y DB2 Connect Web Starter KitATwڼO]wzw ~ڛ_ 270 C * Y DB2 Connect Enterprise EditionG buvvAqv\Ӭ񓴿C buvvA zRvC * pGzRuъvvA𓴿 DB2 Connect ъ JzRъvC : DB2 Connect Enterprise Edition @˿ъnڿъvC l DB2 Connect ъvѝ˺ORC * pGzRuwUъvvA𓴿U DB2 Connect ъ AM߽@UTwHuvvAM߬^uvvC @UъAMsWzRnڿъvC@˿ъ IDC ъ db2licm OwzvX]wv ziHъ db2licm OsWvXAъъuvvCpъ db2licm OsWzvXJ 1. b Windows AWAJUCOG db2licm -a x:\db2\license\connect\license_filename x: Nݺt DB2 Connect ~ CD ѷC b UNIX AWAJUCOG db2licm -a db2/license/connect/license_filename license_filename N DB2 Connect Enterprise EditionADB2 Connect Unlimited Edition O db2conee.licAB DB2 Connect Web Starter Kit O db2consk.licC : Y DB2 Connect Web Starter KitATwڼO]wzw ~ڛ_ 270 C 2. ]wvJ * Y DB2 Connect Unlimited Edition DB2 Connect Web Starter KitG JUCOJ db2licm -p db2conee measured * Y DB2 Connect Enterprise EditionG pGzRuъvvAJUCOG db2licm -p db2conee concurrent db2licm -u N N NݜzRъvC pGzRuwUъvvAJUCOG db2licm -p db2conee registered 񔗝wv`N pGznыъ񔗝wMAhѝiSݪwHKbw@~ wvCsWe db2licm Oz񔗝w ScriptC sx۫w Windows NT w DB2 у 7Aы DB2 у 7 x۫wMxA CpGzW Visual Warehouse x۫wANtx w DB2 A񂻚 DB2 у 7Ax۫wyz۫|AH DB2 у 7 ۫㡌xʿъC~ъу 7A𝥘Ӯʪx wC DB2 у 7 wA@ъ񬀡x۫wyz۫|ӿу 7CӬ[x۫wyz۫Aъx۫wъ{ C Windows NTA}l --> {› --> IBM DB2 --> x۫w zAiʛCx۫wAХ\Windows DB2 Universal Database ͐tJ b AIX 5 Wъ IBM e-server p690 DB2 UDB у 7 b AIX 5 @~tWAIBM e-server p690 ft DB2 UDB у 7A̓n FixPak 6 hC Enterprise Edition UNIX CD-ROM ъ~ Aъ UNIX ѡxу 6 񊬮у 7 DB2 Universal Database (UDB) Enterprise Edition (EE) CD-ROMA]t@M 90 Ь DB2 Connect Enterprise Edition (CEE) ъCЮ DB2 Connect \ӼOы DB2 UDB EE ~A znbww DB2 UDB EE tWw DB2 CEE ~Nӿъ DB2 Connect \CpGzwF 90 Ь DB2 CEE ъABMw@v уANѝR DB2 CEE ~w DB2 CEE vXCznsw~C b DB2 EE DB2 CEE for UNIX ͐tJ@FwvXьC pGzwH EE wAwъ CEE ~AoQnі[aw CEEAz iHݗ`UCьAh 90 Ь CEE ъCpGzh Connect EE ъ ANMiHъ DB2 EE DB2 Connect \C Ynh DB2 Connect у 7AqUѡxЛwUC›G * b AIXAЛw db2_07_01.clic ›C * b NUMA-Q Solaris @~AЛw db2clic71 MnC * b LinuxAЛw db2clic71-7.1.0-x RPMC * b HP-UXAЛw DB2V7CONN.clic ›C Ynh DB2 Connect у 6AqUѡxЛwUC›G * b AIXAЛw db2_06_01.clic ›C * b NUMA-Q Solaris @~AЛw db2cplic61 MnC * b LinuxAЛw db2cplic61-6.1.0-x RPMC * b HP-UXAЛw DB2V6CONN.clic ›C DB2 Connect Enterprise Edition UNIX CD-ROM ъ~ Aъ UNIX ѡxу 6 񊬮у 7 DB2 Connect Enterprise Edition (EE) CD-ROMA]t@M 90 Ь DB2 Universal Database (UDB) Enterprise Edition (EE) ъC 90 Ь DB2 UDB EE ъ@ъA DB2 Connect B@OѝnC pGzwF 90 Ь DB2 UDB EE ъABMw@vуANѝ R DB2 UDB EE ~w DB2 UDB EE vXCznsw~Cb DB2 EE DB2 CEE for UNIX ͐tJ@FwvXьCpGz wH Connect EE wAwъ UDB EE ~AoQnі[aw CEEAziHݗ`UCьAh 90 Ь EE ъCpGzh DB2 UDB EE ъANvT DB2 Connect EE \C Ynh DB2 UDB EE у 7AqUѡxЛwUC›G * b AIXAЛw db2_07_01.elic ›C * b NUMA-Q Solaris @~AЛw db2elic71 MnC * b LinuxAЛw db2elic71-7.1.0-x RPMC * b HP-UXAЛw DB2V7ENTP.elic ›C Ynh DB2 UDB EE у 6AqUѡxЛwUC›G * b AIXAЛw db2_06_01.elic ›C * b NUMA-Q Solaris @~AЛw db2elic61 MnC * b LinuxAЛw db2elic61-6.1.0-x RPMC * b HP-UXAЛw DB2V6ENTP.elic ›C UNIX W Merant Driver Manager DB2 UDB у 7 ODBC X{ Merant Driver Manager b UNIX Ws DB2 ODBC X{Ab Unicode ޡo{FeCoeP Merant Driver Manager ъ UnicodeA̔ъ{O_nDѪъCoi|P~o сDAʪpu۫㡌xvBuۛT̝z{vH MQSIAѪn Merant Driver Manager D IBM ۫CziHъN DB2 ODBC X{픂ΫwAъ Unicode Aі[пMޫiпъ CvT DB2 UDB у]Aу 7.1 ft FixPak 2 sуAH񊬮у 7.2 ftѶ FixPak hC b AIXBHP-UX uSolaris @~v DB2 у 7.1 P 7.2 Aх ъ Unicode N DB2 ODBC X{픂ΫwCnъo˗N wAzѝы@ѸуAЩ˛уl DB2 ODBC X{픂ΫwWC : N (_36) Ϋw]t DB2 JDBC X{ʃ Unicode C ъΫwN\ JDBC ъ{ (]A WebSphere Application Server) ºQaft DB2 C Ynb AIXBHP-UX uSolaris @~vW񙗽D Unicode ODBC wAХ\UCOCЮoOԛ{AzѝbCs~@ A]Aъߑ FixPak ]@C AIX Ynb AIX WыѝΫwAG 1. HοʥͪѸAъ db2stop force ʪ۫wοC 2. H admin ο IDAъ db2admin stop force ̝zAοC 3. Ѹl db2.o ( /usr/lpp/db2__/lib U)C 4. H root AoX slibcleanC 5. N db2_36.o s db2.oATwʪv\iv񗀹@PCъUC ROG cp db2_36.o db2.o -r--r--r-- bin:bin for db2.o Yn񙗽^lѾAݗ`P{ALOъѸO db2_ 36.oC Solaris @~ YnыѝΫwAG 1. HοʥͪѸAъ db2stop force ʪ۫wοC 2. H admin ο IDAъ db2admin stop force ̝zAοC 3. Ѹl libdb2.so.1 ( /opt/IBMdb2/V./lib U)C 4. N libdb2_36.so.1 s libdb2.so.1ATwʪv\iv񗀹@ PCъUCROG cp libdb2_36.so.1 libdb2.so.1 -r-xr-xr-x bin:bin libdb2.so.1 5. wC˩۫wοoX db2iupdt Aw DAS οoX dasiupt C Yn񙗽^lѾAݗ`P{ALOъѸO libdb2_ 36.so.1C HP-UX - „ FixPak 4 sуъC zѝbпMެkeAѲw FixPak 4 sуC Ynb HP-UX WыѝΫwAG 1. ъ db2stop force ʪ۫wοC 2. ъ db2admin stop force ̝zAοC 3. Ѹl libdb2.sl ( /opt/IBMdb2/V./lib U)C 4. N libdb2_36.s1 s libdb2.s1ATwʪv\iv񗀹@PC ъUCROˢTw@PG -r-xr-xr-x bin:bin for libdb2.sl 5. wC˩۫wοoX db2iupdt Aw DAS οoX dasiupdt C Yn񙗽^lѾAݗ`P{ALOъѸO libdb2_ 36.s1C Ѫ UNIX @~t YzbѪ UNIX @~tWn DB2 M Merant Driver Manager UApuIBM vC w Web ۛTeѝn[[c w Web uۛTveAzѝNnwyѬ dg_strings.hti ΢s /sqllib/icuweb/macro ϓCziHbyϓ dg_strings.hti CziHb Quick Beginnings Guides NLS j Ѹ DB2 ѾyѢXMC rXyۛT - ѓ bu͐tJv@Ьu۫ay (NLS)vAurXyv ݫUC~G * Y "ۢX" "۫a/arX" * Y "y" "y/Script" * Slovenia NXO "sl"AOʽX "si" DB2 Data Links Manager ͐tJ AIX 5.1 W b AIX 5.1 W{bwю DB2 Data Links File Manager u·Lo vѾCbe AIX WʪPu۫vBeu񊽳 OA{bb AIX 5.1 WюBAъC Dlfm ʛЛTGo afsfid roс~ wb DCE-DFS ʩ Data Links ManagerApG dlfm ]UC~ A IBM AG o afsfid roс~ ݿъ "dlfm add_prefix" nO Data Links Manager DFS ›QR AN|oс~C ]wѸOs Tivoli Storage Manager O wѸOsъ@ TSM ̝zOA]w DLFM_TSM_MGMTCLASS DB2 n@˥Aݬ̝zOWC DFS qʛ{탦D DFS qʛ{ъѾAziHb DB2 Universal Database q Aw@C M DFS qʛ{훧n DB2 UDB qAAOAw DFS qʛ{ezѝw DB2 Universal Database qC F DFS qʛ{rXn 2 MB ~Abw DFS qʛ{ DB2 qw@ѸA zt~Od 40 MB B~C w DFS qʛ{ DB2 zq DB2 Aw@ѸAznhC DB2 Universal Database ~ʃnAȝ˩ۛTХ\ DB2 for UNIX tJUC b AIX ۫΀̝z{߀{ dlfm see OXCoXOˀb AIX ۫΀̝z{ ߀{AGPUCьG PID PPID PGID RUNAME UNAME ETIME DAEMON NAME 17500 60182 40838 dlfm root 12:18 dlfm_copyd_(dlfm) 41228 60182 40838 dlfm root 12:18 dlfm_chownd_(dlfm) 49006 60182 40838 dlfm root 12:18 dlfm_upcalld_(dlfm) 51972 60182 40838 dlfm root 12:18 dlfm_gcd_(dlfm) 66850 60182 40838 dlfm root 12:18 dlfm_retrieved_(dlfm) 67216 60182 40838 dlfm dlfm 12:18 dlfm_delgrpd_(dlfm) 60182 1 40838 dlfm dlfm 12:18 dlfmd_(dlfm) DLFM SEE nD\C A񀬀W dlfm οʬWAуʪW "dlfm"C wM[c DB2 Data Links Manager for AIXG DCE-DFS ʩB~w`N buwѲMѾvqAsWsۛTG z]ѝw e-fix for DFS 3.1A PTF › 1 (iъ)C ibHU e-fix ۛTG http://www.transarc.com/Support/dfs/datalinks/efix_dfs31_main_page.html HG ѝbw Data Links Manager e dfs qC ъ db2setup smittyC buKeytab vqA˓~˺ѓG tDڮMqXۛT keytab Aˀ datalink.ktb M .... ѓTWGdatalink.ktb OъbUdC uKeytab vq˝ uDCE-DFS ߩmw@~vUA] DLMADMIN οʽыAo˔~ ыC buData Links File Manager APqvA`NAѝb Data Links Manager qeѲw Data Links Manager AC sWuѸϓv`G YѸެkOwуοtA oѝO DFS οtϓC Tw DFS ̝zwы DFS ›C ›O DMLFS ›C Ь "dlfm add_prefix" O wb DCE/DFS ʩ Data Links ManagerA dlfm add_prefix Oi |A˪^X -2061 (Ѹ)CYoсpA𛧪UCBJG 1. oX dlfm stop O˛ Data Links Manager `n{{C 2. oX dlfm stopdbm O˛ DB2 {C 3. oX dce_login root O˿o dce root {C 4. oX dlfm startdbm O˜ʛ DB2 {C 5. oX dlfm add_prefixOnO Data Links Manager ›C 6. oX dlfm start O˜ʛ Data Links Manager `n{{C ͿѾGs`n{b dlfm 񯫂S oϜpoсCݿъoX dlfm stop Oѓ`A dlfm_copyd (copy `n{) SCpGoсoϜpAbsʛ dlfm eA oX dlfm shutdown OC wM[c DB2 Data Links Manager for AIXGъ db2setup ъ{b AIX Ww DB2 Data Links Manager buwы DB2 ۫w DLFM_DBvqADLFM_DB Oыb DCE_DFS CѝHߩmwBJ˛C buDMAPP DCE-DFS wѲʛnvqABJ 2 ˚pUG 2. sWO /opt/dcelocal/tcl/user_cmd.tclAHTw DFS ʛ]ʛF DMAPPC wM[c DB2 Data Links Manager for AIXGDCE-DFS ߩmw@~ sWUCu Data Links Manager wv`G b Data Links Manager AWAѝUCBJAHwG 1. buwM[c DB2 Data Links Manager for AIXvouDCE-DFS B~w`Nvo`AN keytab ыuKeytab vU nC 2. H root AJUCOHʛ DMAPPG stop.dfs all start.dfs all 3. pUCBJAъ dce root {ʿ˛ "dlfm setup"C a. H Data Links Manager DLMADMIN ̝znJC b. H root AoX dce_loginC c. JOGdlfm setupC b Data Links Manager qWAѝUCBJAHwG 1. buwM[c DB2 Data Links Manager for AIXvouDCE-DFS B~w`Nvo`AN keytab ыuKeytab vU nC 2. H root AJUCOHʛ DMAPPG stop.dfs all start.dfs all wM[c DB2 Data Links Manager for AIXGъ Smit ԛw DB2 Data Links Manager uSMIT ߩmw@~v`AκBJ 7 HX "dce_login root" O ѝb "dlfm setup" eoXC nBJ 11C bBJ 6 (dlfm server_conf) MBJ 8 (dlfm client_conf) A|BJC ] 𝥛BJ 12 (dlfm start)CYnwA𛧪UCBJG 1. buwM[c DB2 Data Links Manager for AIXvouDCE-DFS B~w`Nvo`AN keytab ыuKeytab vU nC 2. H root AJUCOHʛ DMAPPG stop.dfs all start.dfs all wM[c DB2 Data Links DFS qʛ{ bu[c DFS qʛ{v`ANUCۛT[BJ 2G "secval" Oq`|[cC LA]iӃnsʛC Ybs READ PERMISSION DB Ϋo{DA sʛw DB2 DFS qʛ{C wM[c DB2 Data Links Manager for Solaris @~t bw DB2 Data Links Manager for Solaris @~tѝUC@G 1. NUCTsW /etc/system G set dlfsdrv:glob_mod_pri=0x100800 set dlfsdrv:glob_mesg_pri=0xff set dlfsdrv:ConfigDlfsUid=UID UID N id dlfm ъ IDC 2. s}AHсC b Windows NT W۫ Administrator sMъv b Windows NT WANjѸ˿Aъ DataLinks ˖A ъ dlmadmin P UNIX W root ъҪPMъvCUݫN ԬF񱩹C +-----------------------+----------------------+----------------------+ | @~ | Unix (root) | Windows NT | | | | (dlmadmin) | +-----------------------+----------------------+----------------------+ | W | O | O | +-----------------------+----------------------+----------------------+ | Ois | O | O | +-----------------------+----------------------+----------------------+ | R | O | _ (U) | +-----------------------+----------------------+----------------------+ | s | O | _ (U) | +-----------------------+----------------------+----------------------+ : NTFS \oú@~bWC dlmadmin ъiHъ gJ\ivAHºQoú@~C N Data Links File System Filter (DLFF) wO ziH dlfs_cfg AN Data Links File System Filter (DLFF) w OCdlfs_cfg|ÿ strload `˩JX{[c C άmb /usr/lpp/db2_07_01/cfg/ ϓC zLA]ib /etc ϓo˔C dlfs_cfg άpUG d - 0 1 G d d Ѕ㽳wnJX{C driver-name driver-name OnJX{ҩ|CʪpA DB2 у 7 ҩ|O /usr/lpp/db2_07_01/bin/dlfsdrvCX{WO dlfsdrvC vfs number oO DLFS b /etc/vfs vfs C dlfm id oO DataLinks Manager ̝zъ IDC global message priority oO DLFS X{itmЅCѪ|wqnOtڃx TϖCьC global module priority oO DLFS X{itmЅCѪ|wqnOtڃx X{`BVFS @~ Vnode @~CьC 0 1 0 1 Oъ˽ыX{Ds`IprC`IWONp r[QsX{`IW˽ыC iWL 5 H Wpr (0-4)C {񬀢diӪpUG d /usr/lpp/db2_07_01/bin/dlfsdrv 14,208,255,-1 - 0 1 |OTO global message priority global module priority ]wˮwC YnNOAziH global message priority C 4 ˛TuѲºiHъG #define LOG_EMERGENCY 0x01 #define LOG_TRACING 0x02 #define LOG_ERROR 0x04 #define LOG_TROUBLESHOOT 0x08 jѸ DLFF 񬀛Tъ LOG_TROUBLESHOOT @TuѲºC oO@ N[cdG pGzun(emergency)T񊓨~TAN dlfs_cfg tm񬀅s TuѲºÐ]w 5 (1+4)G d /usr/lpp/db2_07_01/bin/dlfsdrv 14,208,5,-1 - 0 1 pGun~TANsTuѲºÐ]w 4G d /usr/lpp/db2_07_01/bin/dlfsdrv 14,208,4,-1 - 0 1 pGzn DLFS OAhNsTuѲºÐ]w 0G d /usr/lpp/db2_07_01/bin/dlfsdrv 14,208,0,-1 - 0 1 bwߛOT pGzbw߃nOB~񊀖ЛTAzѝκ dlfs_cfg C dlfs_cfg άmb/usr/lpp/db2_07_01/cfg ϓC sTuѲ ºѝ]w 255 (juѲº) | 13 (8+4+1)C NuѲºÐ]w 13 (8+4+1) |OB~񊀖ЩۛTC b]wsTuѲºAЛ DLFS LoοtAsJ dlfsdrv X{HbJъsuѲºáC bsJ dlfsdrv X {Aѝs DLFS LoοtC : AΚ dlfs_cfg AѶߑ dlfsdrv X{J|ъ P dlfs_cfg ]wC N Sun Solaris tWO@~Yp Sun(TM) Solaris(TM) tS dlfs_cfg Ctڃx`n{ (syslogd) NtTӃAڃxʿъۛTAb /etc/syslog.conf t CpGzQNuDLFF wvO@~YpAN /etc/syslog.conf kern.notice M kern.debug nϐ]wC~Azѝ syslogd ߪAsʛAo~|сC ݜzSQOʪ{qM~AЛ /etc/syslog.conf kern.notice M kern.debug nϬНABPn syslogd AsʛAoсC DATALINK _m ۫w_m߮iuѸ_mALΪS ROLL-FORWARDA|o ޿͐t@PBz{CpUAΖU DATALINK ʪݫNQm۫@Pm (DRP) AUC Data Links Manager z{biHw۫w DB2 Data Links ManagerCYé۫ SQL nDBz{ÃPъ{@ (ʪpAѸ/_m)A]tFPw[c۫ w DLM qHCbHeADB2 Lkw[c DLMAYѪ|хQ ъCoP SQL ъ{Bz{ì[B~tC@чsW DLMAbnD Bz{PѪqH̔Ai|PY SQL nD (ʪpAh /ݫ/۫w)C ъ SMIT Лw DLFM Ѿi|hB~› bqw Data Links Manager AIX WЛw DB2 (у 5B6 7) eAݗ`UCBJG 1. H root AъUCOѸ /etc/vfsG cp -p /etc/vfs /etc/vfs.bak 2. Лw DB2C 3. H root AъBJ 1 ʛѸN /etc/vfsG cp -p /etc/vfs.bak /etc/vfs }le/MwDqW zѝMwC@x DB2 A۫AWCzѝnDoDq WA~Ӛʪw@~CbsuDB2 Data Links ΀̝z{vADB2 UDB A|ÛeUCۛT DLFMG * ۫wW * οʪW * DqW M DLFM |NۛTPѪݫ@񱇴AHMwO_e\suыCu ۫wWBοʪWMDqWXwъ dlfm add_db OU DLFM Asu~|ыCb dlfm add_db OъDqWѝM DB2 UDB AÛeDqWюC ъHUCުʜoDqWG 1. b DB2 AWJ hostname OCʪpAOi|ê^ db2serverC 2. zѡxAUC@G * b AIX WAJ host db2server OA db2server OѲeBJ ʜoWCo˽O|ê^UCXG db2server.services.com is 9.11.302.341, Aliases: db2server * b Windows NT WAJ nslookup db2server OA db2server O ѲeBJʜoWCo˽O|ê^UCXG AGdnsserv.services.com }G9.21.14.135 WGdb2server.services.com }G9.21.51.178 * b Solaris @~WAJ cat /etc/hosts | grep 'hostname'Cp GDqWb /etc/hosts 񽳮wtԛWAho˽O| ê^UCXG 9.112.98.167 db2server loghost pGDqWwtԛWAhO|ê^UCXG 9.112.98.167 db2server.services.com loghost bъ dlfm add_db OU DB2 UDB ۫wъ db2server.services.com @DqWCpGb dlfm add_db OъѶѪOWAh DB2 A DLFM su|C YnN Data Links AU DB2 ۫wAiъ DB2 "add datalinks manager for database database_alias using node hostname port port_number" OC hostname O Data Links AWCbOiъѶ Data Links AOWC˪ Data Links A DATALINK ѝъ URL ˽ w hostnameFYb URL DATALINK Aѝъ "add datalinks manager" OʿъWCъPOWN|y SQL z C ъ DB2 Data Links File ManagerGq DB2 ۫w DB2 Data Links Manager ߬M@ ݿъ DROP DATALINKS MANAGER Oq۫wN DB2 Data Links Manager AOу|M DB2 Data Links Manager ۛTCъi HTa_lЛѶ۫wAHѸۛTU›Co iHъ dlfm drop_dlm O˺Co˽O|NSw۫wʪۛTDP BRCDB2 Data Links Manager ѝbAO~|\CD` nGOub DB2 Data Links Manager ~ӿъF_hAN|h DB2 Data Links Manager nۛTABLk^_C YnSw۫w_lЛBz{ѸۛTU›G 1. HuData Links ΀̝z{v̝znJtC 2. oXUCOG dlfm drop_dlm database instance hostname G database O DB2 UDB ۫wWF instance O۫wʪbοF hostname O۫wʪb DB2 UDB ADqWC 3. nXC YҬъkۛdAь˪pъOWUAХ\ Command ReferenceC wOыF@s~X (Х\"DLFM1001E (s~T)")C dlfm Client_conf 󫑫ъ@ b DLFM qApG dlfm client_conf ]YÝzЪA DB2 "stale" Ϯ\O]@CпMޫμoXUCOG db2 uncatalog db db2 uncatalog node db2 terminate MAA dlfm client_confC DLFM1001E (s~T) DLFM1001E: b drop_dlm Bz{ëoс~C ]G DB2 Data Links Manager Lkw۫w_lЛU›Bz{ CoiӪ]UCѶ@]oсG * DB2 Data Links Manager bC * O񽳮w۫wBοDqWXLC * b DB2 Data Links Manager Ѷ@ѾAC @G 𛧪UCBJG 1. Tw DB2 Data Links Manager bCʛ DB2 Data Links ManagerA pGѪbC 2. Tw۫wBοDqWXwq@wU۫wCzib DB2 Data Links Manager Wъ "dlfm list registered databases" OˇF ϬC 3. pG~MoсA db2diag.log 񬀩ۛTAdO_Ѷ ѾA (ʪpAConnection Management ServiceB Transaction Management Service ) C`N db2diag.log 񬀓~XA~XU ϑAݛ@C DLFM ]w[c dlfm setup dlfm.cfg wQhCbѾYAHC _mΫioсD DGpG@˔άPуObP۫wAݩ۫wni _mAData Links File Manager (DLFM) Retrieve `n{|Lk^ѓT sуC IGݜzqѸM_m۫wAѸMA]|]s Data Links Manager File System (DLFS) ˩@__mCU DB2 Data Links Manager ^M_m{ìB@ުC * pGWΝ{уeκMjpёuPvsn_ mΑAhW{|QOPάуCW{ |t~xs filename.MODAۃ_mhO DLFM s񬀔Ρ lуCʪpApG{ΪWO abcAabc |Qs abc.MODC * pGW{άeκMjpёuѮvsn_m ΑAData Links Retrieve `n{|]хgκA]Aqs _mάуC nGΪiөgLκAeκMjpёOCo uκv@kOΪvTάjpAMߜNeκ푦 ]lάeκ푦C dG]z@˩۫w DBTESTA۫wݫ@ DATALINK C{ bAzÛUC@~G 1. b DLFS eы fileA CoOά@ˬуC 2. b DBTEST ۫wJ fileA (URL)C 3. s@ DBTEST ۫wѸC 4. R DBTEST ۫w fileA C 5. b DLFS eR fileAC 6. b DLFS eыt@ fileA C oOάGˬуC 7. b DBTEST ۫wJ fileA (URL)C 8. _mѸM DBTEST ۫wC DLFM ^`n{|NGˬу fileA s fileA.MODAANs @ˬу fileA s DLFS eA@u@у fileAC OApGoGˬу fileA ͪPeκMjpёADLFM Retrieve `n{|]oÔάуPA]i_mC Adb DLFS eWOάGˬуA˽D@ˬуCz SuѓNοt_mPѸ񬀬APC пMޫGTwъ{|NΗ (eκMjp) P sC b AIX W Data Links/DFS Script dmapp_prestart oс~ pGO /usr/sbin/cfgdmepi -a "/usr/lib/drivers/dmlfs.ext" A˪^X 1 (bz Data Links/DFS Script dmapp_prestart)A w DFS 3.1 ptfset1 ˡѓ cfgdmepiC Tivoli Space Manager P Data Links ҪX DB2 Data Links Manager {bwҪ Tivoli Space Manager \WuIC Tivoli Space Manager Hierarchical Storage Manager (HSM) q{| NXΝӪxsAH@уοtWSwhiъCݪs ӬΫA|sIsoÔABe\ъ񊡽sIsS wC o\ӬѲMѾO Tivoli Space Manager у 4.2C ʿъοttnwThxs (񬀔οt탦n b@ٛW̝z) j񺽄ߪ˿AosSUC Tivoli Space Manager Ͻe@ެkˀ̝z\h߬ThxsC Tivoli Space Manager DB2 Data Links Manager s\ӗкjuˀ̝z DATALINK άC Tivoli Space Manager e\w Data Links ̝z οttmAκKѓ`ъ]G˥Pοt±IAn bʪiӔxs DB2 Data Links Manager οtwѲtm C sW Data Links P HSM οt H Hierarchical Storage Management (HSM) nOοtAѲH HSM nOAH DataLinks File Manager nOC 1. nO HSM AъO "dsmmigfs add /fs"C 2. nO DLM AъO "dlfmfsmd/fs"C οt Data Links zLUCnAMb HSM οt /etc/filesystems qG vfs = dlfs mount = false options = rw,Basefs=fsm nodename = - sW Data Links {s HSM οt nO DLM AъO "dlfmfsmd/fs"C sW HSM {s Data Links οt 1. nO HSM AъO "dsmmigfs add /fs"C 2. nO DLM AъO "dlfmfsmd/fs"C q Data Links-HSM οt Data Links Data Links AъO "dlfmfsmd -j /fs"C q Data Links-HSM οt HSM 1. HSM AъO "dsmmigfs remove /fs"C 2. Data Links O "dlfmfsmd -j /fs"C 3. nO DLM AъO "dlfmfsmd/fs"C q Data Links-HSM οt Data Links P HSM 1. HSM AъO "dsmmigfs remove /fs"C 2. Data Links AъO "dlfmfsmd -j /fs"C \ӡ у\ӪϽe„b AIX WъC FC (Read permission DB) (dsmmigrate) 񊿷^u root ъC b Read Permission DB μ DataLink Manager Administrator (dlfm) pUAuДΥͪCYnso AhnDq۫wOC@nOъ root ъCroot ъ Read Permission DB Λ 񊿷^񱩹eC„b@ӫA dlfm ъ~ӿъ O FC CYb^߇GA@~|A ^~T "ANS1028S {퓨~Cp߬ANC" D root ъLk FC Λ dsmmigrateC@٪˿As ΪAWά̝zvTjC stat M statfs tIs|N Vfs ь fsmA˽Dь dlfsAM dlfs b fsm WC WzN dsmrecalld `n{ѓ`\AbοtW statfs ˔d Vfs O_ fsmC Yάp inode X FC (Read permission DB) XAhO "dsmls" ьѶX dsmls O ls OACь TSM ̝zCnъ @ 4 wM[c DB2 Data Links Manager for AIX @٪w`N q DB2 File Manager у 5.2 ӿ DB2 Data Links Manager у 7 BJ 3 񬀩ۛTѓTCBJ 3 pUьG "3. H DLFM ̝zѸA /usr/lpp/db2_07_01/adm/db2dlmmg OC 6 . AIX Ww NFS 񬀩пMޫ `b NFS 񛧪 DB2 Data Links Manager for AIX w DпMޫAoѸb{ѾхJCoÛDO NFS SAM DB2 Data Links Manager DB2 Universal Database SѶYC [ NFS Ϳ b AIX NFS qWOԡPͿOCNFS q|H sϓ񺑦ˀ@Y@˺ͿOCq]| ъa۫ͿOAHKͿqWeC ͿBz|b READ PERMISSION DB νAb NFS q WсM`pCpGъObeNws AhoÿъNiHs READ PERMISSION DB ΪLs vCъUCѶ@ެk˗хvΪsiӮG * ѲbWъ touch OAMߪA SQL INSERT zH] wC * bt˔άϓWъ touch OC * ъ mount OPˑͿ[cЅ (actimeoB cregminB acregmaxBacdirminBacdirmax) @AHNήϓκ߽O dͿYpC bu۫v㗷Azi[хvs READ PERMISSION DB άA]u@˔ΐQB NFS 훉 Cz񱩹iӪbсJۛdA] NFS 훉ch Bq` NFS ͿOOdʪwάC wP[cR۫ 5 b UNIX @~tWw DB2 q HP-UX {[cЅ ϑ]w HP-UX {Ѕ㓨~X msgmbn msgmax ː]w 65535 Cԡ˛Ѕː]w 65535C 12 zvъ{ ъ Run-Time Client s۫wъ{ Run-Time Client ъːs۫wъ{ (JBXBBROB z)AB DB2 CLI |b۫wiHъeNΐsC@˩۫wC zѝъ DB2 Administration Client DB2 Application Development ClientC b۫wiHъoé۫wъ{M DB2 CLI seAѝN˩۫ wMѪisC UApGzъP@~thqA OP DB2 уA{ѻAzѝWsU˺@~tM DB2 уXъ{C UNIX qъ ODBC s DB2 b 12 (uzvъ{v) AH ODBC qъ{ ODBC SDK ˪w ODBC X{̝z{Ahns odbcinst.iniC o kѓTC]Aݜzw Merant ODBC X{̝z{~Ah ns odbcinst.iniC 24 ]mpXt˪sh۫ pXt DB2 pXtO@ DBMS SݖCpXtizd^bL DBMS W۫C@ SQL ziH˪h DBMS ˺O۫wCʪpAz iHXb DB2 Universal Database ݫBOracle ݫ Sybase ۫C DB2 pXt]tҪ DB2 οʬA (۫wNHpX۫wA) H@ ˮh˩۫C pX۫w]tкO۫ެϓnC ۫ ]A DBMS P۫C۫]AG * Oracle * Sybase * Microsoft SQL Server * Informix * DB2 Universal Database tC]p DB2 for OS/390B DB2 for AS/4000 DB2 for Windows^ DB2 Universal Database pXAiHQъ~hqHwːqH^ ۫۫Czъ~h DB2 οʬ@~tˮwC WOъ ˖кOb۫񬀬ݫPCъ{iHspX۫wAN ѶѪ DB2 ۫w@CѪiHъW˼d۫AnѪOp X۫w񬀬ݫ@C ]wpXtAYis۫񬀩ۛTAY۫Ob@у۫w Cъ񊔐ъ{ÛedpX۫wA˩۫wKq۫^ C DB2 pXtbѸU̺@C񔗝nDb DB2 у 7 i@ ~C~AzӛPW񤬀ъ{@~ ( LOADBREORGBREORGCHKB IMPORTBRUNSTATS )COAziHъzqAъP˩۫ SQL ъyAN DDL DML zX DBMSC pGъ DB2 у 8 ۫Ahn FixPak 8 sу ºQыAъ UNIX Windows DB2 у 8 ݫݬAzѝ NAъ UNIX Windows DB2 у 7.2 Fixpak 8 MъAъ UNIX Windows DB2 у 7.2 pX۫wCYхN Fixpak 8 Mъ UNIX Windows DB2 у 7.2 pX۫wAs|oс~C b FixPak Lkъу 7.2 s~h (p AIXBHP uSolaris @~ vW InformixFLinuxBHP uSolaris@~vW OracleFAIX uSolaris @~vW SybaseFH AIX P NT W Microsoft SQL Server)FzѝR DB2 Relational Connect у 7.2C w DB2 Relational Connect у`ЪbAWw DB2 Relational Connect OAzNH˪A@ pXtAC Relational Connect Os OracleBSybaseBMicrosoft SQL Server Informix ۫ѝCs DB2 Universal Database t CAhn DB2 Relational ConnectC w DB2 Relational Connect eJ * TwpXAWw DB2 Universal Database Enterprise Edition DB2 Universal Database Enterprise -- Extended EditionC b DB2 for UNIX AWJ YzїԜN DB2 tC۫wJz񔗝nDAhݜzw DB2 Universal Database Azѝ񔗝X DB2 ۫ CYnʼO_w۪A𔈼d FEDERATED ЅO_ ]w YESCziHoX GET DATABASE MANAGER CONFIGURATION O˔d]wAѪ|ьʪЅ{]wC * TwbzpXAWwwF۫qnC b Windows NT AWw DB2 Relational Connect 1. HzF DB2 Universal Database wʽыъbnJpX AC 2. Ѷ{Aw{~ӿˡnD˺sC 3. Isw{CziHުHHuުˮIsw{CYw{L kʛAzQnHPyћwAHHuުIsw{C * YnIsw{J a. N DB2 Relational Connect CD JC b. S|ʛw{CMwtyAʛ˃yѬw {C * Isw{G a. @U}lAC b. b}ʑAJUCOG x:\setup /i language G x Nݜz CD-ROM ѷC language NݜzyѬ۫a/aX]ʪpGEN Nݡ^^C c. @UTwC Y|}ʪwogxC 4. @UwA}lw{C 5. ݗ`w{񬀗ьC wA DB2 Relational Connect |PѪ DB2 ~wbϓC ʪpAOracle NET8 qn (net8.dll) ~hΫwAN|wb c:\Program Files\SQLLIB\bin ϓC b UNIX AWw DB2 Relational Connect Ynb UNIX pXAWw DB2 Relational ConnectAъ db2setup ъ{C G bzъ db2setup ъ{X{AwwbpXAW ϪˮwCoÿBJ|]zSw Relational ConnectC 1. HvъnJC 2. Jz DB2 ~ CD-ROMCp CD-ROM ެkAХ\ DB2 for UNIX ͐tJC 3. J cd /cdrom O ( cdrom Oz~ CD-ROM I)AH CD-ROM ϓC 4. J ./db2setup OCX񔑙A|}uw DB2 V7vC| CXzϽewwziHъ˪wC 5. znw񔗝XAp 񔗝X Informix ۫AM߽ UHѪCݜzAÖY|X{PC 6. TwC Y|}uы DB2 AvC 7. JMpXAwgt DB2 οA𓴥ы DB2 οʓAMߓ TwC 8. pGzыu̝zAvAh|X{iCTwC uDB2 w ъ{v|ьnwϬu`ivC]zeхw Relational ConnectA|CXԡG * DB2 Relational Connect ~O * z񔗝X۫ 9. ~C Y|X{@AXoOz Relational Connect ߥ|C TwH~wCiӃnX񔑙~ӺwC 10. uDB2 wъ{v|ьuAivAXѾwºQw CTwC|}uDB2 wъ{vCAMߓT wHъ{C wADB2 Relational Connect |PѪ DB2 ~wbϓC * b DB2 for AIX AAϓ /usr/lpp/db2_07_01C * b DB2 for Solaris Operating Environment AAϓ /opt/IBMdb2/V7.1C * b DB2 for HP-UX AAϓ /opt/IBMdb2/V7.1C * b DB2 for Linux AAϓ /usr/IBMdb2/V7.1C 24 ]mpXt˪sh۫ AЃPW@_ъ CREATE NICKNAME z񬀅WЅO@ϿԼqW -- σPWCpG zbыWAhWϜN|OыWъ authidC ыWAWۛT|xsb SYSCAT.TABLESB SYSCAT.TABOPTIONSBSYSCAT.COLUMNSB SYSCAT.COLOPTIONS P SYSCAT.INDEXES C _mpX۫wPpXA`N ݜzNpX۫w_m^PpXAA۫wMts DB2 tC ۫ʃs۫wP`IϓۛTCzѝb_mNۛT[Hs C 26 s Oracle ۫ Fb AIX Windows NT W~hH~A DB2 Universal Database {b] LinuxBSolaris @~ HP-UX W Oracle ~hC Oracle у 8CYnsoѡx~hAzѝJ V7.2 DB2 Relational Connect CD u񔗝X Oracle ۫vC @чzwF DB2 Relational ConnectAziHN Oracle ۫sWpX AG 1. b DB2 pXAWw[c Oracle qnC 2. UNIX W DB2 pXAA𛧪 djxlink ScriptAN Oracle SQL*Net Net8 Ϋws޿z DB2 pXAABы DB2 p X~hΫwAHKP Oracle ftъC 3. ы (s) db2dj.ini AHKsW Oracle ʚCo˔ѝ ORACLE_HOME ʚ㬀wqC 4. (ъ) ]w DB2_DJ_INI M DB2_DJ_COMM ]wnC 5. d DB2 pXAW Oracle tnsnames.ora mMeABъ Oracle sqlplus ˗ Oracle AsuC 6. sъ DB2 οC 7. ы~hC 8. ыAwqC 9. ыъMC 10. ъ Set Passthru ˗[cC 11. ыݫPݬWC oÿBJьA]A]wʚAiu 26 vC]mpXt ˪s DB2 wP[cR۫ Oracle ۫Cz]iHq http://www.ibm.com/software/data/db2/relconnect/ uWoۛTC Ѿ~ b"sW Oracle ۫pXt"qUC~G * bуЬBJ 2 3 탦n@ˬ[BJCeT˿BJpUьG 1. Ъ Oracle ЬѾAb DB2 pXAWw[c Oracle q nC 2. ]w ORACLE_HOME ʚG export ORACLE_HOME=. 3. UNIX ѡxW DB2 pXAA𛧪 djxlink ScriptAN Oracle SQL*Net Net8 Ϋws޿z DB2 pXAC zѡxAdjxlink Script mbG /usr/lpp/db2_07_01/bin on AIX Solaris @~W /opt/IBMdb2/V7.1/bin /opt/IBMdb2/V7.1/bin HP-UX /usr/IBMdb2/V7.1/bin Linux ub DB2 pXAWw Oracle qnA~ ScriptC 4. κ db2dj.ini οoX db2set OAH]w۫ʚC db2set O|ъz]ws DB2 ]wnC ]wʚ㬀ȝ˽ьiu 26 vC]mXt˪s DB2 wP[cR۫ Oracle ۫C 5. ~уʡzBJ 3 H߬BJC * ѾXn]wG DB2_DJ_INI = sqllib/cfg/db2dj.ini oOѓTAː]wpUG DB2_DJ_INI = $INSTHOME/sqllib/cfg/db2dj.ini ъ LOB nκKD ъ LOB Azi|oсODCʪpA]zq Oracle 񓴿 LONG ۫㬀dAN۫H CLOB J DB2 ݫCpG zSW[۫wъ{۫㛴jpAh| SQL ~AьuO vCYnпM~G 1. _ʪъ{P DB2 οʬsC 2. ъO˺sъ{۫㛴jpG db2 udpate db cfg for dbname using APPLHEAPSZ 1024 dbname OpX۫wWA1024 Oϑ۫㛴jpC 3. s_l]w۫wC YκKoсDAW[z۫wъ{۫㛴jpCYnс As_l]w۫wCʪpG 1. ъO˺sъ{۫㛴jpG db2 udpate db cfg for dbname using APPLHEAPSZ 1024 dbname OpX۫wWA1024 Oϑ۫㛴jpC 2. _ʪъ{P DB2 οʬsC 3. s_l]w۫wC s Sybase ۫ bzN Sybase ۫sWpXAeAzѝN Sybase Open Client nڪw[cb DB2 pXAWCХ\Ѿ񬀪w{AHb Sybase ۫wnAHopw Open Client nڬSwC]O w@~@ѸATwzb Sybase AWwF Sybase xs{A b DB2 pXAWwF Sybase Open Client ΫwC [cqnڃP Sybase AsuAъ@ Sybase u ˗suCisql uҥAъ UNIXASQL Advantage uҥAъ WindowsC Yn]wpXAAHsxsb Sybase ۫۫AzѝG 1. w DB2 Relational Connect у 7.2C Х\"w DB2 Relational Connect"C 2. sW Sybase ۫zpXAC 3. w Sybase rXC уQοBJ 2 3C уьiъb Windows NTBAIX Solaris @~CSwѡxP BoсaC sW Sybase ۫pXA YnsW Sybase ۫pXAAzѝG 1. ]wʚ㿖s]wn („Aъ AIX Solaris)C 2. DB2 P Sybase qn („Aъ AIX Solaris)C 3. sъ DB2 ο („Aъ AIX Solaris)C 4. ы]w¡C 5. ы~hC 6. ъG]w DB2_DJ_COMM ʚC 7. ыAC 8. ъG]w CONNECTSTRING AC 9. ыъMC 10. ыݫPݬWC у`NoÿBJ@ȝˬБC BJ 1G]wʚ㿖s]wn („Aъ AIX Solaris) κ db2dj.ini οoX db2set OAH]w۫ʚCdb2dj.ini ]tFwbpXAW Sybase qn[cۛTCdb2set O |ъz]ws DB2 ]wnC b񔐊۫wtAziHъSݫο񬀮ʪ`I񺐵@ db2dj.ini AъSݫο@h˩`I񺛋@ db2dj.ini Cх񔐊۫ wtAC@ο„i@ db2dj.ini C Yn]wʚG 1. sުb sqllib/cfg db2dj.iniA]wUCʚG SYBASE="" O Sybase qwϓC 2. oX db2set OAъz˺s DB2 ]wnC Oyk db2setAOHz۫wtcCYzѓbUCѶ۫wtc ъ db2dj.ini A~nBJG Yzѓbх񔐊۫wtъ db2dj.ini Azn db2dj.ini „ъϽe`IAoXG db2set DB2_DJ_INI=$HOME/sqllib/cfg/db2dj.ini Yzѓb񔐊۫wtъ db2dj.ini Azn db2dj.ini ъοʬʪ`IAoXG db2set -g DB2_DJ_INI=$HOME/sqllib/cfg/db2dj.ini Yzѓb񔐊۫wtъ db2dj.ini Azn db2dj.ini ъSw`IAoXG db2set -i INSTANCEX 3 DB2_DJ_INI=$HOME/sqllib/cfg/node3.ini G INSTANCEX NݫοʪWC 3 NݪCьb db2nodes.cfg ά`IXC node3.ini N db2dj.ini άκ񊺾WуC BJ 2GN DB2 Sybase qn („ AIX P Solaris @~) Ynъs Sybase ۫ADB2 pXAѝsުq wCs{HpXANqH۫˽ыC@˩۫~ hCݜz djxlink Script Aы~hΫwCYnoX djxlink Script G djxlink BJ 3Gsъ DB2 ο („Aъ AIX Solaris @~) YnTwʚ]w{Asъ DB2 οCݜzsъο A_s DB2 οHzʺ@C oXUCOHsъ DB2 οG b DB2 for Windows NT AWG NET STOP instance_name NET START instance_name b DB2 for AIX Solaris AWG db2stop db2start BJ 4Gы]w¡ Ynы]w¡AzѝыοisC 1. ъ Sybase Ьъ{˽ы¡A]AQsʪ Sybase Open Server ۫CХ\ Sybase wѾAHoъъ{ ȝ˩ۛTC Windows NT q`NήRW sql.iniC Nz޽ыAq sql.ini sRW interfacesA sъʪѡxήRWCYznN sql.ini sRW interfacesAzѝъ IFILE Ѕ㮊 CONNECTSTRING AbBJ 8 񪐃C b AIX Solaris tWAμORW /sqllib/interfacesC 2. ¡is DB2C b DB2 for Windows NT AWG Nήmb DB2 οʬ %DB2PATH% ϓC b DB2 for AIX Solaris AWG Nήmb DB2 οʬ $HOME/sqllib ϓCъ ln OA q DB2 οʬ $HOME/sqllib ϓ񺔂CʪpG ln -s -f /home/sybase/interfaces /home/db2djinst1/sqllib BJ 5Gы~h ъ CREATE WRAPPER z˽w~hANъ˪s Sybase ۫C~ hO@ϥApXAъːqH^۫۫CDB2 ]Aԡ Sybase ~hGCTLIB DBLIBC UCdʚь CREATE WRAPPER zG CREATE WRAPPER CTLIB CTLIB O Sybase Open Client nڿъw]~hWCCTLIB ~hi ъ Windows NTBAIX Solaris AC ziHъzW˿Nw]~hWCOAYzoAz]ѝ]t CREATE WRAPPER zpXA LIBRARY Ѕ~hΫwWC Х\ DB2 SQL Reference CREATE WRAPPER zAHo~h`w Wȝ˩ۛTC BJ 6GъG]w DB2_DJ_COMM ʚ Ynbs Sybase ۫WiA]w DB2_DJ_COMM ʚC |P_O_nbpXA_l]wAJ~hC ]w DB2_DJ_COMM H]A~hΫwAPzbe@BJw~hFʪpG b DB2 for AIX AWG db2set DB2_DJ_COMM='libctlib.a' b DB2 for Solaris AWG db2set DB2_DJ_COMM='libctlib.so' Twѩ (=) ԖSC Х\ DB2 SQL ReferenceAHo~h`wWȝ˩ۛTCХ\ Administration GuideAHo DB2_DJ_COMM ʚ㬀ۛTC BJ 7GыA ъ CREATE SERVER zˮwqC@Qnqs۫ Sybase AAʪpG CREATE SERVER SYBSERVER TYPE SYBASE VERSION 12.0 WRAPPER CTLIB OPTIONS (NODE 'sybnode', DBNAME'sybdb') G SYBSERVER Nݜzw Sybase AWCWѝO@C SYBASE Nݜzn[cs۫CSybase O@۫C 12.0 Nݜzns Sybase уCу 10.0B11.0B11.1B 11.5B11.9 12.0C CTLIB Nݜzb CREATE WRAPPER z񽳮w~hWC 'sybnode' N SYBSERVER `n`IWCb¡񿷜o`IC jpgC M`IWOwA Sybase ۫ʃCХ\ DB2 SQL ReferenceAHoLۛTC 'sybdb' NݜzQns Sybase ۫wWCziHq Sybase Ao o˪WC ziHъ IGNORE_UDT Aft CTLIB DBLIB qHwA˽wp XAO_˺PwSюX UDT UϖCo˪Au AъzL CTLIB M DBLIB qHws۫CG 'Y' UDT пъwqo˿APwѪUϖC 'N' UDT ъwqWCoOw]]wC DB2 ыWAѪ|Msϖ˅Wʽ񺬽Ѿ (ݫBBx s{) ۛTCbѪMۛTAѪi|o{ѸѾҪѪLkٖЬ 㖎 (]NOAхMpX۫wWу۫㖎)CoLkٖ i]AG * sϖ * ҪюX UDT * SюX UDTCoüOъy[WwϖCoÖu Yé۫Aʪp Sybase M Microsoft SQL ServerC ݙpXAo{ѪLkٖЬ۫㖎AѪ|ê^~T SQL3324NCM A@kiӪ~CYOizL CTLIB DBLIB qHws۫A ziH]w IGNORE_UDT AAHKݙpX۫wo{LkٖBS юX UDT ApX۫wӺPw UDT ϖCAYpX ۫w{oiϖApX۫wK|NϖۛTê^CYnp X۫wPwSюX UDT ϖAN IGNORE_UDT ] 'Y'C BJ 8GъG]w CONNECTSTRING A wO{B¡ά|PW¡ά񔽉jpC Sybase Open Client ъO{˺_ˬdP^CziHъ CREATE SERVER OPTION DDL z CONNECTSTRING A]w DB2 {Cъ CONNECTSTRING ˽wG * SQL dOC * nJ^OC * W¡|WC * 񔽉jpC .-;----------------------------. V | >>---+--------------------------+-+---------------------------->< +-TIMEOUT-- = -----------+ +-LOGIN_TIMEOUT-- = -----+ +-IFILE-- = --"string"-----+ +-PACKET_SIZE-- = --񩝞-+ '-;------------------------' TIMEOUT w DB2 Universal Database ѽѶ SQL z Sybase Open Client ^݅Cseconds b DB2 Universal Database ҅dAO@ ѓ҅CzwOOzъ~hC Windows NTBAIX Solaris AiHQъ DBLIB ~hCDBLIB ~hw]O 0C b Windows NTB AIX Solaris AWADBLIB w]| DB2 Universal Database Laѽ^C LOGIN_TIMEOUT w DB2 Universal Database ѽ Sybase Open Client ^nJnD ݅Cw]P TIMEOUT PC IFILE w Sybase Open Client ¡ά|WCb string кO|ѝ H̩ (") tACb Windows NT AWAw]O %DB2PATH%C b AIX Solaris AWAw]O sqllib/interfacesAbz DB2 Universal Database οʬ_lϓC PACKET_SIZE w¡ά񔽉jp (񩝞)CY۫w񔽉jpAs uN|CݿC@˛Oj (ʪpANCJjݫ)AW[ 񔽉jpiҪaW[C 񩝞jpO@˅㡄CХ\ Sybase Ъ UHoȝ˩ۛTC dG b Windows NT AWAъUCOANO]w 60 AN¡ ΐ]w C:\etc\interfaces G CREATE SERVER OPTION connectstring FOR SERVER sybase1 SETTING 'TIMEOUT=60;LOGIN_TIMEOUT=5;IFILE="C:\etc\interfaces"' b AIX P Solaris AWAъUCOANO]w 60 AN ΐ]w /etc/interfaces G CREATE SERVER OPTION connectstring FOR SERVER sybase1 SETTING 'TIMEOUT=60;PACKET_SIZE=4096;IFILE="/etc/interfaces"' BJ 9GыъM YpXA񬀿ъ ID PqXAP Sybase 񬀿ъ ID PqX PAъ CREATE USER MAPPING zAуъ ID P Sybase ۫ wqъ ID PqX񼇴MFʪpG CREATE USER MAPPING FOR DB2USER SERVER SYBSERVER OPTIONS ( REMOTE_AUTHID 'sybuser', REMOTE_PASSWORD 'day2night') G DB2USER NݜzъˇMъ ID (wq Sybase ۫) у ъ IDC SYBSERVER Nݜzb CREATE SERVER zwq Sybase ۫WC 'sybuser' NݜznM DB2USER Sybase ۫ъ IDC jpgC 'day2night' N݃P 'sybuser' qXCjpgC Х\ DB2 SQL ReferenceAHoLȝ˩ۛTC BJ 10GыݫPݬW wbz Sybase ۫񬀿C@ݮݫWCݜzd Sybase ۫ANъoÅWC Sybase WjpgCNݫW H̩ (") tACUCdʚь CREATE NICKNAME zG CREATE NICKNAME SYBSALES FOR SYBSERVER."salesdata"."europe" G SYBSALES N Sybase ݫݬMъWC SYBSERVER."salesdata"."europe" Nݓݗ`UCTкOrG data_source_name."remote_schema_name"."remote_table_name" wzQnыWC@ˬݫA㪇BJCݜzыWADB2 Nъsu˼d۫Cd|s۫AC Ysu LkB@Az|@˓~TC Х\ DB2 SQL ReferenceAHo CREATE NICKNAME zȝ˩ۛTC @مWʩ۫㖎Mȝ˩ۛTAХ\ DB2 Administration GuideC w Sybase rX BJ„b DB2 pXA Sybase APrX«~nCъ P DB2 PrX›۫nӗCUCݫ@u۫ay (NLS)vrX¬P Sybase C z Sybase ۫[cѝPyN Aq{XѝӛyNANь~Bъ уyNˇM۫C YqlrX¿υrXAӗAh DB2 |oX~TCХ\z Sybase ѾHoȝ˩ۛTC 2. uSybase rXv +-------------+-------------------------------------------------------+ | rX | P Sybase | +-------------+-------------------------------------------------------+ | 850 | cp850 | +-------------+-------------------------------------------------------+ | 897 | sjis | +-------------+-------------------------------------------------------+ | 819 | iso_1 | +-------------+-------------------------------------------------------+ | 912 | iso_2 | +-------------+-------------------------------------------------------+ | 1089 | iso_6 | +-------------+-------------------------------------------------------+ | 813 | iso_7 | +-------------+-------------------------------------------------------+ | 916 | iso_8 | +-------------+-------------------------------------------------------+ | 920 | iso_9 | +-------------+-------------------------------------------------------+ ъ ODBC s Microsoft SQL Server ۫]sW`^ bzN Microsoft SQL Server ۫sW DB2 pXAeAzѝN ODBC X{w[cbpXAWCХ\Ѿ񬀪w{AHb ODBC X{AHopw ODBC X{SwC Yn]wpXAHsxsb Microsoft SQL Server ۫۫Az ѝG 1. bpXAWw[c ODBC X{CХ\Ѿ񬀪w{AH b ODBC X{AHopw ODBC X{SwC b DB2 for Windows NT AWG ъ ODBC m̝z{[ct DSNCb Windows ODBC Data Source Administrator 񽳮w SQL Server X{AB` AsWsut DSNvC𽳮wuSQL Aʜъ ъЬnJ ID MqXvC b DB2 for AIX AWG w MERANT ЬуAw MERANT Ϋwϓ LIBPATH 񬀝@nA]w .odbc.ini C 2. w DB2 Relational Connect у 7.2C Х\"w DB2 Relational Connect"C 3. sW Microsoft SQL Server ۫zpXAC 4. w Microsoft SQL Server rXC(„Aъ Windows NT) уQοBJ 3 4C уьiъb Windows NT AIX ѡxCSwѡxPBoс aC sW Microsoft SQL Server ۫pXA bzw ODBC X{ DB2 Relational Connect AъUCBJAN Microsoft SQL Server ۫sWzG 1. ]wʚ („ AIX)C 2. Shell Script („ AIX)C 3. ъG]w DB2_DJ_COMM ʚC(„Aъ AIX) 4. sъ DB2 ο („ AIX)C 5. ы~hC 6. ыAC 7. ыъMC 8. ыݫPݬWC 9. ъGo ODBC lC UCU`NoÿBJ@ȝˬБC BJ 1G]wʚ („ AIX) κ db2dj.ini οoX db2set OAH]w۫ʚCdb2dj.ini ]tۛTϬAHs Microsoft SQL Server ۫Cdb2set O|ъ z]ws DB2 ]wnC b񔐊۫wtAziHъSݫο񬀮ʪ`I񺐵@ db2dj.ini AъSݫο@h˩`I񺛋@ db2dj.ini Cх񔐊۫ wtAC@ο„i@ db2dj.ini C Yn]wʚG 1. sުb sqllib/cf$HOME/sqllib/cfg/g db2dj.iniA]wUC ʚG ODBCINI=$HOME/.odbc.ini DJX_ODBC_LIBRARY_PATH=/lib DB2ENVLIST=LIBPATH oX db2set OAъz˺s DB2 ]wnCdb2set ykAOH z۫wtcC * Yzѓbх񔐊۫wtъ db2dj.ini AYzb񔐊۫w tъ db2dj.ini ABzn db2dj.ini 񬀡„ъϽe `IAoXUCOG db2set DB2_DJ_INI=/db2dj.ini * Yzѓb񔐊۫wtъ db2dj.ini Azn db2dj.ini ъοʬʪ`IAoXUCOG db2set -g DB2_DJ_INI=/db2dj.ini * Yzѓb񔐊۫wtъ db2dj.ini Azn db2dj.ini ъSw`IAoXUCOG db2set -i INSTANCEX 3 DB2_DJ_INI=$HOME/sqllib/cfg/node3.ini G INSTANCEX NݫοʪWC 3 NݪCьb db2nodes.cfg ά`IXC node3.ini N db2dj.ini άκ񊺾WуC Yn]wqΫw|AoXoýOG db2set DB2LIBPATH= db2set DB2ENVLIST=LIBPATH BJ 2G Shell Script („ AIX) djxlink.sh Shell Script qΫw~hΫwCYn Shell ScriptG djxlink BJ 3GъG]w DB2_DJ_COMM ʚ („Aъ AIX) Yzo{OLh˪s Microsoft SQL Server ۫AziHb pXA_l]wA˽Dbzs۫A]w DB2_DJ_COMM ʚ U~hA pKiWiC]w DB2_DJ_COMM ʚH]A~h ΫwAPzb 5 BJw~hCʪpG b DB2 for Windows NT AWG db2set DB2_DJ_COMM=djxmssql3.dll b DB2 for AIX AWG db2set DB2_DJ_COMM=libmssql3.a Twѩ (=) ԖSC Х\ DB2 SQL ReferenceAHo~h`wWȝ˩ۛTC BJ 4Gsъ DB2 ο („ AIX) YnTwʚ]w{Asъ DB2 οCݜzsъοʫA _s DB2 οHzʺ@C oXUCOAsъ DB2 οG db2stop db2start BJ 5Gы~h DB2 Universal Database ԀϐqHwA~hAziHъ˪s Microsoft SQL Server ۫C~hO@ϥApXAъːqH ^۫۫Czъ~hOH DB2 Universal Database ѓb ѡxCъ 3 @nAHAݬ~hC 3. ODBC X{ +----------------------------------+---------------+------------------+ | ODBC X{ | ѡx | ~hW | +----------------------------------+---------------+------------------+ | ODBC 3.0 (sу) X{ | Windows NT | DJXMSSQL3 | +----------------------------------+---------------+------------------+ | MERANT DataDirect Connect ODBC | AIX | MSSQLODBC3 | | 3.6 X{ | | | +----------------------------------+---------------+------------------+ ъ CREATE WRAPPER z˽w~hANъ˪s Microsoft SQL Server ۫C UCdʚь CREATE WRAPPER zG CREATE WRAPPER DJXMSSQL3 DJXMSSQL3 O DB2 for Windows NT A (ъ ODBC 3.0 X{) W ъw]~hWC Yz DB2 for AIX AAziHw MSSQLODBC3 ~hWC ziHъzW˿Nw]~hWCOAYzoAzѝ]t CREATE WRAPPER zpXAѡx LIBRARY Ѕ~hΫwWC ʪpG b DB2 for Windows NT AWG CREATE WRAPPER wrapper_name LIBRARY 'djxmssql3.dll' wrapper_name OzQn~hWA 'djxmssql3.dll' O`wWC b DB2 for AIX AWG CREATE WRAPPER wrapper_name LIBRARY 'libmssql3.a' wrapper_name OzQn~hWA 'libdjxmssql.a' O`wWC Х\ DB2 SQL Reference CREATE WRAPPER zAHo~h` wWȝ˩ۛTC BJ 6GыA ъ CREATE SERVER zˮwqzQnsC@ Microsoft SQL Server ۫CʪpG CREATE SERVER sqlserver TYPE MSSQLSERVER VERSION 7.0 WRAPPER djxmssql3 OPTIONS (NODE 'sqlnode', DBNAME 'database_name') G sqlserver Nݜzw Microsoft SQL Server AWC WѝO @C MSSQLSERVER Nݜzn[cs۫C 7.0 Nݜzns Microsoft SQL Server уCDB2 Universal Database Microsoft SQL Server у 6.5 P 7.0C DJXMSSQL3 Nݜzb CREATE WRAPPER zwq~hWC 'sqlnode' Ot DSN WA˜zѓbs Microsoft SQL Server уC jpgCDB2 Universal Database Microsoft SQL Server у 6.5 P 7.0C M`IW (t DSN W) Ow CREATE SERVER z A Microsoft SQL Server ۫ʃCYOb Windows WAziHq Windows ODBC Data Source Administrator u Ҭut DSNv񿷜o DSNCYOb AIX WAziHq DB2 ʥͪ_lϓ񀬀 .odbc.ini 񿷜o DSNC Х\ DB2 SQL ReferenceAHoziHP CREATE WRAPPER z ftъLC 'database_name' Nݜzns۫wWC M۫wWOw CREATE SERVER z񬀓A Microsoft SQL Server ۫ʃC BJ 7GыъM YpXA񬀿ъ ID PqXAP Microsoft SQL Server 񬀿ъ ID PqXPAъ CREATE USER MAPPING zAуъ ID P Microsoft SQL Server ۫wqъ ID PqX񼇴MFʪpG CREATE USER MAPPING FOR db2user SERVER server_name OPTIONS (REMOTE_AUTHID 'mssqluser', REMOTE_PASSWORD 'day2night') G db2user NݜzъˇMъ ID (wq Microsoft SQL Server ) уъ IDC server_name Nݜzb CREATE SERVER zwqAWC 'mssqluser' N Microsoft SQL Server ۫nJ IDAznъˇM db2userCjpgC 'day2night' N݃P 'mssqluser' qXCjpgC Х\ DB2 SQL ReferenceAHoziHъ CREATE USER MAPPING z LC BJ 8GыݫPݬW wzQns Microsoft SQL Server ۫AC@ݫ WCݜzd Microsoft SQL Server ۫ANъoÅWC ъ CREATE NICKNAME z˽wWCWjpgCUCdʚь CREATE NICKNAME zG CREATE NICKNAME mssqlsales FOR server_name.salesdata.europe G mssqlsales N Microsoft SQL Server ݫݬMъWC server_name.salesdata.europe Nݓݗ`UCTкOrG data_source_server_name.remote_schema_name.remote_table_name ϑzb remote_schema_name remote_table_name Ѹъ ̩C ݜzыWADB2 |s۫ݫ (Microsoft SQL Server ːoìݫ@tݫ)Co|s۫ACYsuAz| @˓~TC wzQnыWʪ۫wݫA㪇BJC CREATE NICKNAME zȝ˩ۛTAХ\ DB2 SQL ReferenceC @مWʩ۫㖎Mȝ˩ۛTA Х\ DB2 Administration GuideC BJ 9GъGo ODBC l Yzs۫JDAziHo ODBC lۛTAHRпMo DC YnTw ODBC lB@ѓ`AъuODBC ̝۫zv luCʛl|vTtA]ݜzwпMDA˖l C d Microsoft SQL Server rX („Aъ Windows NT) Microsoft SQL Server \h DB2 UDB @u۫ay (NLS)v rX“C ъP DB2 PrX›۫nӗCݫ 3 Cь DB2 Universal Database Microsoft SQL Server rXC 4. DB2 UDB Microsoft SQL Server rX“ +-------------+-------------------------------------------------------+ | rX | y | +-------------+-------------------------------------------------------+ | 1252 | ISO r› | +-------------+-------------------------------------------------------+ | 850 | hσy | +-------------+-------------------------------------------------------+ | 437 | ^ | +-------------+-------------------------------------------------------+ | 874 | y | +-------------+-------------------------------------------------------+ | 932 | | +-------------+-------------------------------------------------------+ | 936 | | +-------------+-------------------------------------------------------+ | 949 | y | +-------------+-------------------------------------------------------+ | 950 | c | +-------------+-------------------------------------------------------+ | 1250 | Dnwy | +-------------+-------------------------------------------------------+ | 1251 | ʃy | +-------------+-------------------------------------------------------+ | 1253 | 㖥y | +-------------+-------------------------------------------------------+ | 1254 | gy | +-------------+-------------------------------------------------------+ | 1255 | B | +-------------+-------------------------------------------------------+ | 1256 | ȺBy | +-------------+-------------------------------------------------------+ DB2 pXAP Microsoft SQL Server Pu۫ay (NLS)vrX«Az Microsoft SQL Server ۫[cѝPyN Aq{XѝӛyNANь~Bъ уyNˇM۫CYqlrX¿υrXAӗAh DB2 |oX~TCХ\z Microsoft SQL Server ѾAHoȝ˩ۛTC s Informix ۫]sW`^ bzsW Informix ۫ DB2 pXAeAѝѲbpXAWw [c Informix Client SDK nCХ\ Informix ۫wnڔHѾ w{AHopw Client SDK nڬSwC]Ow@ ѸATw]AF Informix Client SDK ΫwC Yn]wpXAHsxsb Informix ۫񬀩۫AzѝG 1. w DB2 Relational ConnectCХ\"w DB2 Relational Connect"C 2. ъs DB2 FixPakC 3. sW Informix ۫pXAC уBJ 3C у񬀽ьAъ AIXBSolaris @~ HP-UX @~tCoсSw@~ tt|[HC sW Informix ۫pXA YnsW Informix ۫pXAAzѝG 1. ]wʚ㿖s]wnC 2. DB2 Informix qnC 3. sъ DB2 οC 4. ы Informix sqlhosts C 5. ы~hC 6. ъG]w DB2_DJ_COMM ʚC 7. ыAC 8. ыъMC 9. ыݫB݃P Informix PqrWC у`NoÿBJ@ȝˬБC BJ 1G]wʚ㿖s]wn κ db2dj.ini οoX db2set OAH]w۫ʚCdb2dj.ini κtwbpXAW Informix qnڬ[cۛTCdb2set O|ъz]ws DB2 ]wnC b񔐊۫wtAziHъSݫο񬀮ʪ`I񺐵@ db2dj.ini AъSݫο@h˩`I񺛋@ db2dj.ini Cх񔐊۫ wtAC@ο„i@ db2dj.ini C Yn]wʚG 1. s sqllib/cfg ϓ db2dj.ini AMߐ]wUCʚG : pGt񙕿SAziHыC INFORMIXDIR N INFORMIXDIR ʚ]ww Informix Client SDK n ϓ|FʪpG INFORMIXDIR=/informix/csdk INFORMIXSERVER |wqw] Informix AWC INFORMIXSERVER=inf93 G M Informix ~hъ㡄A Informix qn D]wC~h|ъ node AAˡwzn s Informix ۫wAC INFORMIXSQLHOSTS pGzъO Informix sqlhosts ($INFORMIXDIR/etc/sqlhosts) w]|AzNn]w COApGzOъw]H~ Informix sqlhosts Ω |AhzѝN]w Informix sqlhosts άҩ| WCʪpG INFORMIXSQLHOSTS=/informix/csdk/etc/my_sqlhosts 2. ъ Informix ʚ㺾s DB2 οʬ .profile CziHoXUC O]wXC@˚AH@~G PATH=$INFORMIXDIR/bin:$PATH export PATH INFORMIXDIR= export INFORMIXDIR informix_client_path OpXAWw Informix qϓ |CpG|񬀪WtўAb|e[W̩ (")C 3. n DB2 ο .profileAJG . .profile 4. oX db2set OAъz˺s DB2 ]wnC Oyk db2setAOHz۫wtcCYzѓbUCѶ۫wtc ъ db2dj.ini A~nBJG Yzѓbх񔐊۫wtъ db2dj.ini Azn db2dj.ini „ъϽe`IAoXG db2set DB2_DJ_INI=/sqllib/cfg/db2dj.ini : q񬀩|WOҬCʪpA my_home/my_instance/sqllib/cfg/db2dj.ini Yzѓb񔐊۫wtъ db2dj.ini Azn db2dj.ini ъοʬʪ`IAoXG db2set -g DB2_DJ_INI=/sqllib/cfg/db2dj.ini Yzѓb񔐊۫wtъ db2dj.ini Azn db2dj.ini ъSw`IAoXG db2set -i INSTANCEX 3 DB2_DJ_INI=sqllib/cfg/node3.ini G INSTANCEX NݫοʪWC 3 NݪCьb db2nodes.cfg ά`IXC node3.ini N db2dj.ini άκ񊺾WуC BJ 2J DB2 Informix qn Ynъs Informix ۫Ah DB2 pXAѝsުq ΫwCsސBz|wpXAnqHC@˩۫Aы~h wCݜz djxlinkInformix Script AY|ы Informix ~hΫwC YnoX djxlinkInformix ScriptAJG djxlinkInformix : djxlinkInformix Script u|ы Informix ~hΫwCt@ djxlink Script |w DB2 Universal Database C@˩۫ ]OracleB Microsoft SQL Server ^ы~hΫwCpGz uww۫qnAhݜzoX djxlink Script A|C@˓|۫~TC zѝҐ UNIX Systems Administrator () vA~ӛ djxlinkInformix M djxlink ScriptC djxlinkInformix M djxlink Script |@~tANȝˬ~M iTgSwCʪpAYOb AIX WAdjxlinkInformix Script |g /usr/lpp/db2_07_01/lib/djxlinkInformix.outAdjxlink Script |g /usr/lpp/db2_07_01/lib/djxlink.outC djxlinkInformix M djxlink Script |@~tAbSwϓ ы~hΫwCʪpAYOb AIX WAh|b /usr/lpp/db2_07_01/lib ϓы libinformix.a ~hΫwC Ϫn libinformix.a ~hΫwAndΫwW\ivA Tw DB2 οʥͪiH񊛧CpG DB2 οʥͪO System s񬀪A libinformix.a ~hΫwW\ivѝO -rwxr-xr-x t...libinformix.aC BJ 3Gsъ DB2 ο YnTwʚ]w{Asъ DB2 οCݜzsъο A_s DB2 οHzʺ@C oXUCOHsъ DB2 οG b DB2 for AIXBSolaris @~ HP-UX AWG db2stop db2start BJ 4Jы Informix sqlhosts |wC@ Informix ۫wAm۫wAsu]q Hw^Cыo˔άެk\hCziHq Informix Connect Informix Client SDK s Informix ALtAˢsCz]i Hb DB2 AW[c Informix Client SDK s Informix AAѪ ы sqlhosts C ݜzыOsn sqlhosts ADB2 οʥͪ˗Nӿъ Informix dbaccess (pGѪb DB2 AW) ːsd Informix ACo Informix Client SDK NӐs Informix AAz]i˻Ӽ[c DB2 Relational Connect ˿ъ Informix Client SDKC p]mάۛTA Informix U Administrators Guide for Informix Dynamic ServerC +---- iJ ----------------------------------------------------------+ pGzSb sqlhosts wq Informix ۫wAWAhݜz ns Informix ۫wA@~AN|~C +----------------------------------------------------------------------+ BJ 5Gы~h ъ CREATE WRAPPER z˽wnъ˪s Informix ۫~hC~ hO@ϥApXAъːqH^۫۫CUCdʚ ь CREATE WRAPPER zG CREATE WRAPPER informix informix O wrapper_nameFinformix OP Informix Client SDK n@ _ъw]~hWC ziHъzW˿Nw]~hWCOAYzoAz]ѝ]t CREATE WRAPPER zpXA LIBRARY Ѕ~hΫwWC Х\ DB2 SOL Reference CREATE WRAPPER zAHo~hΫwW ۛTC Informix ~hΫwWJ * libinformix.a (AIX) * libinformix.so]Solaris @~^ * libinformix.sl (HP-UX) BJ 6GъG]w DB2_DJ_COMM ʚ YnWis Informix ۫AbpXAW]w DB2_DJ_COMM ʚC|MwO_nb_l]wpXAJ~hC]w DB2_DJ_COMM ʚHJ~hΫwAzbeBJʽw ~hCpGzъO Korn Shell Bourne Shell RO¡Aъo XOG b DB2 for AIX AWG DB2_DJ_COMM='libinformix.a' export DB2_DJ_COMM b DB2 for Solaris Operating Environment AWJ DB2_DJ_COMM='libinformix.so' export DB2_DJ_COMM b DB2 for HP-UX AWJ DB2_DJ_COMM='libinformix.sl' export DB2_DJ_COMM Twѩ (=) ԖSC pGzъO C Shell RO¡AъUCO]wʚG setenv DB2_DJ_COMM 'libinformix.a' (Aъ DB2 for AIX A) setenv DB2_DJ_COMM 'libinformix.so' (Aъ DB2 for Solaris @~ʪA) setenv DB2_DJ_COMM 'libinformix.sl' (Aъ DB2 for HP--UX A) DB2 SQL ReferenceAo~hΫwW DB2_DJ_COMM ʚ㬀 ۛTC BJ 7GыA ъ CREATE SERVER zˮwqzns۫C@ Informix A CzykpUJ CREATE SERVER server_name TYPE server_type VERSION server_version WRAPPER wrapper_name OPTIONS (NODE 'node_name', DBNAME 'database_name') G server_name Nݜzw Informix ۫wAWCo˪WѝO@ AӃPpX۫wwqѪ server_name PWCserver_name ӃPpX۫w񬀬ݫPWC TYPE server_type |wzn[csv۫C : Y Informix ~hAh server_type ѝO informixC VERSION server_version Nݜzns Informix ۫wAуC Informix у 5B7B8 9C WRAPPER wrapper_name Nݜzb CREATE WRAPPER z񽳮wWC NODE 'node_name' N server_name ʪb`IWC node_name ѝwq Informix sqlhosts ]Х\BJ 4^CM node_name ww CREATE SERVER SQL z񬀓AѪO Informix ۫ʃ CjpgCХ\ DB2 SQL ReferenceAHoL ȝ˩ۛTC DBNAME 'database_name' Nݜzns Informix ۫wWC UO CREATE SERVER zdJ CREATE SERVER asia TYPE informix VERSION 9 WRAPPER informix OPTIONS (NODE 'abc', DBNAME 'sales') FOLD_ID FOLD_PW A|vT~hbÛeъ ID MqX Informix eAO_NѪӗjgpgC FOLD_ID P FOLD_PW A CREATE SERVER zdʪpUG CREATE SERVER asia TYPE informix VERSION 9 WRAPPER informix OPTIONS (NODE 'abc', DBNAME 'sales', FOLD_ID 'U', FOLD_PW 'U') BJ 8JыъM pG DB2 pXAWъ ID qXP Informix ۫W ъ ID qXAъ CREATE USER MAPPING zANуъ ID Mwq Informix ۫ъ ID qXFʪpG CREATE USER MAPPING FOR local_userid SERVER server_name OPTIONS (REMOTE_AUTHID 'remode_userid', REMOTE_PASSWORD 'remote_password') G local_userid NݜznMwq Informix ۫Wъ ID уъ IDC SERVER server_name Nݮwq CREATE SERVER z Informix ۫WC REMOTE_AUTHID 'remote_userid' Nݪb Informix ۫wAWznM local_userid ъ IDCnjpgADzN CREATE SERVER z FOLD_ID A]w 'U' 'L'C REMOTE_PASSWORD 'remote_password' N݃P remote_userid pqXCnjpgADzN CREATE SERVER z FOLD_PW A]w 'U' 'L'C UO CREATE USER MAPPING zdJ CREATE USER MAPPING FOR robert SERVER asia OPTIONS (REMOTE_AUTHID 'bob', REMOTE_PASSWORD 'day2night') ziHъ DB2 SOs USERAHKNoX CREATE USER MAPPING z ъv ID M REMOTE_AUTHID ъʽw۫v IDC UO CREATE USER MAPPING zdAt USER SOsJ CREATE USER MAPPING FOR USER SERVER asia OPTIONS (REMOTE_AUTHID 'bob', REMOTE_PASSWORD 'day2night') Х\ DB2 SQL ReferenceAHoLȝ˩ۛTC BJ 9JыݫB݃P Informix PqrW wz Informix ۫WC@ˬݫBݮ Informix PqrAw WCWiH 128 ˪rCݜzd Informix ۫AN| ъoÅWCDB2 |NABσPݫWӗjgADzH̩ (") NѪACUCdʚь CREATE NICKNAME zG CREATE NICKNAME nickname FOR server_name."remote_schema_name"."remote_table_name" G nickname Nݛ@WAъ˖кO Informix ݫBݮPqrC server_name."remote_schema_name"."remote_table_name" N݃ѾкOrTːѸG * server_name Nݜzb CREATE SERVER z񽳮w Informix ۫wAWC * remote_schema_name NݬݫBݮPqrʑϪW C * remote_table_name NݜznsݫBݮPqrW C UO CREATE NICKNAME zdJ CREATE NICKNAME salesjapan FOR asia."salesdata"."japan" wznыWC@ˬݫA𡽢㪇BJCݜzыWA DB2 Nъsu˼d۫Cd|s۫AC Y suLkB@Az|@˓~TC Х\ DB2 SQL ReferenceAHo CREATE NICKNAME zȝ˩ۛTC @مWʩ۫㖎Mȝ˩ۛTAХ\ DB2 Administration GuideC III g ̝z Administration Guide Update Available The Administration Guide was updated as part of FixPak 4. The latest PDF is available for download online at http://www.ibm.com/software/data/db2/udb/winos2unix/support. The information in these notes is in addition to the updated reference. All updated documentation is also available on CD. This CD can be ordered through DB2 service using the PTF number U478862. Information on contacting DB2 Service is available at http://www.ibm.com/cgi-bin/db2www/data/db2/udb/winos2unix/support/help.d2w/report . Administration Guide: Planning (Lլ) Chapter 8. Physical Database Design Table Space Design Considerations Optimizing Table Space Performance when Data is Place on Raid DB2_PARALLEL_IO DB2_PARALLEL_IO also affects table spaces with more than one container defined. If you do not set the registry variable, the I/O parallelism is equal to the number of containers in the table space. If you set the registry variable, the I/O parallelism is equal to the result of prefetch size divided by extent size. You might want to set the registry variable if the individual containers in the table space are striped across multiple physical disks. For example, a table space has two containers and the prefetch size is four times the extent size. If the registry variable is not set, a prefetch request for this table space will be broken into two requests (each request will be for two extents). Provided that the prefetchers are available to do work, two prefetchers can be working on these requests in parallel. In the case where the registry variable is set, a prefetch request for this table space will be broken into four requests (one extent per request) with a possibility of four prefetchers servicing the requests in parallel. In this example, if each of the two containers had a single disk dedicated to it, setting the registry variable for this table space might result in contention on those disks since two prefetchers will be accessing each of the two disks at once. However, if each of the two containers was striped across multiple disks, setting the registry variable would potentially allow access to four different disks at once. Partitioning Keys In the "Nodegroup Design Considerations" subsection of the "Designing Nodegroups" section , the following text from the "Partitioning Keys" sub-subsection stating the points to be considered when defining partitioning keys should be deleted only if DB2_UPDATE_PART_KEY=ON: : If DB2_UPDATE_PART_KEY=OFF, then the restrictions still apply. : In FixPak 3 and later, the default value is OFF. * You cannot update the partitioning key column value for a row in the table. * You can only delete or insert partitioning key column values. Appendix D. Incompatibilities Between Releases Error SQL30081N Not Returned When Lost Connection Is Detected Applications that detect a lost connection to the database server by checking for error SQL30081N will no longer detect lost connections upon migration to DB2 Universal Database Version 6 or above. Export Utility Requires FixPak 7 or Later to Properly Handle Identity Attributes In order for the export utility to support all the identity attributes (for example, minvalue, maxvalue, cycle, order, remarks), you must run both your client and server at a minimum level of FixPak 7. If either the client or server is not at at least this level, the export utility will still function, but will be unable to interpret the attributes. Appendix E. National Language Support (NLS) Country/Region Code and Code Page Support In the table of Supported Languages and Code Sets, code page 5488 is also known as GB 18030, and code page 1394 is also known as ShiftJIS X0213. Connection of a UTF-8 (code page 1208) client to a non-Unicode database is not supported. Import/Export/Load Considerations -- Restrictions for Code Pages 1394 and 5488 Data in code pages 1394 (ShiftJIS X0213) and 5488 (GB 18030) can be moved into a Unicode database using the load or import utilities. The export utility can be used to move data from a Unicode database to a data file in code pages 1394 and 5488. Only connections between a Unicode client and a Unicode server are supported, so you need to use either a Unicode client or set the DB2 registry variable DB2CODEPAGE to 1208 prior to using the load, import, or export utilities. Conversion from code page 1394 or 5488 to Unicode may result in expansion. For example, a 2-byte character may be stored as two 16-bit Unicode characters in the GRAPHIC columns. You need to ensure the target columns in the Unicode database are wide enough to contain any expanded Unicode byte. Datetime Values String Representations of Datetime Values Values whose data types are DATE, TIME, or TIMESTAMP are represented in an internal form that is transparent to the SQL user. Dates, times, and time stamps can also, however, be represented by strings, and these representations directly concern the SQL user because there are no constants or variables whose data types are DATE, TIME, or TIMESTAMP. Thus, to be retrieved, a datetime value must be assigned to a string variable. The string representation is normally the default format of datetime values associated with the country/region code of the client, unless overridden by specification of the DATETIME format option when the program is precompiled or bound to the database. When a valid string representation of a datetime value is used in an operation with an internal datetime value, the string representation is converted to the internal form of the date, time, or time stamp before the operation is performed. Valid string representations of datetime values are defined in the following sections. : Graphic string representations of datetime values are supported only in Unicode databases. Date Strings A string representation of a date is a string that starts with a digit and has a length of at least 8 characters. Trailing blanks may be included; leading zeros may be omitted from the month part and the day part of the date. The table "Formats for String Representations of Dates" remains unchanged. Time Strings A string representation of a time is a string that starts with a digit and has a length of at least 4 characters. Trailing blanks may be included; a leading zero may be omitted from the hour part of the time, and seconds may be omitted entirely. If you choose to omit seconds, an implicit specification of 0 seconds is assumed. Thus, 13:30 is equivalent to 13:30:00. The table "Formats for String Representations of Times" remains unchanged. Time Stamp Strings A string representation of a time stamp is a string that starts with a digit and has a length of at least 16 characters. The complete string representation of a time stamp has the form yyyy-mm-dd-hh.mm.ss.nnnnnn. Trailing blanks may be included; leading zeros may be omitted from the month, day, or hour part of the time stamp, and microseconds may be truncated or omitted entirely. If you choose to omit any digit of the microseconds part, an implicit specification of 0 is assumed. Thus, 1991-3-2-8.30.00 is equivalent to 1991-03-02-08.30.00.000000. Character Set Considerations Date and time stamp strings must contain only digits and delimiter symbols. Date and Time Formats The string representation of date and time formats is the default format of datetime values associated with the country/region code of the application. This default format can be overridden by specifying the DATETIME format option when the program is precompiled or bound to the database. Administration Guide: Implementation (Lլ) New Method for Specifying DMS containers on Windows 2000 and Later Systems DB2 now uses a new method to specify DMS raw table space containers on Windows 2000 and later systems. Each basic disk partition or dynamic volume is assigned a globally unique identifier (GUID) at creation time. This GUID can be used as a device identifier when specifying the containers in a tablespace definition. Because the GUIDs are unique across the system, a multi-node configuration has unique GUID for each node, even if the disk partition definitions are the same. A tool called db2listvolumes.exe has been provided to help display the GUIDs for all the disk volumes defined on a Windows system. The tool creates two files in the current directory that you run it. One file, volumes.xml, contains information about each disk volume. It is designed for easy viewing in any XML-enabled browser. The other file, tablespace.ddl, contains the required syntax for specifying the table space containers. Before you use tablespace.ddl, you must update it to include the remaining information needed for a table space definition. The db2listvolumes tool does not require any command-line arguments. Example for Extending Control Center The example shown in the Extending the Control Center appendix is not correct and will not work. Use the following information to work with the Java example instead: The sample program PluginEx.java is located in the samples/java subdirectory. PluginEx.java is installed with the DB2 Application Development client. To compile PluginEx.java, the following must be included in your classpath: * On Windows platforms use: * DRIVE: \sqllib\java\swingall.jar * DRIVE: \sqllib\cc\com.jar * DRIVE: \sqllib\cc where DRIVE represents the drive on which DB2 is installed. * On UNIX platforms use: * /u/db2inst1/sqllib/java/swingall.jar * /u/db2inst1/sqllib/cc where /u/db2inst1 represents the directory in which DB2 is installed. Create the db2plug.zip to include all the classes generated from compiling PluginEx.java. The file should not be compressed. For example, issue the following: zip -r0 db2plug.zip PluginEx*.class This command places all the class files into the db2plug.zip file and preserves the relative path information. Follow the instructions in the PluginEx.java file to compile and run the example. The CCObject interface includes more static constants than are listed in the Extending the Control Center appendix of the Administration Guide. Below are the Java interfaces for extending the Control Center (CCExtension, CCObject, CCM enuAction, CCToolBarAction). These interfaces are listed here for reference only. CCExtension: // Licensed Materials -- Property of IBM // // (c) Copyright International Business Machines Corporation, 1999. // All Rights Reserved. // // US Government Users Restricted Rights - // Use, duplication or disclosure restricted by // GSA ADP Schedule Contract with IBM Corp. // package com.ibm.db2.tools.cc.navigator; /** * The CCExtension interface allows users to extend the Control Center user * interface by adding new toolbar buttons, new menu items and * remove some predefined set of existing menu actions. * * To do so, create a java file which imports the * com.ibm.db2.tools.cc.navigator package and implements this interface. * The new file provides the implementation of the getObjects() and * getToolbarActions() function. * * The getObjects() function returns an array of CCObjects which defines * the existing * objects which the user would like to add new menu actions or remove * the alter or configure menu actions. * * The getToolbarActions() function returns an array of CCToolbarActions * which is added to the Control Center main toolbar. * * A single CCExtension subclass file or multiple CCExtension subclass * files can be used to define the Control Center extensions. In order * for the Control Center to make use of these extensions, use the * following setup procedures: * (1) Create a "db2plug.zip" file which contains all the CCExtension * subclass files. The files should not be compressed. For example, * if the CCExtension files are in the plugin package and they are * located in the plugin directory, issue * zip -r0 db2plug.zip plugin\*.class * This command will put all the plugin package class files into the * db2plug.zip file and preserve their relative path information. * (2) To run WEBCC as an applet, put the db2plug.zip file in where the * tag points to in the WEBCC html file. * To run the Control Center as an application, put * the db2plug.zip in a directory pointed to by the CLASSPATH * envirnoment variable and where the Control Center is run. * * For browsers that support multiple archives, just add "db2plug.zip" * to the archive list of the WEBCC html page. Otherwise, all the * CCExtension, CCObject, CCToolbarAction, CCMenuAction subclass files * will have to be in their relative path depending on which package * they belong to. */ public interface CCExtension { /** * Get an array of CCObject subclass objects which define * a list of objects to be overrided in the * Control Center * @return CCObject[] CCObject subclass objects array */ public CCObject[] getObjects(); /** * Get an array of CCToolbarAction subclass objects which represent * a list of buttons to be added to the Control Center * main toolbar. * @return CCToolbarAction[] CCToolbarAction subclass objects array */ public CCToolbarAction[] getToolbarActions(); } CCObject CCObject: // // Licensed Materials -- Property of IBM // // (c) Copyright International Business Machines Corporation, 1999. // All Rights Reserved. // // US Government Users Restricted Rights - // Use, duplication or disclosure restricted by // GSA ADP Schedule Contract with IBM Corp. // package com.ibm.db2.tools.cc.navigator; /** * The CCObject interface allows users to define a new object to be * inserted into the Control Center tree or changing the behavior of the * menu actions of an existing object. */ public interface CCObject { /** * The following static constants defines a list of object type * available to be added to the Control Center tree. */ public static final int UDB_SYSTEMS_FOLDER = 0; public static final int UDB_SYSTEM = 1; public static final int UDB_INSTANCES_FOLDER = 2; public static final int UDB_INSTANCE = 3; public static final int UDB_DATABASES_FOLDER = 4; public static final int UDB_DATABASE = 5; public static final int UDB_TABLES_FOLDER = 6; public static final int UDB_TABLE = 7; public static final int UDB_TABLESPACES_FOLDER = 8; public static final int UDB_TABLESPACE = 9; public static final int UDB_VIEWS_FOLDER = 10; public static final int UDB_VIEW = 11; public static final int UDB_ALIASES_FOLDER = 12; public static final int UDB_ALIAS = 13; public static final int UDB_TRIGGERS_FOLDER = 14; public static final int UDB_TRIGGER = 15; public static final int UDB_SCHEMAS_FOLDER = 16; public static final int UDB_SCHEMA = 17; public static final int UDB_INDEXES_FOLDER = 18; public static final int UDB_INDEX = 19; public static final int UDB_CONNECTIONS_FOLDER = 20; public static final int UDB_CONNECTION = 21; public static final int UDB_REPLICATION_SOURCES_FOLDER = 22; public static final int UDB_REPLICATION_SOURCE = 23; public static final int UDB_REPLICATION_SUBSCRIPTIONS_FOLDER = 24; public static final int UDB_REPLICATION_SUBSCRIPTION = 25; public static final int UDB_BUFFERPOOLS_FOLDER = 26; public static final int UDB_BUFFERPOOL = 27; public static final int UDB_APPLICATION_OBJECTS_FOLDER = 28; public static final int UDB_USER_DEFINED_DISTINCT_DATATYPES_FOLDER = 29; public static final int UDB_USER_DEFINED_DISTINCT_DATATYPE = 30; public static final int UDB_USER_DEFINED_DISTINCT_FUNCTIONS_FOLDER = 31; public static final int UDB_USER_DEFINED_DISTINCT_FUNCTION = 32; public static final int UDB_PACKAGES_FOLDER = 33; public static final int UDB_PACKAGE = 34; public static final int UDB_STORE_PROCEDURES_FOLDER = 35; public static final int UDB_STORE_PROCEDURE = 36; public static final int UDB_USER_AND_GROUP_OBJECTS_FOLDER = 37; public static final int UDB_DB_USERS_FOLDER = 38; public static final int UDB_DB_USER = 39; public static final int UDB_DB_GROUPS_FOLDER = 40; public static final int UDB_DB_GROUP = 41; public static final int UDB_DRDA_TABLES_FOLDER = 42; public static final int UDB_DRDA_TABLE = 43; public static final int UDB_NODEGROUPS_FOLDER = 44; public static final int UDB_NODEGROUP = 45; public static final int S390_SUBSYSTEMS_FOLDER = 46; public static final int S390_SUBSYSTEM = 47; public static final int S390_BUFFERPOOLS_FOLDER = 48; public static final int S390_BUFFERPOOL = 49; public static final int S390_VIEWS_FOLDER = 50; public static final int S390_VIEW = 51; public static final int S390_DATABASES_FOLDER = 52; public static final int S390_DATABASE = 53; public static final int S390_TABLESPACES_FOLDER = 54; public static final int S390_TABLESPACE = 55; public static final int S390_TABLES_FOLDER = 56; public static final int S390_TABLE = 57; public static final int S390_INDEXS_FOLDER = 58; public static final int S390_INDEX = 59; public static final int S390_STORAGE_GROUPS_FOLDER = 60; public static final int S390_STORAGE_GROUP = 61; public static final int S390_ALIASES_FOLDER = 62; public static final int S390_ALIAS = 63; public static final int S390_SYNONYMS_FOLDER = 64; public static final int S390_SYNONYM = 65; public static final int S390_APPLICATION_OBJECTS_FOLDER = 66; public static final int S390_COLLECTIONS_FOLDER = 67; public static final int S390_COLLECTION = 68; public static final int S390_PACKAGES_FOLDER = 69; public static final int S390_PACKAGE = 70; public static final int S390_PLANS_FOLDER = 71; public static final int S390_PLAN = 72; public static final int S390_PROCEDURES_FOLDER = 73; public static final int S390_PROCEDURE = 74; public static final int S390_DB_USERS_FOLDER = 75; public static final int S390_DB_USER = 76; public static final int S390_LOCATIONS_FOLDER = 77; public static final int S390_LOCATION = 78; public static final int S390_DISTINCT_TYPES_FOLDER = 79; public static final int S390_DISTINCT_TYPE = 80; public static final int S390_USER_DEFINED_FUNCTIONS_FOLDER = 81; public static final int S390_USER_DEFINED_FUNCTION = 82; public static final int S390_TRIGGERS_FOLDER = 83; public static final int S390_TRIGGER = 84; public static final int S390_SCHEMAS_FOLDER = 85; public static final int S390_SCHEMA = 86; public static final int S390_CATALOG_TABLES_FOLDER = 87; public static final int S390_CATALOG_TABLE = 88; public static final int DCS_GATEWAY_CONNECTIONS_FOLDER = 89; public static final int DCS_GATEWAY_CONNECTION = 90; public static final int S390_UTILITY_OBJECTS_FOLDER = 91; public static final int S390_DATASET_TEMPLATES_FOLDER = 92; public static final int S390_DATASET_TEMPLATE = 93; public static final int S390_UTILITY_LISTS_FOLDER = 94; public static final int S390_UTILITY_LIST = 95; public static final int S390_UTILITY_PROCEDURES_FOLDER = 96; public static final int S390_UTILITY_PROCEDURE = 97; /** * Total number of object types */ public static final int NUM_OBJECT_TYPES = 98; /** * Get the name of these object * * The function returns the name of this object. This name * can be of three types: * (1) Fully qualified name * Syntax: xxxxx-yyyyy-zzzzz * where xxxxx-yyyyy is the fully quality name of the parent * object and zzzzz is the name of the new object. * Note: Parent and child object name is separated by '-' character. * If a schema name is required to identify object, the fully * qualified name is represented by xxxxx-yyyyy-wwwww.zzzzz * where wwwww is the schema name. * Only the behavior of the object that match this fully * quality name will be affected. * (2) Parent fully qualified name * Syntax: xxxxx-yyyyy * where xxxxx-yyyyy is the fully qualified name of the * parent object. * When the object type is folder (ie. DATABASES_FOLDER), the * getName() should only return the fully qualified name of the * folder's parent. * Only the behavior of the object that match this name * and the specific type return by the getType() function will be * affected. * (3) null * Syntax: null * If null is return, the CCMenuActions returns by the * getMenuActions() call will be applied to all objects of type * returns by the getType() call. * @return String object name */ public String getName(); /** * Get the type of this object * @return int return one of the static type constants defined in this * interface */ public int getType(); /** * Get the CCMenu Action array which defines the list of menu actions * to be created for object * return CCMenuAction[] CCMenuAction array */ public CCMenuAction[] getMenuActions(); /** * Check if this object is editable. If not, the Alter related menu * items will be removed from the object's popup menu * return boolean If false, the Alter menu item will be remove from the * object's popup menu. * Return true if you do not wish to modify current Alter menu item * behaviour. */ public boolean isEditable(); /** * Check if this object is configurable. If not, the configuration * related menu items will be removed from the object's popup menu * return boolean If false, the Configuration related menu item will be * removed from the object's popup menu. * Return true if you do not wish to modify current Configuration * behaviour. */ public boolean isConfigurable(); } CCMenuAction: // // Licensed Materials -- Property of IBM // // (c) Copyright International Business Machines Corporation, 1999. // All Rights Reserved. // // US Government Users Restricted Rights - // Use, duplication or disclosure restricted by // GSA ADP Schedule Contract with IBM Corp. // package com.ibm.db2.tools.cc.navigator; import java.awt.event.*; import javax.swing.*; /** * The CCMenuAction class allows users to define a new menu item to be added * to a Control Center object. The new menu item will be added at the end of * an object's popup menu. * * Note: If the object has a Control Center Refresh and/or * Filter menu item, the new menu item will be inserted before the Refresh * and Filter menu. The Control Center Refresh and Filter menu items are * always at the end of the popup menu. */ public interface CCMenuAction { /** * Get the name of this action * @return String Name text on the menu item */ public String getMenuText(); /** * Invoked when an action occurs. * @param e Action event */ public void actionPerformed(ActionEvent e); } CCToolBarAction // Licensed Materials -- Property of IBM // // (c) Copyright International Business Machines Corporation, 1999. // All Rights Reserved. // // US Government Users Restricted Rights - // Use, duplication or disclosure restricted by // GSA ADP Schedule Contract with IBM Corp. // package com.ibm.db2.tools.cc.navigator; import java.awt.event.*; import javax.swing.*; /** * The CCToolbarAction interface class allows users to define a new action * to be added to the Control Center toolbar. */ public interface CCToolbarAction { /** * Get the name of this action * @return String Name text on the menu item, or toolbar button hover help */ public String getHoverHelpText(); /** * Get the icon for the toolbar button * Any toolbar CCAction should override this function and return * a valid ImageIcon object. Otherwise, the button will have no icon. * @return ImageIcon Icon to be displayed */ public ImageIcon getIcon(); /** * Invoked when an action occurs. * @param e Action event */ public void actionPerformed(ActionEvent e); } Administration Guide: Performance (Lլ) System Temporary Table Schemas The schema for a system temporary table is determined by the application and authorization ID that create it. When this data is available, the schema in which the table is created is . Under some circumstances, the tables are created using only one of these IDs to determine the schema, and sometimes, none. This can result in a tables such as AUTHID.TEMPTABLENAME, or .TEMPTABLENAME. You can view the schema information for these tables by using the GET SNAPSHOT command. For information on this command, please refer to the Command Reference Chapter 8. Operational Performance Block- Based Buffer Pool This feature is only supported on the Sun Solaris Operating Environment. Due to I/O overhead, prefetching pages from disk is an expensive operation. DB2's prefetching significantly improves throughput when processing can be overlapped with I/O. Most platforms provide high performance primitives to read contiguous pages from disk into discontiguous portions of memory. These primitives are usually called " scattered read" or "vectored I/O". On some platforms, the performance of these primitives cannot compete with doing I/O in large block sizes. By default, the buffer pools are page-based. That is, contiguous pages on disk are prefetched into discontiguous pages in memory. Prefetching performance can be further enhanced on these platforms if pages can be read from disk into contiguous pages in a buffer pool. A registry variable, DB2_BLOCK_BASED_BP, allows you to create a section in the buffer pool that holds sets of contiguous pages. These sets of contiguous pages are referred to as "blocks". By setting this registry variable, a sequential prefetch will read the pages from disk directly into these blocks instead of reading each page individually. This will improve I/O performance. For more information on this registry variable, see the 'Registry and Environment Variables' section of the Administration Guide. Multiple table spaces of different extent sizes can be bound to a buffer pool of the same block size. There is a close relationship between extent sizes and block sizes even though they deal with separate concepts. An extent is the granularity at which table spaces are striped across multiple containers. A block is the only granularity at which I/O servers doing sequential prefetch requests will consider doing block-based I/O. Individual sequential prefetch requests use extent-size pages. When such a prefetch request is received, the I/O server determines the cost and benefit of doing each request as a block-based I/O (if there is a block-based area in the buffer pool) instead of the page-based I/O using the scattered read method. The benefit of doing any I/O as block-based I/O is the performance benefit from reading from contiguous disk into contiguous memory. The cost is the amount of wasted buffer pool memory that can result from using this method. Buffer pool memory can be wasted for two reasons when doing block-based I/O: * The number of pages in the prefetch request contains fewer pages than the number of pages in a block. That is, the extent size is smaller than the block size. * Some of the pages requested as part of the prefetch request are already in the page area of the buffer pool. : Each block in the block-based area of a buffer pool cannot be subdivided. The pages within the block must all be contiguous. As a result, there is a possibility of wasted space. The I/O server allows for some wasted pages within each block in order to gain the benefit of doing block-based I/O. However, when too much of a block is wasted, the I/O server will revert to using page-based prefetching into the page area of the buffer pool. As a result, some of the I/O done during prefetching will not be block-based. This is not an optimal condition. For optimal performance, you should have table spaces of the same extent size bound to a buffer pool of the same block size. Good performance can still be achieved if the extent size of some table spaces is greater than the block size of the buffer pool they are bound to. It is not advisable to bind table spaces to a buffer pool when the extent size is less than the block size. : The block area of a buffer pool is only used for sequential prefetching. If there is little or no sequential prefetching involved on your system, then the block area will be a wasted portion of the buffer pool. Both AWE and block-based support cannot be setup for a buffer pool at the same time. If both the DB2_AWE and DB2_BLOCK_BASED_BP registry variables refer to the same buffer pool, precedence will be given to AWE. Block-based support will be disabled in this case and will only be re-enabled once AWE is disabled. A buffer pool that is using extended storage does not support block-based I/O. Block-based Buffer Pool Examples Before working with any of the examples, you will need to know the identifiers for the buffer pools on your system. The ID of the buffer pool can be seen in the BUFFERPOOLID column of the SYSCAT.BUFFERPOOLS system catalog view. Scenario 1 You have a buffer pool with an ID of 4 that has 1000 pages. You wish to create a block area which is made up of 700 pages where each block contains 32 pages. You must run the following: db2set DB2_BLOCK_BASED_BP=4,700,32 When the database is started, the buffer pool with ID 4 is created with a block area of 672 pages and a page area of 328 pages. In this example, 32 cannot be evenly divided into 700. This means that the block area size specified had to be reduced to the nearest block size boundary using the following formula: ((block area size)) FLOOR(-----------------) X block size ( (block size) ) ( 700 ) = FLOOR(-----------------) X 32 ( 32 ) = 21 x 32 = 672 Scenario 2 You have a buffer pool with an ID of 11 that has 3000 pages. You wish to create a block area which is made up of 2700 pages. You must run the following: db2set DB2_BLOCK_BASED_BP=11,2700 When the database is started, the buffer pool with ID 11 is created with a block area of 2688 pages and a page area of 312 pages. With no value explicitly given for the block size, the default value of 32 is used. In this example, 32 cannot be evenly divided into 2700. This means that the block area size specified had to be reduced to the nearest block size boundary using the following formula: ((block area size)) FLOOR(-----------------) X block size ( (block size) ) ( 2700 ) = FLOOR(-----------------) X 32 ( 32 ) = 84 x 32 = 2688 Chapter 10. Scaling Your Configuration Through Adding Processors Problems When Adding Nodes to a Partitioned Database When adding nodes to a partitioned database that has one or more system temporary table spaces with a page size that is different from the default page size (4 KB), you may encounter the error message: " SQL6073N Add Node operation failed" and an SQLCODE. This occurs because only the IBMDEFAULTBP buffer pool exists with a page size of 4 KB when the node is created. For example, you can use the db2start command to add a node to the current partitioned database: DB2START NODENUM 2 ADDNODE HOSTNAME newhost PORT 2 If the partitioned database has system temporary table spaces with the default page size, the following message is returned: SQL6075W The Start Database Manager operation successfully added the node. The node is not active until all nodes are stopped and started again. However, if the partitioned database has system temporary table spaces that are not the default page size, the returned message is: SQL6073N Add Node operation failed. SQLCODE = "<-902>" In a similar example, you can use the ADD NODE command after manually updating the db2nodes.cfg file with the new node description. After editing the file and running the ADD NODE command with a partitioned database that has system temporary table spaces with the default page size, the following message is returned: DB20000I The ADD NODE command completed successfully. However, if the partitioned database has system temporary table spaces that are not the default page size, the returned message is: SQL6073N Add Node operation failed. SQLCODE = "<-902>" One way to prevent the problems outlined above is to run: DB2SET DB2_HIDDENBP=16 before issuing db2start or the ADD NODE command. This registry variable enables DB2 to allocate hidden buffer pools of 16 pages each using a page size different from the default. This enables the ADD NODE operation to complete successfully. Another way to prevent these problems is to specify the WITHOUT TABLESPACES clause on the ADD NODE or the db2start command. After doing this, you will have to create the buffer pools using the CREATE BUFFERPOOL statement, and associate the system temporary table spaces to the buffer pool using the ALTER TABLESPACE statement. When adding nodes to an existing nodegroup that has one or more table spaces with a page size that is different from the default page size (4 KB), you may encounter the error message: "SQL0647N Bufferpool "" is currently not active.". This occurs because the non-default page size buffer pools created on the new node have not been activated for the table spaces. For example, you can use the ALTER NODEGROUP statement to add a node to a nodegroup: DB2START CONNECT TO mpp1 ALTER NODEGROUP ng1 ADD NODE (2) If the nodegroup has table spaces with the default page size, the following message is returned: SQL1759W Redistribute nodegroup is required to change data positioning for objects in nodegroup "" to include some added nodes or exclude some drop nodes. However, if the nodegroup has table spaces that are not the default page size, the returned message is: SQL0647N Bufferpool "" is currently not active. One way to prevent this problem is to create buffer pools for each page size and then to reconnect to the database before issuing the ALTER NODEGROUP statement: DB2START CONNECT TO mpp1 CREATE BUFFERPOOL bp1 SIZE 1000 PAGESIZE 8192 CONNECT RESET CONNECT TO mpp1 ALTER NODEGROUP ng1 ADD NODE (2) A second way to prevent the problem is to run: DB2SET DB2_HIDDENBP=16 before issuing the db2start command, and the CONNECT and ALTER NODEGROUP statements. Another problem can occur when the ALTER TABLESPACE statement is used to add a table space to a node. For example: DB2START CONNECT TO mpp1 ALTER NODEGROUP ng1 ADD NODE (2) WITHOUT TABLESPACES ALTER TABLESPACE ts1 ADD ('ts1') ON NODE (2) This series of commands and statements generates the error message SQL0647N (not the expected message SQL1759W). To complete this change correctly, you should reconnect to the database after the ALTER NODEGROUP... WITHOUT TABLESPACES statement. DB2START CONNECT TO mpp1 ALTER NODEGROUP ng1 ADD NODE (2) WITHOUT TABLESPACES CONNECT RESET CONNECT TO mpp1 ALTER TABLESPACE ts1 ADD ('ts1') ON NODE (2) Another way to prevent the problem is to run: DB2SET DB2_HIDDENBP=16 before issuing the db2start command, and the CONNECT, ALTER NODEGROUP, and ALTER TABLESPACE statements. Chapter 13. Configuring DB2 Log Archive Completion Now Checked More Frequently To improve recovery time by avoiding unnecessary log archive requests, the database server now checks for log archive completion both when a new log file is created and when the first active log changes. Correction to Collating Information (collate_info) Section The documentation for collating information incorrectly states that the collate_info parameter can only be displayed by using the GET DATABASE CONFIGURATION API. This is incorrect. You cannot use the GET DATABASE CONFIGURATION API to display the collate_info parameter. Instead, you must use the db2CfgGetAPI. DB2 Registry and Environment Variables Corrections to Performance Variables 5. Performance Variables +---------------------------+-------------+---------------------------+ | Variable Name | Operating | Values | | | System | | +---------------------------------------------------------------------+ | Description | +---------------------------+-------------+---------------------------+ | DB2_BINSORT | All | Default=YES | | | | Values: YES or NO | +---------------------------------------------------------------------+ | Enables a new sort algorithm that reduces the CPU time and elapsed | | time of sorts. This new algorithm extends the extremely efficient | | integer sorting technique of DB2 UDB to all sort datatypes such as | | BIGINT, CHAR, VARCHAR, FLOAT, and DECIMAL, as well as combinations | | of these datatypes. To enable this new algorithm, use the following | | command: | | db2set DB2_BINSORT = yes | +---------------------------+-------------+---------------------------+ | DB2_BLOCK_BASED_BP | Solaris | Default=None | | | Operating | Values: dependant on | | | Environment | parameters | +---------------------------------------------------------------------+ | Specifies the values needed to create a block area within a buffer | | pool. The ID of the buffer pool is needed and can be seen in the | | BUFFERPOOLID column of the SYSCAT.BUFFERPOOLS system catalog view. | | The number of pages to be allocated in the buffer pool to | | block-based I/O must be given. The number of pages to include in a | | block is optional, with a default value of 32. | | The format for the use of this registry variable is: | | | | DB2_BLOCK_BASED_BP=BUFFER POOL ID,BLOCK AREA SIZE,[BLOCK SIZE];... | | | | | | Multiple buffer pools can be defined as block-based using the same | | variable with a semi-colon separating the entries. | | | | The value for BLOCK SIZE can range from 2 to 256. If no BLOCK SIZE | | is given, the default used is 32. | | | | If the BLOCK AREA SIZE specified is larger than 98% of the total | | buffer pool size, then the buffer pool will not be made | | block-based. It is a good idea to always have some portion of the | | buffer pool in the page-based area of the buffer pool because there | | is a possibility of individual pages being required even if the | | majority of the I/O on the system is sequential prefetching. If the | | value specified for BLOCK AREA SIZE is not a multiple of BLOCK | | SIZE, it is reduced to the nearest block size boundary. For more | | information on block-based I/O, see "Block- Based Buffer Pool". | +---------------------------+-------------+---------------------------+ | DB2_NO_FORK_CHECK | UNIX | Default=OFF | | | | Values: ON or OFF | +---------------------------------------------------------------------+ | When this variable is "ON", the client process will not protect | | itself against an application making a copy of the process to be | | run (called forking). When forking occurs, the results are | | unpredictable. The results could range from no effect, to some bad | | results, to some error code being returned, to a trap in the | | application. If you are certain that your application does not fork | | and you want better performance, you should change the value of | | this variable to "ON". | +---------------------------+-------------+---------------------------+ | DB2_MINIMIZE_LIST_PREFETC | All | Default=NO | | H | | Values: YES or NO | +---------------------------------------------------------------------+ | List prefetch is a special table access method that involves | | retrieving the qualifying RIDs from the index, sorting them by page | | number and then prefetching the data pages. | | Sometimes the optimizer does not have accurate information to | | determine if list prefetch is a good access method. This might | | occur when predicate selectivities contain parameter markers or | | host variables that prevent the optimizer from using catalog | | statistics to determine the selectivity. | | | | This registry variable will prevent the optimizer from | | considering list prefetch in such situations. | +---------------------------+-------------+---------------------------+ | DB2_INLIST_TO_NLJN | All | Default=NO | | | | Values: YES or NO | +---------------------------------------------------------------------+ | In some situations, the SQL compiler can rewrite an IN list | | predicate to a join. For example, the following query: | | SELECT * | | FROM EMPLOYEE | | WHERE DEPTNO IN ('D11', 'D21', 'E21') | | | | | | could be written as: | | SELECT * | | FROM EMPLOYEE, (VALUES 'D11', 'D21', 'E21) AS V(DNO) | | WHERE DEPTNO = V.DNO | | | | | | | | This revision might provide better performance if there is an index | | on DEPTNO. The list of values would be accessed first and joined to | | EMPLOYEE with a nested loop join using the index to apply the join | | predicate. | | | | Sometimes the optimizer does not have accurate information to | | determine the best join method for the rewritten version of the | | query. This can occur if the IN list contains parameter markers or | | host variables which prevent the optimizer from using catalog | | statistics to determine the selectivity. This registry variable | | will cause the optimizer to favor nested loop joins to join the | | list of values, using the table that contributes the IN list as the | | inner table in the join. | +---------------------------------------------------------------------+ New Parameters for Registry Variable DB2BPVARS The registry variable DB2BPVARS supports two new parameters: NUMPREFETCHQUEUES and PREFETCHQUEUESIZE. These parameters are applicable to all platforms and can be used to improve buffer-pool data prefetching. For example, consider sequential prefetching in which the desired PREFETCHSIZE is divided into PREFETCHSIZE/EXTENTSIZE prefetch requests. In this case, requests are placed on prefetch queues from which I/O servers are dispatched to perform asynchronous I/O. By default, DB2 maintains one queue of size max( 100 , 2*NUM_IOSERVERS ) for each database partition. In some environments, performance improves with either more queues, queues of a different size, or both. The number of prefetch queues should be at most one half of the number of I/O servers. When you set these parameters, consider other parameters such as PREFETCHSIZE, EXTENTSIZE, NUM_IOSERVERS, buffer-pool size, and DB2_BLOCK_BASED_BP, as well as workload characteristics such as the number of current users. If you think the default values are too small for your environment, first increase the values only slightly. For example, you might set NUMPREFETCHQUEUES=4 and PREFETCHQUEUESIZE=200. Make changes to these parameters in a controlled manner so that you can monitor and evaluate the effects of the change. 6. Summary of New Parameters +-------------------+------------------------+------------------------+ | Parameter name | Default value | Valid range | +-------------------+------------------------+------------------------+ | NUMPREFETCHQUEUES | 1 | 1 to NUM_IOSERVERS | | | | if set to less than 1, | | | | adjusted to 1 | | | | | | | | if set to greater than | | | | NUM_IOSERVERS, | | | | adjusted to | | | | NUM_IOSERVERS | +-------------------+------------------------+------------------------+ | PREFETCHQUEUESIZE | max(100,2*NUM_IOSERVER | 1 to 32767 | | | S) | if set to less than 1, | | | | adjusted to default | | | | | | | | if set to greater than | | | | 32767, adjusted to | | | | 32767 | +-------------------+------------------------+------------------------+ Corrections and Additions to Miscellaneous Registry Variables The DB2_NEWLOGPATH2 registry variable is available for all operating systems. A new variable, DB2_ROLLFORWARD_NORETRIEVE, has been introduced. The correct information for both variables appears below. 7. Miscellaneous Variables +---------------------------+-------------+---------------------------+ | Variable Name | Operating | Values | | | System | | +---------------------------------------------------------------------+ | Description | +---------------------------+-------------+---------------------------+ | DB2_NEWLOGPATH2 | ALL | Default=NO | | | | Values: YES or NO | +---------------------------------------------------------------------+ | This parameter allows you to specify whether a secondary path | | should be used to implement dual logging. The path used is | | generated by appending a "2" to the current value of the logpath | | database configuration parameter. | +---------------------------+-------------+---------------------------+ | DB2_ROLLFORWARD_NORETRIEV | ALL | Default=(not set) | | E | | Values: YES or NO | +---------------------------------------------------------------------+ | If the database configuration parameter USEREXIT is enabled, log | | files are automatically retrieved from the archive during | | rollforward operations. The DB2_ROLLFORWARD_NORETRIEVE variable | | lets you specify that rollforward operations should not retrieve | | log files from the archive. This variable is disabled by default. | | Set this variable to YES if you do not want rollforward to retrieve | | log files automatically. For example, set the variable to YES in a | | hot-standby setup when want to keep log records created by a | | bad application from corrupting the backup system. | +---------------------------------------------------------------------+ Corrections and Additions to General Registry Variables A new variable, DB2_REDUCED_OPTIMIZATION, has been introduced. 8. General Registry Variable +---------------------------+-------------+---------------------------+ | Variable Name | Operating | Values | | | System | | +---------------------------------------------------------------------+ | Description | +---------------------------+-------------+---------------------------+ | DB2_REDUCED_OPTIMIZATION | ALL | Default=NO | | | | Values: YES, NO, or any | | | | integer | +---------------------------------------------------------------------+ | This registry variable lets you disable some of the optimization | | techniques used at specific optimization levels. If you reduce the | | number of optimization techniques used, you also reduce time and | | resource use during optimization. | | : Although optimization time and resource use might be reduced, | | the risk of producing a less-than-optimal data access plan is | | increased. | | * If set to NO | | The optimizer does not change its optimization techniques. | | * If set to YES | | If the optimization level is 5 (the default) or lower, the | | optimizer disables some optimization techniques that might consume | | significant prepare time and resources but that do not usually | | produce a better access plan. | | If the optimization level is exactly 5, the optimizer scales back | | or disables some additional techniques, which might further reduce | | optimization time and resource use, but also further increase the | | risk of a less-than-optimal access plan. For optimization levels | | lower than 5, some of these techniques might not be in effect in | | any case. If they are, however, they remain in effect. | | * If set to any integer | | The effect is the same as if the value is set to YES, with the | | following additional behavior for dynamically prepared queries | | optimized at level 5: If the total number of joins in any query | | block exceeds the setting, then the optimizer switches to greedy | | join enumeration instead of disabling additional optimization | | techniques as described above for optimization level 5, | | which implies that the query will be optimized at a level similar | | to optimization level 2. | | For information about greedy and dynamic join enumeration, | | see "Search Strategies for Selecting Optimal Join" in | | Administration Guide: Performance (Lլ). | | | | | | Note that the dynamic optimization reduction at optimization level | | 5, as described in "Adjusting the Optimization Class" | | in Administration Guide: Performance, takes precedence over the | | behavior described for optimization level of exactly 5 | | when DB2_REDUCED_OPTIMIZATION is set to YES as well as over the | | behavior described for the integer setting. | +---------------------------------------------------------------------+ Administering Satellites Guide and Reference (Lլ) Setting up Version 7.2 DB2 Personal Edition and DB2 Workgroup Edition as Satellites The sections that follow describe how to set up Windows-based Version 7.2 DB2 Personal Edition and DB2 Workgroup Edition systems so that they can be used as fully functional satellites in a satellite environment. For information about the terms and concepts used in the information that follows, refer to the Administering Satellites Guide and Reference. You can find this book at the following URL: http://www.ibm.com/cgi-bin/db2www/data/db2/udb/winos2unix/support/ v6pubs.d2w/en_main For Technotes that supplement the information in the Administering Satellites Guide and Reference, refer to the following URL: http://www.ibm.com/cgi-bin/db2www/data/db2/udb/winos2unix/support/index.d2w/report Prerequisites To set up either DB2 Personal Edition or DB2 Workgroup Edition as satellites, you require the following: 1. A DB2 control server The DB2 control server is a DB2 Enterprise Edition system that runs on Windows NT or AIX, and has the Control Server component installed. The DB2 Enterprise Edition system that you use must be at Version 6 with FixPak 2 or higher, or Version 7 at any FixPak level. * If you have a Version 6 Enterprise Edition system that you want to use as the DB2 control server, see "Installing FixPak 2 or Higher on a Version 6 Enterprise Edition System". * If you are using Version 7 and do not have the Control Server component installed, install this component, re-install any FixPaks that you have already installed, then create the DB2 control server instance and satellite control database. Refer to the Administering Satellites Guide and Reference for instructions on creating these objects. : If you are installing a Version 7.2 Enterprise Edition system on Windows NT for use as the DB2 control server, and you want to perform a response file installation, see the Technote entitled DB2 Control Server Response File Keywords for information about the keywords to specify in the response file. 2. The DB2 control server instance and the satellite control database The DB2 control server instance is typically called DB2CTLSV, and the satellite control database is called SATCTLDB. The DB2 control server instance and the satellite control database are on the Enterprise Edition system, and, on Windows NT, are automatically created when you install DB2 with the Control Server component. If you install DB2 on AIX, see the Administering Satellites Guide and Reference for information about creating the DB2 control server instance and the satellite control database. 3. The P̝z The P̝z is the set of GUI tools that you use to set up and administer the satellite environment. You access this set of tools from the . For more information about the P̝z and the satellite environment, see the Administering Satellites Guide and Reference, and the online help that is available from the P̝z . If you are running a Version 6 , see "Upgrading a Version 6 and P̝z". If you have not already used the P̝z to set up the satellite environment and to create the object that represents the new satellite in the P̝z, you should do so before installing the satellite. For more information, see the description of how to set up and test a satellite environment in the Administering Satellites Guide and Reference. 4. A Version 7.2 Personal Edition or Workgroup Edition system that you want to use as a satellite. Installation Considerations When you install either DB2 Personal Edition or DB2 Workgroup Edition, you do not have to select any special component to enable either system to synchronize. If you intend to perform a response file installation, see "Performing a Response File Installation" for the keywords that you should specify when installing the Version 7.2 system. If you are performing an interactive installation of your Version 7.2 system, see "Configuring the Version 7.2 System for Synchronization" after you finish installing DB2 for values that you must set at the Version 7.2 system to enable it to synchronize. Performing a Response File Installation If you are performing a response file installation of Version 7.2 DB2 Personal Edition or DB2 Workgroup Edition, you can set the following keywords in the response file. If you decide to not specify one or more of these keywords during the response file installation, see "Configuring the Version 7.2 System for Synchronization" for additional steps that you must perform after installing DB2 to enable the Version 7.2 system to synchronize. You can also use the instructions in this section if you want to change any values that were specified during the response file installation. db2.db2satelliteid Sets the satellite ID on the system. : If you do not specify this keyword, the satellite ID is automatically set to the user ID that was used to install DB2. If you want to use this user ID as the satellite ID, you do not have to specify a value for this keyword. db2.db2satelliteappver Sets the application version on the system. : If you do not specify this keyword, the application version on the satellite is automatically set to V1R0M00. If you want to use this value as the application version, you do not have to specify a value for this keyword. db2.satctldb_username Sets the user name to be used for the system to connect to the satellite control database. db2.satctldb_password Sets the password that the user name passes to the DB2 control server when the user name connects to the satellite control database. After you complete the response file installation, the Version 7.2 system is ready to synchronize. You should issue the db2sync -t command on the satellite to verify that the values specified on the satellite are correct, and that the satellite can connect to the satellite control database. For additional information about performing a response file installation, refer to the Administering Satellites Guide and Reference. : 1. In Version 7, user IDs and passwords are required for the creation of all services on Windows NT and Windows 2000. These user IDs and passwords are specified in the response file by keyword pairs. The first keyword pair found in the response file becomes the default user ID and password for all services, unless you provide an override for a service by specifying the specific keyword pair for that service. In Version 6, the admin.userid and the admin.password keywords could be specified during a response file installation of DB2 Satellite Edition to specify the user ID and password that would be used by the Remote Command Service. For Version 7.2 Personal Edition and Workgroup Edition, if you specify these keywords, they are used for the DB2DAS00 instance on the Version 7.2 system. For a DB2 Version 7.2 system, the Remote Command Service will use the user ID and password that is used by the DB2 instance on the system. If you do not specify values for db2.userid and db2.password, the defaulting rule described above applies. 2. In Version 6, you could create a database when installing DB2 Satellite Edition using a response file installation. You cannot create a database during a response file installation on the Version 7.2 Personal Edition or Workgroup Edition system that you intend to use as a satellite. The following keywords (which are described in the Administering Satellites Guide and Reference), are not supported: * db2.userdb_name * db2.userdb_recoverable * db2.userdb_rep_src Configuring the Version 7.2 System for Synchronization If you install the Version 7.2 system interactively, several values must be set on the DB2 Personal Edition or DB2 Workgroup Edition system after installing DB2 before the system can synchronize. : You can execute an operating system script on the system to set all values at the satellite except for the user ID and password that the satellite uses to connect to the satellite control database (see step 4). 1. Set the satellite ID by using the db2set command. If you install DB2 Personal Edition or DB2 Workgroup Edition interactively, the satellite ID is automatically set to the user ID that was used to install DB2. If you want to use this user ID as the satellite ID, you do not have to perform this step. For information about setting the satellite ID, see the Administering Satellites Guide and Reference. 2. Set the application version on the satellite by using the db2sync -s command. If you install DB2 Personal Edition or DB2 Workgroup Edition interactively, the application version on the satellite is automatically set to V1R0M00. If you want to use this value as the application version, you do not have to perform this step. You can use the db2sync -g command on the satellite to view the current setting of the application version. If you want to change this value, issue the db2sync -s command. You are prompted to provide a new value for the application version. For more information about setting the application version, see the Administering Satellites Guide and Reference. 3. Issue the catalog node and catalog database commands on the satellite to catalog the DB2 control server instance and the satellite control database, SATCTLDB, at the satellite. You can also use the db2sync -t command on the satellite to open the DB2 Synchronizer application in test mode. If the SATCTLDB database is not cataloged at the satellite when you issue the command, the Catalog Control Database window opens. You can either use the DB2 discovery feature that is available from the Catalog Control Database window to catalog the DB2 control server and the SATCTLDB database, or you can type the hostname and server name in this window. You will also be prompted to specify the user ID and password that the satellite will use to connect to the satellite control database, as described in step 4. : After you install Version 7.2 DB2 Personal Edition or DB2 Workgroup Edition interactively, the DB2 Synchronizer does not start automatically in test mode (as was the case for Version 6 DB2 Satellite Edition). 4. Issue the db2sync -t command on the satellite to: * Specify the user ID and the password that the satellite will use to connect to the satellite control database If synchronization credentials are not already stored at the satellite, the Connect to Control Database window opens. You must use this window to specify the user ID and password the satellite will use to connect to the satellite control database. * Verify the values that are set on the satellite are correct * Verify that the satellite can connect to the satellite control database After you complete these configuration tasks, the Version 7.2 system is ready to synchronize. Installing FixPak 2 or Higher on a Version 6 Enterprise Edition System For a Version 6 Enterprise Edition system to be used as a DB2 control server, the system must be at FixPak 2 or higher. The sections that follow describe the tasks that you must perform to upgrade a Version 6 Enterprise Edition system on Windows NT or AIX for use as a DB2 control server. If you are using a Version 6 , also perform the steps in "Upgrading a Version 6 and P̝z" to verify that you have the correct level of the and the P ̝z to administer the satellite environment. Upgrading Version 6 DB2 Enterprise Edition for Use as the DB2 Control Server For a Version 6 DB2 Enterprise Edition system to be used as the DB2 control server, it must be installed with the Control Server component, and DB2 Enterprise Edition should be at the FixPak 2 service level, or higher. Depending on whether the DB2 control server component is installed, and the service level of DB2 Enterprise Edition, you will have to perform one of the following tasks: * Install the DB2 control server component to an existing DB2 Enterprise Edition V6.1 system and install FixPak 2 or higher. Then update the satellite control database (SATCTLDB) on the system. * Upgrade an already installed DB2 control server to the FixPak 2 level or higher. Use the information that follows to identify which of the two preceding tasks you need to perform, and the steps that apply to your situation. The following is a summary of the steps that you will perform. 1. First, assess the current state of your DB2 Enterprise Edition installation. You will determine whether the Control Server component is installed, and the service level of DB2. 2. Second, based on the state information that you obtain, you will determine what needs to be done. 3. Third, you will perform the necessary steps to upgrade DB2 Enterprise Edition. The DB2 control server can only run on DB2 Enterprise Edition for Windows NT and AIX. Continue with the instructions that are appropriate for your platform: * "Upgrading DB2 Enterprise Edition on Windows NT" * "Upgrading DB2 Enterprise Edition on AIX" Upgrading DB2 Enterprise Edition on Windows NT Use the information in the sections that follow to determine the current service level of your Version 6 DB2 Enterprise Edition system, and the steps that you need to perform to update the system to the FixPak 2 service level or higher. You will need to perform the steps of one or more of the following sections: * "Assessing DB2 Enterprise Edition on Windows NT" * "Determining What Needs to Be Done" * "Installing the Control Server Component on Windows NT" * "Installing FixPak 2 or Higher on Windows NT" * "Upgrading the SATCTLDB on Windows NT" Assessing DB2 Enterprise Edition on Windows NT If you have DB2 Enterprise Edition installed on Windows NT, perform the following steps: 1. Check whether the Control Server component is installed. Use the Registry Editor to display the list of installed components: a. Enter regedit at a command prompt. b. Under the HKEY_LOCAL_MACHINE\SOFTWARE\IBM\DB2\Components registry key, check whether the Control Server is listed. If it is not listed, the control server is not installed. 2. Determine the service level of DB2 Enterprise Edition. Issue the db2level command from a command prompt. Use the table that follows to interpret the output: +-----------------------------------------------------+--------------+ | Values of Key Fields in the db2level output | Your DB2 | |-----------------------------------------------------| system is | | Release | Level | Informational Tokens | at: | +----------------+----------+-------------------------+--------------+ | SQL06010 | 01010104 | db2_v6, n990616 | Version 6.1 | | | | | base | +----------------+----------+-------------------------+--------------+ | SQL06010 | 01020104 | DB2 V6.1.0.1, n990824, | Version 6.1 | | | | WR21136 | plus FixPak1 | +----------------+----------+-------------------------+--------------+ | SQL06010 | 01030104 | DB2 V6.1.0.6, s991030, | Version 6.1 | | | | WR21163 or DB2 | plus FixPak2 | | | | V6.1.0.9, s000101, | | | | | WR21173 | | +----------------+----------+-------------------------+--------------+ : If the level is greater than 01030104, your system is at a higher FixPak than FixPak 2. 3. Record the information that you find, and continue at "Determining What Needs to Be Done". Determining What Needs to Be Done Using the information that you have gathered, find the row in the following table that applies to your situation, and follow the steps that are required to prepare your DB2 Enterprise Edition system to support the DB2 control server at the FixPak 2 level or higher. Sections that follow the table provide instructions for performing the required steps. Consider checking off each step as you perform it. Only perform the steps that apply to your situation. +-----------------------+----------------------+----------------------+ | Control Server | Service Level of DB2 | Steps required to | | Component Installed | Enterprise Edition | prepare your DB2 | | | System | Enterprise Edition | | | | system | +-----------------------+----------------------+----------------------+ | No | Version 6.1 base, or | Perform the | | | Version 6.1 plus | following steps: | | | FixPak 1, or Version | 1. "Installing the | | | 6.1 plus FixPak 2 or | Control Server | | | higher | Component on Windows | | | | NT" | | | | 2. "Installing | | | | FixPak 2 or Higher | | | | on Windows NT" | | | | 3. "Upgrading the | | | | SATCTLDB on Windows | | | | NT" | +-----------------------+----------------------+----------------------+ | Yes | Version 6.1 base, or | Perform the | | | Version 6.1 plus | following steps: | | | FixPak 1 | 1. "Installing | | | | FixPak 2 or Higher | | | | on Windows NT" | | | | 2. "Upgrading the | | | | SATCTLDB on Windows | | | | NT" | +-----------------------+----------------------+----------------------+ | Yes | Version 6.1, plus | Perform the | | | FixPak 2 or higher | following step: | | | | 1. "Upgrading the | | | | SATCTLDB on Windows | | | | NT" | +-----------------------+----------------------+----------------------+ Installing the Control Server Component on Windows NT To install the Control Server component on Windows NT: 1. Ensure that all database activity on the system is complete before proceeding. 2. Insert the DB2 Universal Database Enterprise Edition Version 6.1 CD in the CD drive. If the installation program does not start automatically, run the setup command in the root of the CD to start the installation process. 3. When prompted, shut down all the processes that are using DB2. 4. On the Welcome window, select Next. 5. On the Select Products window, ensure that DB2 Enterprise Edition is selected. 6. On the Select Installation Type panel, click Custom. 7. On the Select Components panel, ensure that the Control Server component is selected, and click Next. : If you select other components that are not already installed on your system, these components will be installed too. You cannot alter the drive or directory in which DB2 is installed. 8. On the Configure DB2 Services panels, you can modify the protocol values and the start-up options for the Control Server instance, or take the default values. Either modify the defaults and click Next, or click Next to use the defaults. 9. Click Next on the Start Copy files window to begin the installation process. 10. When the file copying process is complete, you have the option of rebooting your system. You should reboot now. The changes made to the system for the Control Server do not take effect until the system is rebooted. When the installation process is complete and you have rebooted the system, the satellite control database (SATCTLDB) that was created as part of the Control Server installation must be cataloged in the DB2 instance if you want to use the and P̝z locally on the system. To catalog the SATCTLDB database: 1. Open a DB2 Command Window by selecting Start>Programs>DB2 for Windows NT>Command Window 2. Ensure that you are in the db2 instance. Issue the set command and check the value of db2instance. If the value is not db2, issue the following command: set db2instance=db2 3. Catalog the db2ctlsv instance by entering the following command: db2 catalog local node db2ctlsv instance db2ctlsv 4. Catalog the SATCTLDB database by entering the following command db2 catalog database satctldb at node db2ctlsv 5. Commit the cataloging actions by entering the following command: db2 terminate 6. Close the DB2 Command Window. Installing FixPak 2 or Higher on Windows NT To upgrade an existing Version 6 DB2 Enterprise Edition system on Windows NT to FixPak 2 or higher, either: * Download the latest FixPak for DB2 Enterprise Edition for Windows NT V6.1 from the Web, along with its accompanying readme. The FixPak can be downloaded by following the instructions at URL: http://www.ibm.com/software/data/db2/db2tech/version61.html Install the FixPak following the instructions in the readme.txt file. * Use a DB2 Universal Database, Version 6.1 FixPak for Windows NT CD that is at FixPak 2 level or higher, and follow the instructions in the readme.txt file in the WINNT95 directory on the CD to complete the installation. Upgrading the SATCTLDB on Windows NT To upgrade the SATCTLDB database on Windows NT 1. Determine the level of the SATCTLDB database: a. Log on with a user ID that has local administrative authority on the Windows NT system. b. Open a DB2 Command Window by selecting Start>Programs>DB2 for Windows NT>Command Window. c. Connect to the SATCTLDB by entering the following command db2 connect to satctldb d. Determine if the trigger I_BATCHSTEP_TRGSCR exists in the database by issuing the following query: db2 select name from sysibm.systriggers where name='I_BATCHSTEP_TRGSCR' Record the number of rows that are returned. e. Enter the following command to close the connection to the database: db2 connect reset If step d returned one row, the database is at the correct level. In this situation, skip step 2, and continue at step 3. If zero (0) rows are returned, the database is not at the correct level, and must be upgraded, as described in step 2, before you can perform step 3. 2. To upgrade the SATCTLDB database, perform the following steps. Enter all commands in the DB2 Command Window: a. Switch to the directory \misc, where is the install drive and path, for example c:\sqllib. b. Ensure that you are in the db2ctlsv instance. Issue the set command and check the value of db2instance. If the value is not db2ctlsv, issue the following command: set db2instance=db2ctlsv c. Drop the SATCTLDB database by entering the following command: db2 drop database satctldb d. Create the new SATCTLDB database by entering the following command: db2 -tf satctldb.ddl -z satctldb.log e. Issue the following command: db2 terminate 3. Bind the db2satcs.dll stored procedure to the SATCTLDB database. Perform the following steps: a. Connect to the SATCTLDB database by entering the following command db2 connect to satctldb b. Switch to the directory \bnd, where is the install drive and path, for example c:\sqllib. c. Issue the bind command, as follows: db2 bind db2satcs.bnd 4. Enter the following command to close the connection to the database: db2 connect reset 5. Close the DB2 Command Window. Upgrading DB2 Enterprise Edition on AIX Use the information in the sections that follow to determine the current service level of your Version 6 DB2 Enterprise Edition system, and the steps that you need to perform to update the system to the FixPak 2 service level, or higher. You will need to perform the steps of one or more of the following sections: * "Assessing DB2 Enterprise Edition on AIX" * "Determining What Needs to Be Done" * "Installing the Control Server Component on AIX" * "Installing FixPak 2 or Higher on AIX" * "Upgrading the SATCTLDB Database on AIX" Assessing DB2 Enterprise Edition on AIX If you have Version 6 DB2 Enterprise Edition installed on AIX, perform the following steps: 1. Check whether the Control Server component is installed. Enter the following command: lslpp -l | grep db2_06_01.ctsr If no data is returned, the Control Server component is not installed. 2. Determine the service level of the DB2 Enterprise Edition. Log on as a DB2 instance owner, and issue the db2level command. Use the table that follows to interpret the output: +-----------------------------------------------------+--------------+ | Values of Key Fields in the db2level output | Your DB2 | |-----------------------------------------------------| system is | | Release | Level | Informational Tokens | at: | +----------------+----------+-------------------------+--------------+ | SQL06010 | 01010104 | db2_v6, n990616 | Version 6.1 | | | | | base | +----------------+----------+-------------------------+--------------+ | SQL06010 | 01020104 | DB2 V6.1.0.1, n990824, | Version 6.1 | | | | U465423 | plus FixPak1 | +----------------+----------+-------------------------+--------------+ | SQL06010 | 01030104 | DB2 V6.1.0.6, s991030, | Version 6.1 | | | | U468276 or DB2 | plus FixPak2 | | | | V6.1.0.9, s000101, | | | | | U469453 | | +----------------+----------+-------------------------+--------------+ : If the level is greater than 01030104, your system is at a higher FixPak than FixPak 2. 3. Record the information that you find, and continue at "Determining What Needs to Be Done". Determining What Needs to Be Done Using the information that you have gathered, find the row in the following table that applies to your situation, and follow the steps that are required to prepare your Version 6 DB2 Enterprise Edition system to support the DB2 control server at the FixPak 2 level. Sections that follow the table provide instructions for performing the required steps. Consider checking off each step as you perform it. Only perform the steps that apply to your situation. +-----------------------+----------------------+----------------------+ | Control Server | Service Level of DB2 | Steps required to | | Component Installed | Enterprise Edition | prepare your DB2 | | | System | Enterprise Edition | | | | system | +-----------------------+----------------------+----------------------+ | No | Version 6.1 base, or | Perform the | | | Version 6.1 plus | following steps: | | | FixPak 1, or Version | 1. "Installing the | | | 6.1 plus FixPak 2 or | Control Server | | | higher | Component on AIX" | | | | 2. "Installing | | | | FixPak 2 or Higher | | | | on AIX" | | | | 3. "Upgrading the | | | | SATCTLDB Database on | | | | AIX" | +-----------------------+----------------------+----------------------+ | Yes | Version 6.1 base, or | Perform the | | | Version 6.1 plus | following steps: | | | FixPak 1 | 1. "Installing | | | | FixPak 2 or Higher | | | | on AIX" | | | | 2. "Upgrading the | | | | SATCTLDB Database on | | | | AIX" | +-----------------------+----------------------+----------------------+ | Yes | Version 6.1, plus | Perform the | | | FixPak 2 or higher | following step: | | | | 1. "Upgrading the | | | | SATCTLDB Database on | | | | AIX" | +-----------------------+----------------------+----------------------+ Installing the Control Server Component on AIX To install the Control Server component on AIX 1. Log on as a user with root authority. 2. Insert the DB2 Universal Database Enterprise Edition Version 6.1 CD in the CD drive. 3. Change to the directory where the CD is mounted, for example, cd /cdrom. 4. Type the following command to start the DB2 installer: ./db2setup 5. When the DB2 Installer window opens, use the tab key to select the Install option, and press Enter. 6. Locate the Enterprise Edition line and use the tab key to select the Customize option beside it. Press Enter. 7. Select the DB2 Control Server component, tab to OK, and press Enter. 8. Follow the instructions on the remaining windows to complete the installation of the DB2 Control Server component. When the installation process is complete, create the DB2CTLSV instance and the SATCTLDB database. To perform these tasks, follow the detailed instructions in "Setting up the DB2 Control Server on AIX" in Chapter 13 of the Administering Satellites Guide and Reference. Installing FixPak 2 or Higher on AIX To upgrade an existing DB2 Enterprise Edition system AIX to FixPak 2 or higher, either: * Download the latest FixPak for DB2 Enterprise Edition for AIX V6.1 from the Web, along with its accompanying FixPak readme. The FixPak can be downloaded by following the instructions at URL: http://www.ibm.com/software/data/db2/db2tech/version61.html Install the FixPak following the instructions in the FixPak readme file. * Use a DB2 Universal Database, Version 6.1 FixPak for AIX CD that is at FixPak 2 level or higher, and follow the instructions in the readme directory on the CD to complete the installation. Ensure that you have updated the DB2CTLSV instance by running the db2iupdt command as instructed in the FixPak readme file. Upgrading the SATCTLDB Database on AIX To upgrade the SATCTLDB database on AIX: 1. Determine the level of the SATCTLDB database: a. Log in as db2ctlsv. b. Ensure that the database server has been started. If the server is not started, issue the db2start command. c. Connect to the SATCTLDB database by entering the following command: db2 connect to satctldb d. Determine if the trigger I_BATCHSTEP_TRGSCR exists in the database by issuing the following query: db2 "select name from sysibm.systriggers where name='I_BATCHSTEP_TRGSCR'" Record the number of rows that are returned. e. Enter the following command to close the connection to the database: db2 connect reset If step d returned one row, the database is at the correct level. In this situation, skip step 2, and continue at step 3. If zero (0) rows are returned, the database is not at the correct level, and must be upgraded, as described in step 2, before you can perform step 3. 2. To upgrade the SATCTLDB database to the FixPak 2 level, perform the following steps. Enter all commands in the DB2 Command Window: a. Switch to the $HOME/sqllib/misc directory. b. Drop the SATCTLDB database by entering the following command: db2 drop database satctldb c. Create the new SATCTLDB database by entering the following command: db2 -tf satctldb.ddl -z $HOME/satctldb.log d. Issue the following command: db2 terminate 3. Bind the db2satcs.dll stored procedure to the SATCTLDB database. Perform the following steps: a. Connect to the SATCTLDB database by entering the following command db2 connect to satctldb b. Switch to the directory $HOME/sqllib/bnd. c. Issue the bind command, as follows: db2 bind db2satcs.bnd 4. Enter the following command to close the connection to the database: db2 connect reset Upgrading a Version 6 and P̝z To use a Version 6 and P̝z with a Version 6 DB2 control server and satellite control database (SATCTLDB) that have been upgraded to FixPak 2 or higher, the tools must also be upgraded to FixPak 2 or higher. If the and the P̝z are running on the same system as the DB2 control server, they were upgraded when the DB2 Enterprise Edition system was upgraded to FixPak 2. However, if you run these tools on another system, you must upgrade this system to the FixPak 2 level or higher. To upgrade this system to FixPak 2 or higher: * Download the latest FixPak for your product at the V6.1 level from the Web, along with its accompanying readme. FixPaks can be downloaded by following the instructions at URL: http://www.ibm.com/software/data/db2/db2tech/version61.html Install the FixPak following the instructions in the readme file. * Use a DB2 Universal Database, Version 6.1 FixPak CD for the operating system that you are running that is at FixPak 2 level or higher, and follow the instructions in the readme to complete the installation. Command Reference (Lլ) Update Available The Command Reference was updated as part of FixPak 4. The latest PDF is available for download online at http://www.ibm.com/software/data/db2/udb/winos2unix/support. The information in these notes is in addition to the updated reference. All updated documentation is also available on CD. This CD can be ordered through DB2 service using the PTF number U478862. Information on contacting DB2 Service is available at http://www.ibm.com/cgi-bin/db2www/data/db2/udb/winos2unix/support/help.d2w/report . db2updv7 - Update Database to Version 7 Current Fix Level This command updates the system catalogs in a database to support the current FixPak in the following ways: * Enables the use of the new built-in functions: ABS, DECRYPT_BIN, DECRYPT_CHAR, ENCRYPT, GETHINT, MULTIPLY_ALT, and ROUND. * Enables the use of the new built-in functions for Unicode databases: DATE(vargraphic), TIME(vargraphic), TIMESTAMP(vargraphic), GRAPHIC(datetime-expression), GRAPHIC(date-expression), GRAPHIC(time-expression), and VARGRAPHIC(datetime-expression). * Enables the use of the new built-in procedures (GET_ROUTINE_SAR and PUT_ROUTINE_SAR). * Adds or applies corrections to WEEK_ISO and DAYOFWEEK_ISO functions on Windows and OS/2 databases. * Applies a correction to table packed descriptors for tables migrated from Version 2 to Version 6. * Creates the view SYSCAT.SEQUENCES. * Creates the system objects needed in order to use a DB2 version 8 client to connect to a DB2 version 7 server. Authorization sysadm Required Connection Database. This command automatically establishes a connection to the specified database. Command Syntax >>-db2updv7---d--database_name--+--------------------------+----> '--u--userid---p--password-' >--+----+------------------------------------------------------>< '--h-' Command Parameters -d database-name Specifies the name of the database to be updated. -u userid Specifies the user ID. -p password Specifies the password for the user. -h Displays help information. When this option is specified, all other options are ignored, and only the help information is displayed. Example After installing the FixPak, update the system catalog in the sample database by issuing the following command: db2updv7 -d sample Usage Notes This tool can only be used on a database running DB2 Version 7.1 or Version 7.2 with at least FixPak 2 installed. If the command is issued more than once, no errors are reported and each of the catalog updates is applied only once. To enable the new built-in functions, all applications must disconnect from this database and the database must be deactivated if it has been activated. Additional Context for ARCHIVE LOG Usage Note The usage notes for ARCHIVE LOG currently state that using this command will cause a database to lose a portion of its log sequence number (LSN) space, and thereby hasten the exhaustion of valid LSNs. To put this space usage into context, if you have a log file size of 100MB and run ARCHIVE LOG every five minutes, it will still take approximately 40 years to exhaust the valid LSNs. Under most operating conditions, you will not experience an impact. REBIND The syntax diagram for the REBIND command should appear as follows: Oyk >>-REBIND--+---------+--package-name----------------------------> '-PACKAGE-' .-ANY----------. >--RESOLVE--+-CONSERVATIVE-+----------------------------------->< RUNSTATS In the documentation for the RUNSTATS command, the last paragraph of the "Usage Notes" has incorrect information. The last paragraph currently states what happens when inconsistencies are found when running the RUNSTATS command with and without distribution or index statistics. The statistics that are dropped or retained are not stated correctly. What follows are the correct statements about what happens. If you issue RUNSTATS on a table, then previously collected distribution statistics are dropped. If you issue RUNSTATS on indexes only, then previously collected distribution statistics are retained. db2inidb - Initialize a Mirrored Database The description of the RELOCATE USING configfile parameter should appear as follows: Specifies that the database files are to be relocated based on the information listed in the configuration file prior to initializing the database as a snapshot, standby or mirror. : For information on the format of the configuration file, see the Data Movement Utilities Guide and Reference. Usage Information If the RELOCATE USING configfile parameter is specified and the database is relocated successfully, then the configuration file is copied into the database directory and renamed db2path.cfg. During any subsequent crash recoveries or rollfoward recoveries, this configuration file is used to dynamically rename the container paths during the log file processing. If you initialize a snapshot or a mirror database, then the configuration file is removed automatically after the recovery completes. If you initialize a standby database, then the configuration file is not only removed after the recovery completes but is also removed if you cancel the recovery process. If you are working with a standby database that you are keeping in the pending state so that you can continually roll it forward, and you add new containers to the original database, then you can manually update the db2path.cfg file to indicate where the containers should be stored for the standby database. If you do not specify a location for the new containers, then DB2 will attempt to store them in the same location as the originals. db2relocatedb (new command) db2relocatedb - Relocate Database Renames a database, or relocates a database or part of a database (e.g., container, log directory) as specified in the configuration file provided by the user. This tool makes the necessary changes to the DB2 instance and database support files. v None ѝnsu None Oyk >>-db2relocatedb---f--configFilename--------------------------->< OЅ -f configFilename Specifies the name of the file containing configuration information necessary for relocating the database. This can be a relative or absolute filename. The format of the configuration file is: DB_NAME=oldName,newName DB_PATH=oldPath,newPath INSTANCE=oldInst,newInst NODENUM=nodeNumber LOG_DIR=oldDirPath,newDirPath CONT_PATH=oldContPath1,newContPath1 CONT_PATH=oldContPath2,newContPath2 ... Where: DB_NAME Specifies the name of the database being relocated. If the database name is being changed, both the old name and the new name must be specified. This is a required field. DB_PATH Specifies the path of the database being relocated. This is the path where the database was originally created. If the database path is changing, both the old path and new path must be specified. This is a required field. INSTANCE Specifies the instance where the database exists. If the database is being moved to a new instance, both the old instance and new instance must be specified. This is a required field. NODENUM Specifies the node number for the database node being changed. The default is 0. LOG_DIR Specifies a change in the location of the log path. If the log path is being changed, then both the old path and new path must be specified. This specification is optional if the log path resides under the database path, in which case the path is updated automatically. CONT_PATH Specifies a change in the location of table space containers. Both the old and new container path must be specified. Multiple CONT_PATH lines can be provided if there are multiple container path changes to be made. This specification is optional if the container paths reside under the database path, in which case the paths are updated automatically. : Blank lines or lines beginning with a comment character (#) will be ignored. d Example 1 To change the name of the database TESTDB to PRODDB in the instance DB2INST1 that resides on the path /home/db2inst1, create the following configuration file: DB_NAME=TESTDB,PRODDB DB_PATH=/home/db2inst1 INSTANCE=db2inst1 NODENUM=0 Save the configuration file as relocate.cfg and use the following command to make the changes to the database files: db2relocatedb -f relocate.cfg Example 2 To move the database DATAB1 from the instance JSMITH on the path /dbpath to the instance PRODINST do the following: 1. Move the files in the directory /dbpath/jsmith to /dbpath/prodinst. 2. Use the following configuration file with the db2relocatedb command to make the changes to the database files: DB_NAME=DATAB1 DB_PATH=/dbpath INSTANCE=jsmith,prodinst NODENUM=0 Example 3 The database PRODDB exists in the instance INST1 on the path /databases/PRODDB. The location of two tablespace containers needs to be changed as follows: * SMS container /data/SMS1 needs to be moved to /DATA/NewSMS1. * DMS container /data/DMS1 needs to be moved to /DATA/DMS1. After the physical directories and files have been moved to the new locations, the following configuration file can be used with the db2relocatedb command to make changes to the database files so that they recognize the new locations: DB_NAME=PRODDB DB_PATH=/databases/PRODDB INSTANCE=inst1 NODENUM=0 CONT_PATH=/data/SMS1,/DATA/NewSMS1 CONT_PATH=/data/DMS1,/DATA/DMS1 Example 4 The database TESTDB exists in the instance DB2INST1 and was created on the path /databases/TESTDB. Table spaces were then created with the following containers: TS1 TS2_Cont0 TS2_Cont1 /databases/TESTDB/TS3_Cont0 /databases/TESTDB/TS4/Cont0 /Data/TS5_Cont0 /dev/rTS5_Cont1 TESTDB is to be moved to a new system. The instance on the new system will be NEWINST and the location of the database will be /DB2. When moving the database, all of the files that exist in the /databases/TESTDB/db2inst1 directory must be moved to the /DB2/newinst directory. This means that the first 5 containers will be relocated as part of this move. (The first 3 are relative to the database directory and the next 2 are relative to the database path.) Since these containers are located within the database directory or database path, they do not need to be listed in the configuration file. If the 2 remaining containers are to be moved to different locations on the new system, they must be listed in the configuration file. After the physical directories and files have been moved to their new locations, the following configuration file can be used with db2relocatedb to make changes to the database files so that they recognize the new locations: DB_NAME=TESTDB DB_PATH=/databases/TESTDB,/DB2 INSTANCE=db2inst1,newinst NODENUM=0 CONT_PATH=/Data/TS5_Cont0,/DB2/TESTDB/TS5_Cont0 CONT_PATH=/dev/rTS5_Cont1,/dev/rTESTDB_TS5_Cont1 Example 5 The database TESTDB has 2 partitions on nodes 10 and 20. The instance is SERVINST and the database path is /home/servinst on both nodes. The name of the database is being changed to SERVDB and the database path is being changed to /databases on both nodes. In addition, the log directory is being changed on node 20 from /testdb_logdir to /servdb_logdir. Since changes are being made to both nodes, a configuration file must be created for each node and db2relocatedb must be run on each node with the corresponding configuration file. On node 10, the following configuration file will be used: DB_NAME=TESTDB,SERVDB DB_PATH=/home/servinst,/databases INSTANCE=servinst NODE_NUM=10 On node 20, the following configuration file will be used: DB_NAME=TESTDB,SERVDB DB_PATH=/home/servinst,/databases INSTANCE=servinst NODE_NUM=20 LOG_DIR=/testdb_logdir,/servdb_logdir ъk`N If the instance that a database belongs to is changing, the following must be done before running this command to ensure that changes to the instance and database support files will be made: * If a database is being moved to another instance, create the new instance. * Copy the files/devices belonging to the databases being copied onto the system where the new instance resides. The path names must be changed as necessary. * Change the permission of the files/devices that were copied so that they are owned by the instance owner. If the instance is changing, the tool must be run by the new instance owner. In a EEE environment, this tool must be run against every node that requires changes. A separate configuration file must be supplied for each node, that includes the NODENUM value of the node being changed. For example, if the name of a database is being changed, every node will be affected and the db2relocatedb command must be run with a separate configuration file on each node. If containers belonging to a single node are being moved, the db2relocatedb command only needs to be run once on that node. Х\ For more information, see the db2inidb - Initialize a Mirrored Database command in the Command Reference. db2move The db2move tool now has two addtional options, --aw and --sn. Full documentation for this tool follows: Database Movement Tool This tool facilitates the movement of large numbers of tables between DB2 databases located on workstations. The tool queries the system catalog tables for a particular database and compiles a list of all user tables. It then exports these tables in PC/IXF format. The PC/IXF files can be imported or loaded to another local DB2 database on the same system, or can be transferred to another workstation platform and imported or loaded to a DB2 database on that platform. : Tables with structured type columns are not moved when this tool is used. v This tool calls the DB2 export, import, and load APIs, depending on the action requested by the user. Therefore, the requesting user ID must have the correct authorization required by those APIs, or the request will fail. Oyk .-------------------------. V | >>-db2move--dbname--action----+---------------------+-+-------->< +--tc--table-creators-+ +--tn--table-names----+ +--sn--schema names---+ +--io--import-option--+ +--lo--load-option----+ +--l--lobpaths--------+ +--u--userid----------+ +--p--password--------+ '--aw-----------------' OЅ dbname Name of the database. action Must be one of: EXPORT, IMPORT, or LOAD. -tc table-creators. The default is all creators. This is an EXPORT action only. If specified, only those tables created by the creators listed with this option are exported. If not specified, the default is to use all creators. When specifying multiple creators, each must be separated by commas; no blanks are allowed between creator IDs. The maximum number of creators that can be specified is 10. This option can be used with the "-tn" and "-sn" options to select the tables for export. An asterisk (*) can be used as a wildcard character that can be placed anywhere in the string. -tn table-names. The default is all user tables. This is an EXPORT action only. If specified, only those tables whose names match exactly those in the specified string are exported. If not specified, the default is to use all user tables. When specifying multiple table names, each must be separated by commas; no blanks are allowed between table names. The maximum number of table names that can be specified is 10. This option can be used with the "-tc" and "-sn" options to select the tables for export. db2move will only export those tables whose names are matched with specified table names and whose creators are matched with specified table creators. An asterisk (*) can be used as a wildcard character that can be placed anywhere in the string. -sn schema names. The default is ALL SCHEMAS. This is an EXPORT action only. If specified, only those tables whose schemas match exactly those in the specified string are exported. If not specified, the default is to use all schemas. When specifying multiple schema names, each must be separated by commas; no blanks are allowed between schema names. The maximum number of schema names that can be specified is 10. This option can be used with the "-tc" and "-tn" options to select the tables for export. db2move will only export those tables whose names are matched with specified table names, whose schemas are matched with specific table schemas, and whose creators are matched with specified table creators. An asterisk (*) can be used as a wildcard character that can be placed anywhere in the string. : Schema names less than 8 characters in length are padded to be 8 characters long. For example, if you want to include the schemas "AUSER" and "BUSER"and use the wildcard character, you must specify -sn *USER*. -io import-option. The default is REPLACE_CREATE. Valid options are INSERT, INSERT_UPDATE, REPLACE, CREATE, and REPLACE_CREATE. -lo load-option. The default is INSERT. Valid options are INSERT and REPLACE. -l lobpaths. The default is the current directory. This option specifies the absolute path names where LOB files are created (as part of EXPORT) or searched for (as part of IMPORT or LOAD). When specifying multiple LOB paths, each must be separated by commas; no blanks are allowed between LOB paths. If the first path runs out of space (during EXPORT), or the files are not found in the path (during IMPORT or LOAD), the second path will be used, and so on. If the action is EXPORT, and LOB paths are specified, all files in the LOB path directories are deleted, the directories are removed, and new directories are created. If not specified, the current directory is used for the LOB path. -u userid. The default is the logged on user ID. Both user ID and password are optional. However, if one is specified, the other must be specified. If the command is run on a client connecting to a remote server, user ID and password should be specified. -p password. The default is the logged on password. Both user ID and password are optional. However, if one is specified, the other must be specified. If the command is run on a client connecting to a remote server, user ID and password should be specified. -aw allow warnings. Used for the EXPORT action only. If this option is specified, then any tables that receive warnings during export will be included in the db2move.lst file. If the option is omitted, then any tables that cause warnings during export are not included in the db2move.lst file. A table's .ixf file and .msg file are generated regardless of whether or not this option is used. d * db2move sample export This will export all tables in the SAMPLE database; default values are used for all options. * db2move sample export -tc userid1,us*rid2 -tn tbname1,*tbname2 This will export all tables created by "userid1" or user IDs LIKE "us%rid2", and with the name "tbname1" or table names LIKE "%tbname2". * db2move sample import -l D:\LOBPATH1,C:\LOBPATH2 This example is applicable to OS/2 or the Windows operating system only. The command will import all tables in the SAMPLE database; LOB paths "D:\LOBPATH1" and "C:\LOBPATH2" are to be searched for LOB files. * db2move sample load -l /home/userid/lobpath,/tmp This example is applicable to UNIX-based systems only. The command will load all tables in the SAMPLE database; both the /home/userid/lobpath subdirectory and the tmp subdirectory are to be searched for LOB files. * db2move sample import -io replace -u userid -p password This will import all tables in the SAMPLE database in REPLACE mode; the specified user ID and password will be used. ъk`N This tool exports, imports, or loads user-created tables. If a database is to be duplicated from one operating system to another operating system, db2move facilitates the movement of the tables. It is also necessary to move all other objects associated with the tables, such as aliases, views, triggers, user-defined functions, and so on. db2look (DB2 Statistics and DDL Extraction Tool; see the Command Reference) can facilitate the movement of some of these objects by extracting the data definition language (DDL) statements from the database. When export, import, or load APIs are called by db2move, the FileTypeMod parameter is set to lobsinfile. That is, LOB data is kept in separate files from PC/IXF files. There are 26 000 file names available for LOB files. The LOAD action must be run locally on the machine where the database and the data file reside. When the load API is called by db2move, the CopyTargetList parameter is set to NULL; that is, no copying is done. If logretain is on, the load operation cannot be rolled forward later. The table space where the loaded tables reside is placed in backup pending state and is not accessible. A full database backup, or a table space backup, is required to take the table space out of backup pending state. When issued on a Version 5.2 client against a Version 6 database, this tool does not support table or column names that are greater than 18 characters in length. Files Required/Generated When Using EXPORT: * Input: None. * Output: EXPORT.out The summarized result of the EXPORT action. db2move.lst The list of original table names, their corresponding PC/IXF file names (tabnnn.ixf), and message file names (tabnnn.msg). This list, the exported PC/IXF files, and LOB files (tabnnnc.yyy) are used as input to the db2move IMPORT or LOAD action. tabnnn.ixf The exported PC/IXF file of a specific table. tabnnn.msg The export message file of the corresponding table. tabnnnc.yyy The exported LOB files of a specific table. "nnn" is the table number, "c" is a letter of the alphabet, "yyy" is a number ranging from 001 to 999. These files are created only if the table being exported contains LOB data. If created, these LOB files are placed in the lobpath directories. There are a total of 26 000 possible names for the LOB files. system.msg The message file containing system messages for creating or deleting file or directory commands. This is only used if the action is EXPORT and a LOB path is specified. Files Required/Generated When Using IMPORT: * Input: db2move.lst An output file from the EXPORT action. tabnnn.ixf An output file from the EXPORT action. tabnnnc.yyy An output file from the EXPORT action. * Output: IMPORT.out The summarized result of the IMPORT action. tabnnn.msg The import message file of the corresponding table. Files Required/Generated When Using LOAD: * Input: db2move.lst An output file from the EXPORT action. tabnnn.ixf An output file from the EXPORT action. tabnnnc.yyy An output file from the EXPORT action. * Output: LOAD.out The summarized result of the LOAD action. tabnnn.msg The LOAD message file of the corresponding table. Additional Option in the GET ROUTINE Command This command now supports the HIDE BODY parameter, which specifies that the body of the routine must be replaced by an empty body when the routine text is extracted from the catalogs. This does not affect the compiled code; it only affects the text. GET ROUTINE Oyk >>-GET ROUTINE--INTO--file_name--FROM--+----------+-------------> '-SPECIFIC-' >----PROCEDURE----routine_name--+-----------+------------------>< '-HIDE BODY-' CREATE DATABASE DB2 now supports new collation sequence keywords, IDENTITY_16BIT and SQL_CS_IDENTITY_16BIT, for Unicode databases. When IDENTITY_16BIT is specified for the CLP CREATE DATABASE command or SQLEDBDESC.SQLDBCSS is set to SQL_CS_IDENTITY_16BIT in the sqlecrea() -- Create Database API, all data in the Unicode database will be collated using the CESU-8 order. CESU-8 is Compatibility Encoding Scheme for UTF-16: 8-Bit, and as of this writing, its specification is contained in the Draft Unicode Technical Report #26 available at the Unicode Technical Consortium web site(www.unicode.org). CESU-8 is binary identical to UTF-8 except for the Unicode supplementary characters, that is, those characters that are defined outside the 16-bit Basic Multilingual Plane (BMP or Plane 0). In UTF-8 encoding, a supplementary character is represented by one 4-byte sequence, but the same character in CESU-8 requires two 3-byte sequences. In a Unicode database, CHAR, VARCHAR, LONG VARCHAR, and CLOB data are stored in UTF-8, and GRAPHIC, VARGRAPHIC, LONG VARGRAPHIC, and DBCLOB data are stored in UCS-2. For IDENTITY or SQL_CS_NONE collation, non-supplementary characters in UTF-8 and UCS-2 have identical binary collation, but supplementary characters in UTF-8 collate differently from the same characters in UCS-2. IDENTITY_16BIT or SQL_CS_IDENTITY_16BIT ensures all characters, supplementary and non-supplementary, in a DB2 Unicode databases have the same binary collation. Data Recovery and High Availability Guide and Reference (Lլ) Data Recovery and High Availability Guide and Reference Available Online The new Data Recovery and High Availability Guide and Reference is now available online in both HTML and PDF format at http://www.ibm.com/software/data/db2/udb/winos2unix/support. This information was previously contained in the Administration Guide. The information in these notes is in addition to the updated reference. All updated documentation is also available on CD. This CD can be ordered through DB2 service using the PTF number U478862. Information on contacting DB2 Service is available at http://www.ibm.com/cgi-bin/db2www/data/db2/udb/winos2unix/support/help.d2w/report . New Archive Logging Behavior Prior to FixPak 4, DB2 only checked for archive completion when a new log file was needed. Now DB2 checks for archive completion whenever the first active log changes. As a result, information is recorded to disk earlier and more often. The benefit of this change is that if the system crashes, the information stored on disk (related to which log files are successfully archived) is more accurate and DB2 does not have to reissue the archive request for log files that are already archived. There is no change to what DB2 does after detecting the successful archive of a particular log file. DB2 now detects the completion of log archives earlier and will rename them earlier. Inactive truncated log files are deleted. As a result, the number of log files remaining in the active log path can be less than the LOGPRIMARY database configuration value. In this case, DB2 will create new log files when needed. Before this change, restarting the database reduced the number of logs to equal the value of LOGPRIMARY. Now, when you restart a database, DB2 first examines the database log directory. If the number of empty logs is fewer than the number of primary logs, DB2 will allocate new logs to make up the difference. If more empty logs are available than there are primary logs in the database directory, DB2 will allow the database to be restarted with all the available empty logs in the database directory. After database shutdown, any secondary log files in existence will remain in the active log path at restart time. To clear out the active log path, the DB2 ARCHIVE LOG command may be used. How to Use Suspended I/O for Database Recovery The information below about the db2inidb utility supersedes the information in the Version 7.2 What's New book. db2inidb is a tool shipped with DB2 that can perform crash recovery or put a database in rollforward pending state. Suspended I/O supports continuous system availability by providing a full implementation for online split mirror handling, that is, splitting a mirror without shutting down the database. If you cannot afford to do offline or online backups on a large database, you can do backups or system copies from a mirror image by using suspended I/O and a split mirror image. Suspended I/O prevents disk writes while the split mirror image of a database is being taken. All database operations besides online backup and restore should function normally while a database is suspended. However, some operations may wait for I/O writes to resume if dirty pages must be flushed from the buffer pool or log buffers to the logs. These operations should resume normally once the database I/O is resumed. It is important that the database I/O be resumed from the same connection that it was originally suspended and that no other operations be performed from this connection until the database I/O resumes. Otherwise, subsequent connection attempts may hang if they require flushing dirty pages from the buffer pool to disk. Subsequent connections will complete once database I/O resumes. If your connection attempts are hanging, and it has become impossible to resume the I/O from the connection that you used to suspend it, then you will have to run the RESTART command with the WRITE RESUME option. When used in this circumstance, the RESTART command will resume I/O writes without performing crash recovery. The RESTART command with the WRITE RESUME option will only perform crash recovery when you use it after a database crash. In a partitioned database environment, you don't have to suspend I/O writes on all partitions simultaneously. You can suspend a subset of one or more partitions in order to create split mirrors to perform offline backups. If the catalog node is included in the subset, it must be the last partition to be suspended. Mirroring a database primarily involves copying the entire contents of the database directory, and the local database directory. The local database directory, sqldbdir, is located at the same level of the file structure as the main database directory. In addition, if the log directory and table space containers are not in the database directory, then they must also be copied. Since the split mirrored database is dependent on these directory paths, the paths that these directories are copied to must be identical to those of the primary system. This means that the instance must also be the same. As a result of this dependency, it is not possible to create a mirror database on the same system as the primary database unless the new "relocate" option of the db2inidb tool is used. The purpose of the "relocate" option is to relocate a database on a given system using a specified configuration file. This can involve changing the internal database directory, container directory, log directory, instance name and database names. Assuming the database directory, container directories and log directory were successfully mirrored to different directory paths on the same system as the primary database, the db2inidb tool can be used along with the "relocate" option to update the mirrored database's internal paths. A usage scenario with this option can be found below. Depending on how the storage devices are being mirrored, the uses of db2inidb will vary. The following uses assume that the entire database is mirrored consistently through the storage system. In a multinode environment, the db2inidb tool must be run on every partition before the split mirror can be used from any of the partitions. The db2inidb tool can be run on all partitions simultaneously by using the db2_all command. 1. Making a Clone Database The objective here is to have a clone of the primary database to be used on another system. The following procedure describes how a clone database may be made: a. Suspend I/O writes on the primary database by entering the following command: db2 set write suspend for database b. Use operating system and disk subsystem level commands to split the mirror from the primary database. Ensure that you split both the data and the logs. c. Resume I/O writes on the primary database by entering the following command: db2 set write resume for database After running the command, the primary database should be back to a normal state. d. Mount the split mirror of the primary database on another system. e. Start the database instance on the other system, by entering the following command: db2start f. Start the DB2 crash recovery by entering the following command: db2inidb database_name AS SNAPSHOT : This command will remove the suspend write state and roll back the changes made by transactions that were occurring at the time of the split. You can also use this process to perform an offline backup, but if restored on the primary database, this backup cannot be used to roll forward, because the log chain will not match. 2. Using the Split Mirror as a Standby Database As the mirrored (standby) database is continually rolling forward through the logs, new logs that are being created by the primary database are constantly fetched from the primary system. The following procedure describes how the split mirror can be used as a standby database: a. Suspend I/O writes on the primary database: db2 set write suspend for database b. Use operating system and disk subsystem level commands to split the mirror from the primary database. Ensure that you only split the data and not the logs. c. Resume the I/O writes on the primary database so that it goes back to normal processing. db2 set write resume for database d. Mount the split mirror of the database to another system. e. Start the primary database instance by using the db2start command. f. Place the mirror in roll forward pending: db2inidb database_name AS STANDBY : This command will remove the suspend write state and place the mirrored database in rollforward pending state. g. Copy logs by setting up a user exit program to retrieve log files from the primary system to ensure that the latest logs will be available for this mirrored database. h. Roll forward the database to the end of the logs. i. Go back to step g and repeat this process until the primary database is down. j. Roll forward the database to the end of the logs, using the AND STOP option to bring the database back online. It will now be ready to use. 3. Using the Split Mirror as a Backup Image The following procedure describes how to use the mirrored database as a backup image to restore over the primary database: a. Stop the primary database instance with the db2stop command. b. Use operating system and disk subsystem commands to copy the mirrored data back on top of the primary database. Do not copy back the log files. The logs on the primary database must be used for rollforward operations. c. Start the primary database instance with the db2start command. d. Run the following command to place the mirrored database in a rollforward pending state and to remove the suspend write state: db2inidb database_name AS MIRROR e. Roll forward the database to the end of the logs, using the AND STOP option to bring the database back online. It will now be ready to use. 4. Splitting a Mirror onto the Same System as the Primary Database The following procedure describes how to use the "relocate" option of the db2inidb tool to mirror a database onto the same system as the primary database. The example assumes that the database will be used under a new instance. a. Create a new instance on the current system. b. Suspend I/O writes on the primary database: db2 set write suspend for database c. Use the operating system and disk subsystem level commands to split the mirror from the primary database. : The database directory, local database directory, container directories, and log directory must be copied to the new instance. If the container directories or the log directory exist under the database directory, then only the database directory and local database directory need to be copied. d. Resume I/O writes on the primary database so that it goes back to normal processing: db2 set write resume for database e. Create a configuration file with the following information: DB_NAME=name,optional_new_name DB_PATH=primary_db_dir_path,mirrored_db_dir_path INSTANCE=primary_instance,mirror_instance LOG_DIR=primary_db_log_dir,mirrored_db_log_dir CONT_PATH=primary_db_container_#1_path, mirrored_db_container_#1_path ... CONT_PATH=primary_db_container_#n_path, mirrored_db_container_#n_path NODENUM=node_# : The LOG_DIR and the CONT_PATH fields are required only if the log directory and container directories exist outside of the database directory. All of the other fields are required, except for NODENUM, which will default to zero if not specified. f. Start the database from the newly created instance: db2start g. Relocate the mirrored database, remove the suspended state, and place the mirror in the rollforward pending state: db2inidb database_name as STANDBY relocate using config_file h. Copy logs by setting up a user exit program to retrieve log files from the primary database to ensure that the latest logs will be available for this mirrored database. i. Roll forward the database to the end of the logs. j. Go back to step h and repeat this process until the primary database is down. k. Roll forward the database to the end of the logs, using the AND STOP option to bring the database back online. It will now be ready to use. New Backup and Restore Behavior When LOGRETAIN=CAPTURE If a database is configured with LOGRETAIN set to CAPTURE, the following operations cannot be performed: * Online database backup * Online or offline table space-level backup * Online or offline table space-level restore Following a database restore operation using an offline backup image taken while LOGRETAIN is set to CAPTURE, the database is not put in rollforward pending state. A database restore operation using an online database backup image taken while LOGRETAIN is set to CAPTURE (Version 7.2 prior to FixPak 4) is supported. Incremental Backup and Recovery - Additional Information During the second phase of processing, the database history is queried to build a chain of backup images required to perform the requested restore operation. If, for some reason, this is not possible, and DB2 is unable to build a complete chain of required images, the restore operation terminates, and an error message is returned. In this case, an automatic incremental restore will not be possible, and you will have issue the RESTORE DATABASE command with the INCREMENTAL ABORT option. This will cleanup any remaining resources so that you can proceed with a manual incremental restore. During the third phase of processing, DB2 will restore each of the remaining backup images in the generated chain. If an error occurs during this phase, you will have to issue the RESTORE DATABASE command with the INCREMENTAL ABORT option to cleanup any remaining resources. You will then have to determine if the error can be resolved before you re-issue the RESTORE command or attempt the manual incremental restore again. NEWLOGPATH2 Now Called DB2_NEWLOGPATH2 References to the NEWLOGPATH2 registry variable have been changed to DB2_NEWLOGPATH2. Choosing a Backup Method for DB2 Data Links Manager on AIX or Solaris Operating Environment Before setting the PASSWORDACCESS option in the Tivoli Storage Manager system options file, you must ensure that /usr/lib contains a symbolic link to thelibApiDS.a library file. Tivoli Storage Manager -- LAN Free Data Transfer DB2 Universal Database now allows users to use Tivoli's LAN Free Data Transfer technology for backups and restores to a TSM server. If you are using one of the following versions of DB2 Universal Database in conjunction with Tivoli's ADSM 3.1.x clients, you may experience problems when backing up or restoring to a TSM server: * DB2 for AIX (32-bit) * DB2 for Solaris @~ (32-bit) * DB2 for HP-UX (32-bit). If you experience these problems, then carry out the following steps to correct them: 1. Issue a db2stop command. 2. Locate the sqllib/adsm directory on the DB2 UDB server. 3. Create a backup copy of libtadsm.a. Making a copy of it called libtadsm.a.bak is sufficient. 4. Copy libadsm.a to libtasdm.a. 5. Issue a db2start command. 6. Re-issue the failed backup or restore command. Data Movement Utilities Guide and Reference (Lլ) Extended Identity Values Now Fully Supported by Export Utility The export utility now fully supports extended identity values. You will need both your client and server to be running with FixPak 7 or later in order to exploit this function. Change to LOB File Handling by Export, Import, and Load DB2 UDB now makes use of LOB location specifiers (LLSs) when importing, exporting, and loading large object (LOB) information. This allows multiple LOBs to be stored in a single file. An LLS is a string indicating where LOB data can be found within a file. The format of the LLS is filename.ext.nnn.mmm/, where filename.ext is the name of the file that contains the LOB, nnn is the offset of the LOB within the file (measured in bytes), and mmm is the length of the LOB (in bytes). For example, an LLS of db2exp.001.123.456/ indicates that the lob is located in file db2exp.001, begins at an offset of 123 bytes into the file, and is 456 bytes long. If the indicated size in the LLS is 0, the LOB is considered to have a length of 0. If the length is -1, the LOB is considered to be NULL and the file name and offset do not matter. When exporting data using the lobsinfile modifier, the LOBs will not always be placed into separate files. There may be multiple LOBs in each LOB file, and multiple LOB files per LOB path. The data file will now contain LLS records instead of just file names. The import and load functions have also been changed to handle the changes to the export function. When loading or importing data with the modified by lobsinfile option specified, LLSs will be expected for each of the corresponding LOB columns. If something other than an LLS is encountered for a LOB column, the database will treat it as a LOB file, and will load the entire file as the LOB. IXF Considerations There are three new IXF data types. These three types correspond to character large objects (CLOBs), binary large objects (BLOBs), and double-byte character large objects (DBCLOBs) when represented by LLSs. The values of these data types are 964, 960, and 968 respectively. IXF files now require each LOB column to have its own D record. This is created automatically by the export tool, but must be created manually if you are using a third party utility to create the IXF files. Additionally, an LLS is required for each LOB in the table, and not just the non-null LOBs. If a LOB column is null, you must write an LLS representing a null LOB. Code Page Support for Import, Export and Load Utilities The import, export and load utilities can now be used to transfer data from the new Chinese code page GB 18030 (code page identifier 5488) and the new Japanese code page ShiftJIS X0213 (code page identifier 1394) to DB2 UDB Unicode databases. In addition, the export utility can be used to transfer data from DB2 UDB Unicode databases to GB 18030 or ShiftJIS X0213 code page data. For example, the following command will load the Shift_JISX0213 data file u/jp/user/x0213/data.del residing on a remotely connected client into MYTABLE: db2 load client from /u/jp/user/x0213/data.del of del modified by codepage=1394 insert into mytable where MYTABLE is located on a DB2 UDB Unicode database. Chapter 2. Import Using Import with Buffered Inserts The note at the end of this section should read: : In all environments except EEE, the buffered inserts feature is disabled during import operations in which the INSERT_UPDATE parameter is specified. Chapter 3. Load Pending States After a Load Operation The first two sentences in the last paragraph in this section have been changed to the following: The fourth possible state associated with the load process (check pending state) pertains to referential and check constraints, DATALINKS constraints, AST constraints, or generated column constraints. For example, if an existing table is a parent table containing a primary key referenced by a foreign key in a dependent table, replacing data in the parent table places both tables (not the table space) in check pending state. Load Restrictions and Limitations The following restrictions apply to generated columns and the load utility: * It is not possible to load a table having a generated column in a unique index unless the generated column is an "include column" of the index or the generatedoverride file type modifier is used. If this modifier is used, it is expected that all values for the column will be supplied in the input data file. * It is not possible to load a table having a generated column in the partitioning key unless the generatedoverride file type modifier is used. If this modifier is used, it is expected that all values for the column will be supplied in the input data file. totalfreespace File Type Modifier The totalfreespace file type modifier (LOAD) has been modified to accept a value between 0 and 2 147 483 647. Chapter 4. AutoLoader AutoLoader Restrictions and Limitations The following have been added to the restrictions and limitations for the AutoLoader utility: 1. AutoLoader must be executed on one of the server nodes. 2. If multiple instances exist, the AutoLoader can only be used against databases that are local to the instance specified by the DB2INSTANCE environment variable. Using AutoLoader The following has been added to the "Before Using AutoLoader" section: Prior to invoking the AutoLoader utility ensure that rsh and/or rexec are functioning properly. Rexec is used to spawn remote processes if the password is specified in the AutoLoader configuration file. Otherwise, rsh is used. rexecd Required to Run AutoLoader When Authentication Set to YES In the AutoLoader Options section the following note will be added to the AUTHENTICATION and PASSWORD parameters description: In a Linux environment, if you are running the AutoLoader with the authentication option set to YES, rexecd must be enabled on all machines. If rexecd is not enabled the following error message will be generated: openbreeze.torolab.ibm.com: Connection refused SQL6554N An error occurred when attempting to remotely execute a process. The following error messages will be generated in the db2diag.log file: 2000-10-11-13.04.16.832852 Instance:svtdbm Node:000 PID:19612(db2atld) Appid: oper_system_services sqloRemoteExec Probe:31 AutoLoader May Hang During a Fork on AIX Systems Prior to 4.3.3 The AutoLoader is a multithreaded program and one of the threads forks off another process. Forking off a child process causes an image of the parent's memory to be created in the child. On AIX systems prior to AIX 4.3.3, it is possible that locks used by libc.a to manage multiple threads allocating memory from the heap within the same process will be held by a non-forking thread. Since the non-forking thread will not exist in the child process, this lock will never be released in the child, causing the parent to sometimes hang. AIX 4.3.3 contains a fix for a libc problem that could cause the AutoLoader to hang during a fork. Appendix C. Export/Import/Load Utility File Formats The following update has been added to this Appendix: The export, import, and load utilities are not supported when they are used with a Unicode client connected to a non-Unicode database. Unicode client files are only supported when the Unicode client is connected to a Unicode database. Replication nPЪU gD IBM A ъ DataJoiner у 2 s˺g۫㪌D IBM AAD IBM Ag۫Ap InformixBMicrosoft SQL ServerBOracleBSybaseB Sybase SQL AnywhereC ziHъgpsA] DB2 Relational Connect у 7 SsOC{s DB2 M DataJoiner уʪѡx]AS/400BOS/2BOS/390BUNIX Windows^Azѝъ DJRA ]DataJoiner g̝z^ˀ̝zSݬgC b Windows 2000 Wg DB2 DataPropagator у 7 P Windows 2000 @~teC xs SQL Ϋw~ Yb DB2 Connect Personal Edition ъuvAzLkxs SQL CYxs SQL AzN@hь DAS b@ъ񬀓~TA W DAS S@ъA]ѪSH DB2 Connect PE XfC ъ{񊜜OW uъ{vʿъOWѝXuvъOWAuъ{v~ ѓ`B@C DB2 @ ϑzwbgъU DB2 ~ws DB2 @C Web W Data Difference Utility ziHq Web U Data Difference utility (DDU)A}pUG ftp:// ftp.software.ibm.com/ps/products/datapropagator/fixes/C DDU O@ˢd ъ{AМz񱩹PάԡPуAHсX˚ьу tCȝ˩ۛTAХ\dъ{ʬ README C 3 . ۫㺍gۛd gۛ Х\ DataPropagator Library ¡ (http://www.ibm.com/software/data/dpropr/) HoPs۫㺍gۛd C ˇۛd񬀿BJAq AIX W Oracle ۫wgݫN s DB2 for Windows NT W۫wυݫC ˇۛdʿъ DB2 DataJoiner Replication Administration (DJRA) uB^oBъ{ DB2 DataJoinerC bЬ 44 ABJ 6 񪐖ыqXάь˪pUG BJ 6GыqX ]ъ{탦nsAAzѝы@ːqXο˛ъ C Twъ˛ъ{ъ ID iHqXC YnыqXG 1. q Windows NT ROьAϓ C:\scriptsC 2. bϓы@s DEPTQUAL.PWD sC ziHъѶժrs {˽ыo˔Ap NotepadC qXάRWDʼ applyqual .pwdF applyqual rۼOjpgA ѝXzbыwg] wъъw񩬀rڮMC bۛdAъwO DEPTQUALC : ] DB2 DataPropagator у 5 HˬήRWDC 3. qXάepUG SERVER=server USER=userid PWD=password G A Bυ𮊜AWAѝPwg]wݫʚь ю@PC bۛdAoêW SAMPLE COPYDBC userid zpъˀ̝z˻Sw۫wъ IDCYO Windows NT UNIX @ ~tAhnjpgC password Pъ ID qXC YO Windows NT UNIX @~tAh njpgC nbo˔[JўЪC „sWAWBъ ID MqXۛTC 4. qXάe_˔˖G SERVER=SAMPLE USER=subina PWD=subpw SERVER=COPYDB USER=subina PWD=subpw DB2 ʃPKO@ȝ˩ۛTAХ\IBM DB2 Administration GuideC 5 . gW ݫ񊬢W gݫ񊬢W񬀬ўC DATALINK g b Solaris @~WADATALINK gi@у 7.1 FixPak 1 @ѸC Ѫn@ FTP `n{Abυ DATALINK οt񛧪A MDTM (modtime) OA˚ьwάeκCpGzъOу 2.6 Solaris @~tAѶ]A MDTM FTP Ahzn[n Ap WU-FTPDC zӪb AS/400 MLѡx DB2 ۫wg DATALINK C b AS/400 ѡxS DATALINK uvgC AIX 4.2 Abzw]ъX{ (ASNDLCOPY) eAѝw APAR IY03101 (AIX 4210-06 ϑ@ AIX 4.2.1) PTFC o PTF ]AF FTP `n{ "modtime/MDTM" O Y2Kѓ{C ʩˡѓ{A 𔈼d "modtime " Oê^ˬeκA 2000 ~ 1 1 ߮ʡκC pGυݫO~ CCD ݫADB2 DataPropagator |Is ASNDLCOPY ` g DATALINK C ASNDLCOPY M ASNDLCOPYDF ъAХ\U{ lXÿC The following restrictions apply: * CCD ݫt DATALINK ьAS DATALINK C * Y~ CCD ݫt DATALINK C * DY CCD υݫӪ DATALINK C * Mυ𪰬APAwg]wӪ DATALINK C LOB Y CCD ݫӮM LOB M LOB ьpC Wg b 65 Ausqv]AUCG pGъ{MAӐsAъ{|C ъ AS/400 ۫㛤¶ATwjʺg۫`qWX 4 UC AӪpу 69 ʗ 4 MBC 6 . ]wg HBs (Update-anywhere) ѲMѾ pGznъMwg]whF 150 ˬwg]wː]w HBsgAhѝUC DDLAHыA ASN.IBMSNAP_COMPENSATE ݫC CREATE TABLE ASN.IBMSNAP_COMPENSATE ( APPLY_QUAL char(18) NOT NULL, MEMBER SMALLINT, INTENTSEQ CHAR(10) FOR BIT DATA, OPERATION CHAR(1)); ]wg 95 Au]w CD ݫB̮MݫWvG DPREPL.DFT O \sqllib\bin ϓANO \sqllib\java ϓC oOѓTA DPREPL.DFT \sqllib\cc ϓC 128 AOdGzu^{vx}ъu^{vR OA~ъOd˺RCCYHRʛu^{vAh Ѫ|ъOd˺RCC 8 DP_ gR{b Windows 32 tM AIX WC b AIX WR {ATw PATH ʚ sqllib/binϓX{b /usr/local/bin eAH κKM /usr/local/bin/analyze oсC gR{ԡˬ[ъrG CT M ATTC CT=n uь^lݫ n ߬nC rъC YzSwrAw] 7 C AT=n uьъlݫ n ߬nC rъC Yz SwrAw] 7 C dG analyze mydb1 mydb2 f=mydirectory ct=4 at=2 deepcheck q=applyqual1 UCugR{v񺐆srۛTG deepcheck wR{훧ҬR]AUCۛTGCD M UOW RۛTB DB2 for OS/390 ݫ񔐊MY˩`Bwg]wυ RBwgAHwg]w SQL z퓨~C R]AʪAC rъC lightcheck wihUCۛTGASN.IBMSNAP_SUBS_COLS ݫʪ Bwg~BWhB|AѓTLC ۛT YxsMс@˩p HTML XC rM deepcheck rѩC AS/400 ѡx PTF gR{uCouҪ›gʬۛTA PAс@Ûe IBM ANݬ HTML AHUDMwC o AS/400 uAUAݬ PTF (ʪpA~ 5769DP2 NU PTF SF61798 sу)C sWUCDMпMޫΪuv@`G DGSgpUAъ{jF ъlݚь STATUS=2C wg]w]th˿ݫCYni]w@ݫIBzAN n˿ݫwq@ CCD ݫ (ObPwg]w)C ݫisA|DPBJ CCD ݫuъv{ (ʪpA ъ{iӮ|хʛѾ|хo)Cqݫgsυݫъ {|iJjA]Ѫbѽ CCD ݫQsC YnjAʛ CCD ݫъ{ (o|Pgoс Ѿ)C ъ{|J CCD ݫAe\`ъ{Bzʪ ݫˬC tݫwg]w|oсpA CCD ݫЪh ъ{흥JC 9 AS/400 ^{Mъ{ b 178 Auu@̝zvpUьG ziHw]wqСHwqC ыHltAѝlt QZSNDPR RWABb QDPR H~ΫwыC wqAȝ˩۫Х\uOS/400 u@̝z V4R3vC sWUCuʮM]w AS/400 U DB2 DataPropagator wv( 178 )G pG]q˪ۮwvDAhziNw]ѽOq 30 W[ 120C zibC^u@}lu@AziъUC{ÿ ʪblt񛧪 u@w]ѽOG 1. oXUCOA QGPL/QBATCH HыsOѾG CRTDUPOBJ OBJ(QBATCH) FROMLIB(QGPL) OBJTYPE(*CLS) TOLIB(QDPR) NEWOBJ(QZSNDPR 2. sыOѽO (ʪpA 300 )G CHGCLS CLS(QDPR/QZSNDPR) DFTWAIT(300) 3. slt QDPR/QZSNDPR 񬀩|nHъsыOG CHGRTGE SBSD(QDPR/QZSNDPR) SEQNBR(9999) CLS(QDPR/QZSNDPR 194 ¬uъRڃx`vJoylGYzR ڃx`ATwъݫʪڃxʪ DLTRCV(* NO)C b 195 AADDEXITPGM OЅ㔐UCьG ADDEXITPGM EXITPNT(QIBM_QJO_DLT_JRNRCV) FORMAT(DRCV0100) PGM(QDPR/QZSNDREP) PGMNBR(*LOW) CRTEXITPNT(*NO) PGMDTA(65535 10 QSYS) 10 OS/390 ^{Mъ{ b 10 sUCqG DB2 DataPropagator for OS/390 ѲMѾ zѝҐ DB2 for OS/390 у 5BDB2 for OS/390 у 6 DB2 for OS/390 у 7A~ӛ DB2 DataPropagator for OS/390 у 7 (V7)C OS/390 W UNICODE M ASCII sXެk DB2 DataPropagator for OS/390 V7 UNICODE M ASCII sXެkCYn} ossXެkAzѝҐ DB2 for OS/390 V7ABѝԛыӗ DB2 DataPropagator Bυ񊜜ݫAN|bUCU`CLAY zSκѶsXެkAz{sgʜNъ DB2 DataPropagator for OS/390 V7C sXެk YzBCD υݫъPsXެkAziHNg񬀩۫ DCCݫsXެkAݗ`@ CCSID WhGݫ r۫iHъ ASCIIBUNICODE EBCDIC ˢsXCݫ񀬀ʪݫ ѝъPsXެkCSQL zʪݫsXެkѝPCPA zbXъюݫѝPsXެkC Yхݗ`@ CCSID WhAhbsADB2 N|HWê^ SQLCODE -873Cìݫ˼O ASCII UNICODEAzD/q[cˮwCS OaAݓݫsXެkAݗ`oÐWhG * DB2 for OS/390 WυݫiHO EBCDICBASCII UNICODECѪ iHbъѶ DBMS (DB2 tCAҪ DataJoiner D DB2 t C)񼍪PPsXެkݫsC * b DB2 for OS/390 AWAPAWʪ CDBUOWBnOR ݫѝъPsXެkCTO@PAѝTwsX kC * PAWʪݫ (ASN.IBMSNAP_SUBS_xxxx) ѝъP sXެkC * ѪݫiъѶsXެkFLAϑ ASN.IBMSNAP_CRITSEC ݫ Od EBCDICC ]wsXެk YnݫwAݬsXެkAκъ˝сݫ SQLG * HAݬsXެkыsMυݫA{sυݫs XެkCϑz{sݫsXެkeu^{vMuъ{ vAMHN}ުʛu^{vsʛuъ{vC{ sݫsXެkG 1. ъ Reorg ъ{s{sݫC 2. {sݫC 3. wssXެkˡϬݫC 4. ъ Load ъ{Nl۫㩳JsݫC Load M Reorg ъ{ȝ˩ۛTAХ\ DB2 Universal Database for OS/390 Utility Guide and ReferenceC * HAݬsXެkыsݫκ{sݫsXެkC DPCNTL.MVS DB2 for OS/390 sqllib\samples\repl AѪ]t ыݫ CREATE TABLE zCѝO ASCII UNICODE ݫ˿]ʪp ASN.IBMSNAP_REGISTER M ASN.IBMSNAP_PRUNCNTL^A[J CCSID ASCII CCSID UNICODE rApUCdʮьC CREATE TABLE ASN.IBMSNAP_PRUNCNTL ( TARGET_SERVER CHAR( 18) NOT NULL, TARGET_OWNER CHAR( 18) NOT NULL, TARGET_TABLE CHAR( 18) NOT NULL, SYNCHTIME TIMESTAMP, SYNCHPOINT CHAR( 10) FOR BIT DATA, SOURCE_OWNER CHAR( 18) NOT NULL, SOURCE_TABLE CHAR( 18) NOT NULL, SOURCE_VIEW_QUAL SMALLINT NOT NULL, APPLY_QUAL CHAR( 18) NOT NULL, SET_NAME CHAR( 18) NOT NULL, CNTL_SERVER CHAR( 18) NOT NULL, TARGET_STRUCTURE SMALLINT NOT NULL, CNTL_ALIAS CHAR( 8) ) CCSID UNICODE DATA CAPTURE CHANGES IN TSSNAP02; Ynκ{sݫM CD ݫAъ Reorg M Load ъ{C * ݽыsgwg]wAκ̝zuҮʝс SQL A HwAݬsXެkC SQL οҪ CREATE TABLE zAiъ Owgwg]wы CD MυݫCbAݪm[J r CCSID ASCII CCSID UNICODECʪpG CREATE TABLE user1.cdtable1 ( employee_name varchar, employee_age decimal ) CCSID UNICODE; DB2 UDB for OS/390 SQL Reference ]t CCSID ȝ˩ۛTC 11 UNIX ѡx^{Mъ{ b UNIX M Windows W]wu^{vMuъ{vʚ Yzъw]rX¡H~rX½ы۫wAN DB2CODEPAGE ʚ ]˪rXC]w DB2CODEPAGE eorX¡ȝ˩ۛTAХ\ DB2 Administration GuideCu^{vѝbP۫w (^{^ ۫) PrX񛧪CDB2qu^{vʪb@ъ񔶇ʿo u^{vrXCYх]w DB2CODEPAGEADB2 |q@~torX¡C Yzы۫wOъw]rXAhlс@~tu^{v ѼOѓTC 14 ݫc b 339 AK[UCyl 2 STATUS G pGzъ CCD ݫABbъlݬAo "2" A u 8 GDPwvuDGSgpUAъ{ jF ъlݚь STATUS=2vC 15 ^{Mъ{T T ASN0017E G ASN0017E u^{vo{Y퓨~ALkoXѓT~TC`W routineC^X return_codeC sWUC۫㪌T ASN1027SG ASN1027S w˪hjѾ (LOB) C~X C Gwg]wwF˪hjѾ (BLOBBCLOB DBCLOB) Cie\j㼛 10C ъ^Gwg]whLhjѾC T ASN1048E pUьG ASN1048E uъ{v`Cȝ˩۫AХ\ъlG Guъ{v`CbTA wq B C ъ^Gdf͛lݫ APPERRM AHTwuъ{v` С]C A. qъ{ʛ^{Mъ{ b 399 A~X{bdʜ`Aˢdʜ`ʛ^{Mъ{ AOAdʬrXOѓTCdʬbPъ{Ѕ㪐AM ьѪM^{Ѕ㪐C ziHHUϓoъ{M^{dU make G For NT - sqllib\samples\repl For UNIX - sqllib/samples/repl System Monitor Guide and Reference (Lլ) db2ConvMonStream In the Usage Notes, the structure for the snapshot variable datastream type SQLM_ELM_SUBSECTION should be sqlm_subsection. Maximum Database Heap Allocated (db_heap_top) The Maximum Database Heap Allocated data element is not collected by the DB2 Version 7 database manager. Troubleshooting Guide (Lլ) Starting DB2 on Windows 95, Windows 98, and Windows ME When the User Is Not Logged On For a db2start command to be successful in a Windows 95, Windows 98, or Windows Millennium Edition (ME) environment, you must either: * Log on using the Windows logon window or the Microsoft Networking logon window * Issue the db2logon command (see note 1 for information about the db2logon command). In addition, the user ID that is specified either during the logon or for the db2logon command must meet DB2's requirements (see note 2). When the db2start command starts, it first checks to see if a user is logged on. If a user is logged on, the db2start command uses that user's ID. If a user is not logged on, the db2start command checks whether a db2logon command has been run, and, if so, the db2start command uses the user ID that was specified for the db2logon command. If the db2start command cannot find a valid user ID, the command terminates. During the installation of DB2 Universal Database Version 7 on Windows 95, Windows 98, and Windows ME, the installation software, by default, adds a shortcut to the Startup folder that runs the db2start command when the system is booted (see note 1 for more information). If the user of the system has neither logged on nor issued the db2logon command, the db2start command will terminate. If you or your users do not normally log on to Windows or to a network, you can hide the requirement to issue the db2logon command before a db2start command by running commands from a batch file as follows: 1. Create a batch file that issues the db2logon command followed by the db2start.exe command. For example: @echo off db2logon db2local /p:password db2start cls exit 2. Name the batch file db2start.bat, and store it in the /bin directory that is under the drive and path where you installed DB2. You store the batch file in this location to ensure that the operating system can find the path to the batch file. The drive and path where DB2 is installed is stored in the DB2 registry variable DB2PATH. To find the drive and path where you installed DB2, issue the following command: db2set -g db2path Assume that the db2set command returns the value c:\sqllib. In this situation, you would store the batch file as follows: c:\sqllib\bin\db2start.bat 3. To start DB2 when the system is booted, you should run the batch file from a shortcut in the Startup folder. You have two options: * Modify the shortcut that is created by the DB2 installation program to run the batch file instead of db2start.exe. In the preceding example, the shortcut would now run the db2start.bat batch file. The shortcut that is created by DB2 installation program is called DB2 - DB2.lnk, and is located in c:\WINDOWS\Start Menu\Programs\Start\DB2 - DB2.lnk on most systems. * Add your own shortcut to run the batch file, and delete the shortcut that is added by the DB2 installation program. Use the following command to delete the DB2 shortcut: del "C:\WINDOWS\Start Menu\Programs\Startup\DB2 - DB2.lnk" If you decide to use your own shortcut, you should set the close on exit attribute for the shortcut. If you do not set this attribute, the DOS command prompt is left in the task bar even after the db2start command has successfully completed. To prevent the DOS window from being opened during the db2start process, you can create this shortcut (and the DOS window it runs in) set to run minimized. : As an alternative to starting DB2 during the boot of the system, DB2 can be started prior to the running of any application that uses DB2. See note 5 for details. If you use a batch file to issue the db2logon command before the db2start command is run, and your users occasionally log on, the db2start command will continue to work, the only difference being that DB2 will use the user ID of the logged on user. See note 1 for additional details. : 1. The db2logon command simulates a user logon. The format of the db2logon command is: db2logon userid /p:password The user ID that is specified for the command must meet the DB2 naming requirements (see note 2 for more information). If the command is issued without a user ID and password, a window opens to prompt the user for the user ID and password. If the only parameter provided is a user ID, the user is not prompted for a password; under certain conditions a password is required, as described below. The user ID and password values that are set by the db2logon command are only used if the user did not log on using either the Windows logon window or the Microsoft Networking logon window. If the user has logged on, and a db2logon command has been issued, the user ID from the db2logon command is used for all DB2 actions, but the password specified on the db2logon command is ignored When the user has not logged on using the Windows logon window or the Microsoft Networking logon window, the user ID and password that are provided through the db2logon command are used as follows: * The db2start command uses the user ID when it starts, and does not require a password. * In the absence of a high-level qualifier for actions like creating a table, the user ID is used as the high-level qualifier. For example: a. If you issue the following: db2logon db2local b. Then issue the following: create table tab1 The table is created with a high-level qualifier as db2local.tab1. You should use a user ID that is equal to the schema name of your tables and other objects. * When the system acts as client to a server, and the user issues a CONNECT statement without a user ID and password (for example, CONNECT TO TEST) and authentication is set to server, the user ID and password from the db2logon command are used to validate the user at the remote server. If the user connects with an explicit user ID and password (for example, CONNECT TO TEST USER userID USING password), the values that are specified for the CONNECT statement are used. 2. In Version 7, the user ID that is either used to log on or specified for the db2logon command must conform to the following DB2 requirements: * It cannot be any of the following: USERS, ADMINS, GUESTS, PUBLIC, LOCAL, or any SQL reserved word that is listed in the SQL Reference. * It cannot begin with: SQL, SYS or IBM * Characters can include: * A through Z (Windows 95, Windows 98, and Windows ME support case-sensitive user IDs) * 0 through 9 * @, #, or $ 3. You can prevent the creation of the db2start shortcut in the Startup folder during a customized interactive installation, or if you are performing a response file installation and specify the DB2.AUTOSTART=NO option. If you use these options, there is no db2start shortcut in the Startup folder, and you must add your own shortcut to run the db2start.bat file. 4. On Windows 98 and Windows ME an option is available that you can use to specify a user ID that is always logged on when Windows 98 or Windows ME is started. In this situation, the Windows logon window will not appear. If you use this option, a user is logged on and the db2start command will succeed if the user ID meets DB2 requirements (see note 2 for details). If you do not use this option, the user will always be presented with a logon window. If the user cancels out of this window without logging on, the db2start command will fail unless the db2logon command was previously issued, or invoked from the batch file, as described above. 5. If you do not start DB2 during a system boot, DB2 can be started by an application. You can run the db2start.bat file as part of the initialization of applications that use DB2. Using this method, DB2 will only be started when the application that will use it is started. When the user exits the application, a db2stop command can be issued to stop DB2. Your business applications can start DB2 in this way, if DB2 is not started during the system boot. To use the DB2 Synchronizer application or call the synchronization APIs from your application, DB2 must be started if the scripts that are download for execution contain commands that operate either against a local instance or a local database. These commands can be in database scripts, instance scripts, or embedded in operating system (OS) scripts. If an OS script does not contain Command Line Processor commands or DB2 APIs that use an instance or a database, it can be run without DB2 being started. Because it may be difficult to tell in advance what commands will be run from your scripts during the synchronization process, DB2 should normally be started before synchronization begins. If you are calling either the db2sync command or the synchronization APIs from your application, you would start DB2 during the initialization of your application. If your users will be using the DB2 Synchronizer shortcut in the DB2 for Windows folder to start synchronization, the DB2 Synchronization shortcut must be modified to run a db2sync.bat file. The batch file should contain the following commands to ensure that DB2 is running before synchronization begins: @echo off db2start.bat db2sync.exe db2stop.exe cls exit In this example, it is assumed that the db2start.bat file invokes the db2logon and db2start commands as described above. If you decide to start DB2 when the application starts, ensure that the installation of DB2 does not add a shortcut to the Startup folder to start DB2. See note 3 for details. Chapter 1. Good Troubleshooting Practices Problem Analysis and Environment Collection Tool There is a utility that will help you identify some of the information associated with your problem and will collect other relevant information to assist DB2 Customer Support to understand your environment and your problem. Much of what is collected using this utility is discussed in the rest of this chapter. The utility is db2support. Details about the syntax and command line options is found in the Command Reference. The purpose of the utility is to collect environmental data about your client or server machine that is running DB2; and then to collect and package a large portion of the output as browsable XML, HTML, or a compressed file archive. The utility also has an option that allows for the collection of some data from you about the nature of your problem using an interactive question and answer process. This process will help you clarify the problem and also provide information to DB2 Customer Support when you finally contact them regarding your problem. : A thin or runtime client is not able to use this utility. The utility requires that the client have the DB2 engine libraries installed. Collection Outputs The utility produces a compressed collection (single file archive) of important database system information. Included in this archive is an HTML report of the most essential information, which you can use to view the information. By default, db2support will not collect table data, schema (DDL), or logs in order to protect the security and sensitivity of customer data. With some options, the user may elect to include aspects of their schema and data (such as including archived logs). Options that expose database schema or data should be used carefully. When db2support is invoked, a message indicating how sensitive data is dealt with will be displayed. The following are the files to be collected and compressed into a single archive: Collected under all conditions 1. db2diag.log 2. All trap files 3. Lock list files (with -d) 4. Dump files 5. User exit (with -d) 6. Buffer pool and table space (SPCS) control files (with -d) 7. Various system related files 8. Output from various system commands 9. db config (with -d) 10. dbm config files 11. Log File Header file (with -d) 12. Recovery History File 13. db2cli.ini Optionally collected 1. Active log files 2. Contents of db2dump directory (i.e. what was not collected above) 3. Core files (-a for all core file, -r for only the most recent core file) 4. Extended system information (-s) The following files make up the content of the HTML report: Collected under all conditions 1. PMR number, if one exists. (if -n was specified) 2. Operating system and level. (e.g. AIX 4.2.1) 3. DB2 release information. 4. Engine library header information. 5. Detecting 32- or 64-bit 6. DB2 install path information. 7. For EEE report contents of db2nodes.cfg 8. How many CPUs, disks, and how much memory. 9. List of databases on this instance. 10. Registry information, environment, including path & libpath. 11. Disk freespace for current filesystem and inodes for Unix. 12. JDK level. 13. dbm config. 14. Listing of the database recovery history file. 15. 'ls -lR' (or windows equivilant) of the sqllib directory. 16. LIST NODE DIRECTORY 17. LIST ADMIN NODE DIRECTORY 18. LIST DCS DIRECTORY 19. LIST DCS APPLICATIONS EXTENDED 20. List of all installed software. Collected if '-s' is specified 1. Detailed disk information (partition layout, type, LVM information, etc.) 2. Detailed network information 3. Kernel statistics 4. Firmware versions 5. Other platform specific commands Collected if DB2 has been started 1. Client connection state 2. db/dbm config (db cfg require -d option) 3. CLI config 4. Memory pool info (size and consumed). Complete data if -d option used. 5. LIST ACTIVE DATABASES 6. LIST DATALINKS MANAGERS 7. LIST DCS APPLICATIONS Collected if -c has been specified and a connection to the database can be made 1. Number of user tables 2. Approximate size of DB data 3. Database snapshot 4. Application snapshot 5. Buffer pool information 6. LIST APPLICATIONS 7. LIST COMMAND OPTIONS 8. LIST DATABASE DIRECTORY 9. LIST INDOUBT TRANSACTIONS 10. LIST NODEGROUPS 11. LIST NODES 12. LIST ODBC DATA SOURCES 13. LIST PACKAGES/TABLES 14. LIST TABLESPACE CONTAINERS 15. LIST TABLESPACES 16. LIST DRDA IN DOUBT TRANSACTIONS If '-q' is specified, collect the following The interactive question and answer mode is started. With the exception of an optional "describe your problem" question and a small number of requests for customer information, all of the questions will have multiple choice answers from which to select. All of the questions, including follow up questions, and the answers will be collected. In some cases, the utility will ask you to carry out a task and place the results of that task in an additional directory. A small decision tree is used during the interactive mode to determine the questions to ask. These interactive questions assist in determining the category of the problem and based on the category a few other relevant questions may be asked and additional data collected. At the end of the questions, any data that would have been collected in the automatic mode, will also be collected. The answers to all questions are stored in preparation to be sent to service along with any data collected in automatic mode. Viewing detailed_system_info.html If you are running db2support on a non-English installation and are experiencing difficulties properly viewing detailed_system_info.html, you may need to use Internet Explorer version 5 or later with DOS encoding. To change the encoding, select View --> Encoding --> Central European (DOS). If you do not already have the required encoding support, then Internet Explorer prompts you to download the required files from the Microsoft Updates web site. This information does not apply to double-byte languages (Simplified Chinese, Traditional Chinese, Japanese and Korean). Viewing DB2 Support Tool Syntax One Page at a Time To view the syntax for the DB2 Support Tool one page at a time, run the following command: db2support | more Chapter 2. Troubleshooting the DB2 Universal Database Server Under the "Locking and Deadlocks" section, under the "Applications Slow or Appear to Hang" subsection, change the description under "Lock waits or deadlocks are not caused by next key locking" to : Next key locking guarantees Repeatable Read (RR) isolation level by automatically locking the next key for all INSERT and DELETE statements and the next higher key value above the result set for SELECT statements. For UPDATE statements that alter key parts of an index, the original index key is deleted and the new key value is inserted. Next key locking is done on both the key insertion and key deletion. It is required to guarantee ANSI and SQL92 standard RR, and is the DB2 default. Examine snapshot information for the application. If the problem appears to be with next key locking, you can set the DB2_RR_TO_RS option on if none of your applications rely on Repeatable Read (RR) behavior and it is acceptable for scans to skip over uncommitted deletes. When DB2_RR_TO_RS is on, RR behavior cannot be guaranteed for scans on user tables because next key locking is not done during index key insertion and deletion. Catalog tables are not affected by this option. The other change in behavior is that with DB2_RR_TO_RS on, scans will skip over rows that have been deleted but not committed, even though the row may have qualified for the scan. For example, consider the scenario where transaction A deletes the row with column1=10 and transaction B does a scan where column1>8 and column1<12. With DB2_RR_TO_RS off, transaction B will wait for transaction A to commit or rollback. If it rolls back, the row with column1=10 will be included in the result set of transaction B's query. With DB2_RR_TO_RS on, transaction B will not wait for transaction A to commit or rollback. It will immediately receive query results that do not include the deleted row. Do not use this option if you require ANSI and SQL92 standard RR or if you do not want scans to skip uncommitted deletes. Chapter 8. Troubleshooting DB2 Data Links Manager In Version 7 FixPak 2, an SQL1179W warning message is generated by the server when precompiling a source file or binding a bind file without specifying a value for the FEDERATED option. The same message is generated when the source file or bind file includes static SQL references to a nickname. There are two exceptions: * For clients that are at an earlier FixPak than Version 7 FixPak 2 or for downlevel clients, the sqlaprep() API does not report this SQL1179W warning in the message file. The Command Line Processor PRECOMPILE command also does not output the warning in this case. * For clients that are at an earlier FixPak than Version 7 FixPak 2 or for downlevel clients, the sqlabndx API does report this SQL1179W warning in the message file. However, the message file also incorrectly includes an SQL0092N message indicating that no package was created. This is not correct as the package is indeed created. The Command Line Processor BIND command returns the same erroneous warning. Chapter 15. Logged Information Gathering Stack Traceback Information on UNIX-Based Systems The Troubleshooting Guide incorrectly states that to activate stack traceback on every node of a multi-node system, you need to use the db2_all command. Only the db2_call_stack command is needed. Use of db2_all and db2_call_stack together will cause an error. b 64 񩬀ѡxWъ DB2 Universal Database 5 [c LOCKLIST UCۛT[u 2vC Ѕ eW {W LOCKLIST 60000 524288 shmsys:shminfo_shmmax b 64 Solaris @~tW DB2 ъnW[ /etc/system "shmsys:shminfo_shmmax" AHtmj۫w@ъOڝC DB2 for UNIX ͐tJ ϑЅi] "ۚ RAM 90%A񩝞"C oϑ 64 I@C MAb DB2 for UNIX ͐tJ UCϑDGͪWL 4 GB RAM 32 t˿ (b Solaris @~tW`@hi 64 GB)ApG ъN shmmax ]w@j 4 GB rABOъ 32 񩬀 A˫u|r 32 A|y shmmax D`pC 6 Ͻeb 64 񩬀@~tWS LDAP C 32 64 񩬀۫wLkыbP|WCʪpApG@ 32 񩬀۫w AhG db2 create db on pGOq 64 񩬀οoXOA|oo~T "SQL10004C s wϓoс I/O ~C" XML Extender Administration and Programming (Lլ) Release Notes for the IBM DB2 XML Extender can be found on the DB2 XML Web site: http://www.ibm.com/software/data/db2/extenders/xmlext/library.html MQSeries у`pъ DB2 MQSeries ˽πcXÛTP۫wsъ{C у`JIb@tC\APuъwq\ (UDF)vAѪiwb DB2 Universal Database у 7.2 ъaъC ъoÛу\Ai iHjdъ{AqѾq۫㡌xC p۫㡌xъ{ۛTAХ\sJҬu۫㡌x̝z UvAziHq http://www.ibm.com/software/data/db2/udb/winos2unix/support o˫C DB2 MQSeries 㬀wP[c у`p[c DB2 Hъ DB2 MQSeries FunctionC unz\ UC{ANiHq SQL ъ DB2 MQSeries \Co\ӬA \uу`Nv SQL Reference @`C [cPъ DB2 MQSeries Function у{üG 1. bC@ˇۚڥWw MQSeriesC 2. bۚڥWw MQSeries AMIC 3. ъP[c DB2 MQSeries Function ~AYnъ DB2 MQSeries Function ЬoG/q\\Az]ѝbC ˇۚڥWw MQSeries Integrator MQSeries Publish/Subscribe FunctionC MQSeries Integrator ۛTA http://www.ibm.com/software/ts/mqseries/integratorC MQSeries Publish/Subscribe \ӬۛTA𪌀ϖ 3 U http://www.ibm.com/software/ts/mqseries/txppacsC w MQSeries @˿BJOnTwz DB2 AWO_wwF MQSeries у 5.1 P s Fixpak (C)CYzwwу MQSeriesA𩧪U@BJuw MQSeriesy AMIvC DB2 у 7.2 ]A DB2 ъ MQSeries A уCw MQSeries 񂻚{s MQSeries wSwѡxOAibSw ѡxu͐tJvБyAb http://www.ibm.com/software/ts/mqseries/library/manualsCTwݜzi w{ëAn]ww]C̝z{C w MQSeries AMI U˿BJOw MQSeries ъ{ÛT¡ (AMI)C oO MQSeries {]p ¡㔂WAѪЀ̝z{]p@˝MjC DB2 MQSeries Function n¡wCY MQSeries AMI wwbz DB2 AWA𩧪U@ BJ uъ DB2 MQSeries FunctionvCY|хw MQSeries AMIAhziHq DB2 7.2 ЬwMnڿ˪wAq MQSeries Mnڀ http ://www.ibm.com/software/ts/mqseries/txppacsAU AMI уCziHb uϖ 3 - ~㔂WvU AMICF޽K_AМz DB2 MQSeries AMI уCΪb sqllib/cfg ϓCάWO@~t G +----------------------------------+----------------------------------+ | AIX у 4.3 񊺾sу | ma0f_ax.tar.Z | +----------------------------------+----------------------------------+ | HP-UX | ma0f_hp.tar.Z | +----------------------------------+----------------------------------+ | Solaris @~ | ma0f_sol7.tar.Z | | | mq0f_sol26.tar.Z | +----------------------------------+----------------------------------+ | Windows 32 | ma0f_nt.zip | +----------------------------------+----------------------------------+ ݗ` AMI Readme 񘝡zѓ` AMI w{A˔bYwMC ъ DB2 MQSeries Function bBJAzN[cъ DB2 MQSeries Function ۫wC enable_MQFunctions ъ{O@˅uOA|Ѳdw]wAݬ MQSeries AMߪwы DB2 MQSeries \Ӭw][cAHo\Ӝ ъw۫wAT{[cB@ѓ`C 1. w Windows NT Windows 2000A𪌿BJ 5C 2. b UNIX ]wsGYzb UNIX Wъo\AzѝѲN DB2 οʥ (q`O de2inst1) Pj UDF ъ ID (q`O db2fenc1)AsW MQSeries s mqm C DB2 \Ӄn]wHs MQSeriesC 3. b UNIX W]w DB2 ʚGN AMT_DATA_PATH ʚsW DB2 A ЬCьCziHsޔ $INSTHOME/sqllib/profile.envAN AMT_DATA_PATH sW DB2ENVLISTC]iъ db2set OC 4. b UNIX WAsʛ۫wοGYnʚ㚌сAѝsʛ ۫wοC 5. b UNIX WNϓ $INSTHOME/sqllib/cfgAb Windows WNϓ %DB2PATH%/cfgC 6. O enable_MQFunctions H[cъ DB2 MQSeries \Ӭ۫wC b DB2 UDB EEE A„sϩ`IWуBJCХ\"enable_ MQFunctions"AHoO҃CUC@@٢dCb\ ANъw۫w[cC 7. YnъuROBzvo\Abzswъ۫wA oXUCOG values DB2MQ.MQSEND('a test') values DB2MQ.MQRECEIVE() @ːzNÛeT "a test" DB2MQ_DEFAULT_Q CA˝G˽h N^C : enable_MQFunctions GANыw] MQSeries CNы MQSeries C̝z{ DB2MQ_DEFAULT_MQM w]C DB2MQ_DEFAULT_ QCY amt.xmlBamthost.xml amt.dtdwsb AMT_DATA_PATH VϓANыoÔCY amthost.xml sbAB]t connectionDB2MQ wqAh|NsWAݩۛTCˬ άуNxs DB2MQSAVE.amthost.xmlC MQSeries ÛT DB2 MQSeries \TÛTʽG۫㇤BoG/q\ (p/s) nD/^ (r/r)C H۫㇤ÛeT|Ûe@ϬaABw^Cb p/s ʽA@ hѼNTÛeGA{AeT@hъCnD/^ P۫㇤AÛew^C Tc MQSeries у|nDѶÛeTScC Ѫ~p MQSeries Integrator (MQSI)AN|H CBCOBOL XML r TCb MQSI cTOЛTxswwqCXML Tq` @˪TcABi]zLxswˀ̝zCT]iӼOS cAnъ{XˡլRπcTeCoTOю cA]NOAѪъ񩝞mTwwjT񬀑C uMQSeries UFvАoюcTCzLYs\AN XML T DB2 XML XRC MQSeries \[ MQSeries \› DB2 UDB у 7.2 Ai SQL z]AÛT@~C oьiъHѶyх…gъ{AʪpAъѶ۫w ¡ CBJavaBSQLCUCьʪdʺb SQL CiHъʪ AqL{]pyѿъ SQLCWzʪ MQSeries ÛTwC MQSeries \Ӭȝ˩ۛTAХ\uу`Nv SQL Reference @ `C bу[cAMQSeries AObP DB2 @_۫wAC MQSeries \Ӫwb DB2WAЇ MQSeries AsvC DB2 q ibis DB2 Server ѶWCh˜qiPzL۫ws MQSeries \CzLЬ\ADB2 qib SQL z񀛧ÛT@~C oÛT@~i DB2 ъ{bѪqHAPL MQSeries ъ{ qHC enable_MQFunctions OOъ˜ъ MQSeries \Ӭ DB2 ۫wCѪN ыw][cAqъ{|ъ˼[cAn̝z@Cp AХ\"enable_MQFunctions"P"disable_MQFunctions"C w][cД ъ{]pv@˺͐tʛެkA@˺}o¡CYnAiW [[cL\C d 1GYnъw][cÛeTASQL zpUG VALUES DB2MQ.MQSEND('simple message') o|NT simple message Ûe MQSeries C̝z{w][cw CC MQSeries uъ{ÛT¡ (AMI)vAbÛT훉񊽳wü훉Ûe wqAНMjCoîwqOdb~xswAъ AMI ̝zuҿˀ̝zCoi AMI ъ{eoi@CDB2 Ь MQSeries \ӼOH AMI MQSeries ¡CAMI ~[cъA˔ uAMI xswvAHxs[cۛTCw][c]A MQSeries AMI xsw[cA Hъ DB2C MQSeries AMI ԡDnAA{IhAQӃ DB2 MQSeries \ CA{IO̓ޝΘIAYTiÛeIC b AMI xsw AC@ˬA{IOH MQSeries CW񊪯C̝z{ˮwqChw qA{퓴~AъwÛT@~CDnA{~]A TuѲº񊽨CЇw]A{IhwqABioi ъAHi@B㔐ъ{Cd 1 iHUCުgAHTaww]A {IhWG d 2G VALUES DB2MQ.MQSEND('DB2.DEFAULT.SERVICE', 'DB2.DEFAULT.POLICY', 'simple message') CiЪA@h˔ъ{AA˪C񊔐ъ{Y`n˪A Cb\h[cAhCNQwqPъ{ϬC]o ˝zAbi MQSeries nDAg`wqPA{IOnCb UCd񪐃G d 3G VALUES DB2MQ.MQSEND('ODS_Input', 'simple message') : bdAхwhANъw]hC MQSeries ЛT@~۫w@~OAHb@u@XA@Q O@ѵC Unix Windows W MQSeries \ӡу\C ъÛe㫂A VARCHAR jTμO 4000 ˪rCbÛe CLOB TAjμO 1 MBCo]Oъ MQPublish G TTjpWC bъ CLOB TP VARCHAR TAnPCq`AMQ 㬀 CLOB у|ъPуPykC@tOOWbBr CLOBCʪpAMQREAD CLOB Ѯ MQREADCLOBCpoÿ㬀ȝ˪CьA Х\"CLOB data now supported in MQSeries functions"C ~X zibuMQSeries ъ{ÛT¡Uv B A MQSeries \ ê^^XC ъkۛU MQSeries Function iъjdۛUCу`NQ@ЇM A]AuуÛTvBuъ{svu۫ѼvC уÛT ݮʪ۫wъ{sP DB2 AA|oс MQSeries DB2 \ T񺐆уCqiӼO۫wAу񔗝bC bۛdAq A Is MQSEND \AÛeъwqw]A{ mC MQSeries \ӔH|b۫wA DB2 񀛧CyAq B Is MQRECEIVE \Aw]A{wqC񺐆OOTA Nê^qCPA@~ MQSeries \ DB2 C ۫wqiHъ\hު˿ъÛTCÛTY@ъkpUG * ۫㪼› -- H˪@hiPۛT񺺊ۛTCۛT iӼO~ъ{p SAPAoiъ{Co۫iqC Axsb۫wݫAHi@BBzRC * u@te -- u@nDѼCAмPъ{h˫οʪ@ъC οʐ㺗@u@AѪ|qCTA]tnu@n DCъ̐NAh˫οiH@ъxsnD񺐵@CNݬu@tC * ъ{H -- bX{êX@pATq`ъ˿GCo Ti]tu@nOnDCq`AoϽHOVF]NO A_lT@޿w^CХ\"Request/Reply qH"AHo ˩ۛTC * ъ{q -- qPHA۫ql{ÛeXABw^C OAqq`]twoс~Ѿ۫C "oG/q\" Oq i񺺊C UCۛdʘXRFWzۛdAHJÛTC]NOAT b A P B ÛeC BJºêpUG 1. DB2 q MQSEND IsAwwwqυA{AHNݥ B CC 2. MQSeries DB2 \ӛۃ MQSeries @~HÛeTCb A W MQSeries ATOANÛeA{Iwq񊥸 A { MQSeries [cʮwqϬaC AMwoO B WCC M Ѫ|NTÛe B MQSeries AAbnzqa C 3. B W MQSeries A˪ A 񺪰ATANm b B ϬaCC 4. B W MQSeries qnDCOOTC ÛeT ъ MQSENDADB2 ъoiinÛe۫AnÛemAn eCb~Aoq`s "Send and Forget"AьÛeunÛeT A˿ MQSeries eqHwOATOTiFϬaCUCd |@C d 4JYnъh highPriority NъwqrÛeA{I myPlaceG VALUES DB2MQ.MQSEND('myplace','highPriority','test') boAh highPriority AMI xswʮwqhAN MQSeries uѲ ºÐ]whA]iӢҿLA{~AʪpC Tei SQL ѶoX񊿤ъw۫㝞X˪Co]A _\BBljӽCʪpA@ݫ EMPLOYEEA VARCHAR LASTNAMEBFIRSTNAME DEPARTMENTAwC@ DEPARTMENT 5LGA 񬀡u Ûe]tۛTTAziUCG d 5G SELECT DB2MQ.MQSEND(LASTNAME || ' ' || FIRSTNAME || ' ' || DEPARTMENT) FROM EMPLOYEE WHERE DEPARTMENT = '5LGA' Yݫ]@˺Ҭ AGE AѪi]|QJApUьG d 6G SELECT DB2MQ.MQSEND (LASTNAME || ' ' || FIRSTNAME || ' ' || DEPARTMENT|| ' ' || char(AGE)) FROM EMPLOYEE WHERE DEPARTMENT = '5LGA' pGݫ EMPLOYEE @˖ CLOB RESUME ˿S AGE Ah| Ûe@hTAt DEPARTMENT 5LGA C@uۛTApUьG d 7G SELECT DB2MQ.MQSEND (clob(LASTNAME) || ' ' || clob(FIRSTNAME) || ' ' || clob(DEPARTMENT) || ' ' || RESUME)) FROM EMPLOYEE WHERE DEPARTMENT = '5LGA' d 8G AUCdʚьpъѶ SQL ьˡlсTeCНG ˬݫ DEPTAt VARCHAR DEPT_NO P DEPT_NAMEAiÛetu LASTNAME DEPT_NAME TG d 8G SELECT DB2MQ.MQSEND(e.LASTNAME || ' ' || d.DEPTNAME) FROM EMPLOYEE e, DEPT d WHERE e.DEPARTMENT = d.DEPTNAME ^T MQSeries DB2 \iTCPPBAbê^ C񺐆OOTAqCA˜@~|TqC Cъ@~˘^TA„iH^@A˿ъ@~˘^T Aih^PTCUCd|@G d 8G VALUES DB2MQ.MQREAD() dʿъA{hw]~Aê^ VARCHAR rA˪r]tw]A {wqC񺐆OOTCnG`NYSiКT ANê^@ NULL C@~|CC d 9G VALUES DB2MQ.MQRECEIVE('Employee_Changes') Wzdʚьpъw]hANTq Employee_Changes A{wq C񺐆OOC DB2 @˽D`O\AOqъwq ( DB2 Ь) \Aсݫ OC ziH}oݫ\ACei@ DB2 ݫCUCdʃ oːG d 10G SELECT t.* FROM table ( DB2MQ.MQREADALL()) t dê^@ݫAЮʪw]A{wq񺪯CʪT񊪐oÛT yz۫ʝCê^ݫc񺺇ҮwqOwqAh@ |MTeAlh]tyz۫CYunê^TAis…gdG d 11G SELECT t.MSG FROM table (DB2MQ.MQREADALL()) t ݫ\ê^ݫP۫w^ݫPCoьziHъsxެk ъݫCʪpAziHX@ݫPt@ݫeApԪC񬀛T qG d 12G SELECT t.MSG, e.LASTNAME FROM table (DB2MQ.MQREADALL() ) t, EMPLOYEE e WHERE t.MSG = e.LASTNAME d 13G SELECT COUNT(*) FROM table (DB2MQ.MQREADALL()) t ziHzLݫ\ӿ˽ыAHݫOCCʪpAUC dʐzLA{ NEW_EMPLOYEES ʛˬCA˽ыW NEW_EMP G d 14G CREATE VIEW NEW_EMP (msg) AS SELECT t.msg FROM table (DB2MQ.MQREADALL()) t bοA„H]tҡ˛T@ˮwqCYTO[ cAʪp]tTwάԡˑAhѪ|VeHъ DB2 \ANT լRԬCʪpAYzDÛeSݪCT]t@ 18 mA߽hO@ 18 񩬀WrAhziHwq@A]tC@ ˺OAʪpG d 15G CREATE VIEW NEW_EMP2 AS SELECT left(t.msg,18) AS LNAME, right(t.msg,18) AS FNAME FROM table(DB2MQ.MQREADALL()) t uDB2 xs{ýϩmvsSuMQSeries UFvAiъ˽ыs DB2 ݫ\ANwTcMC Aq`nN@h˛Texsb۫wCoiъ SQL \ӿ AH̺@xsTeCdiӼOG d 16G INSERT INTO MESSAGES SELECT t.msg FROM table (DB2MQ.MQRECEIVEALL()) t ]t VARCHAR(2000) @ݫ MESSAGESAWzz|qw]A {CANTJݫC i·󪇺̐NAH[\psxϖC ъ{퇴ъ{s ъ{ҪXO\hпMޫά@񩻔CΜNRъ{ҪX{s [cAuNs}oъ{ҪX{sAq`|› ltP›X@~AHcҬu@C MQSeries q`QҪXъ {уuCibjѸwBnyєsAMQSeries ѵ sъ{P›XެkC `NQΐѸъ{ҪXۛpH DB2 ˿ъѪC]DD݅s xAuъ{ҪXvsxQWVFu@dC]AI„bԡ˘ DDGRequest/Reply qHA MQSeries Integrator Publish/ SubscribeC Request/Reply qH uRequest/Reply (R/R)vqHެkO‡M̐NA@˔ъ{iVt@˔ ъ{nDAC@@ެkAOnD{NTÛenD Yu@A{C@чu@wAД{iMwNG ( T{) ê^nDCъWzуÛT̐NANӐsÛenDPA {^CDnD{b~eAѲѽ^A_hYåѝ ъXC@˪^nDCMQSeries j{}oыoA O@˼ IDAѵBTC ݪ\hެkiЪъAެkOnDъw ID ьTAʪpUCьG d 17G DB2MQ.MQSEND ('myRequester','myPolicy','SendStatus:cust1','Req1') zNΛЅ Req1 sWWz MQSEND zAHьnD IDC YnSwnD^Aъ MQRECEIVE zAa X ID BньA{ʮwq@hTApUьG d 18G DB2MQ.MQRECEIVE('myReceiver','myPolicy','Req1') pGAnDъ{uABnDb^ÛeeoXWz MQRECEIVEAh|P ID TC YnA{nD񊼍 IDAъPUCzG d 19G SELECT msg, correlid FROM table (DB2MQ.MQRECEIVEALL('aServiceProvider', 'myPolicy',1)) t o|ê^A{ aServiceProvider @ˡnDT񊼍 IDC @чFA{AѪ|N^TÛe aReauester CCbo AAnD{|L@~CWAOʛ_lA{nD|b ]w^CpPoъ{hOAѝoi{ˀ̝zFnD {ѝ^𬀜pC oϫWыDPBBzuIAOnD{AД{OюWыaC oiъAXAъ{„|_asA]iъժVA hnD^|bBz{ýeѲE›_C o›Xڐq`ъ۫㡌x AHwas۫㡌x@~۫xsC oG/q\ ۫X~ ъ{ҪXt@@هۛdAO@ъ{qLъ{ ѾC zieaNTÛeCA˪Ct@˔ъ{퀉CT eiHOъwqrAiHq۫w˅…gCTOn ъ MQSEND \ӿÛeTCݐoTnPÛeh˜Ai Hъ MQSeries AMI ueMvC eMOъ AMI ̝zuҿˮwqCeM]t˺OA{MCÛe eMTA|ӃMʮwqC@ˬA{Cw@ìA {@C˛TAoOSOъ\CUCdʚьÛeT eM interestedPartiesG d 20G DB2MQ.MQSEND('interestedParties','information of general interest'); ݻSݬA{픐TnhAhn Publish/Subscribe OC Publish/Subscribe tq`@iҬBwюA\hqi bnOAHqhѼTC YnOAiъ MQPublish ¡AP MQSeries Integrator MQ Series Publish/Subscribe ӐsC MQPublish iъъawPTDDCDDiъߺMa wnTCBJºêpUG 1. MQSeries ̝z[c MQSeries Integrator oG/q\\C 2. Pъ{b MQSI [cʮwqq\Iq\Aъaw DDCC@ъߓDDAiHQъ MQSeries Integrator V2 Heq\̐NCnG`NAA{WNݬC wqъC 3. DB2 ъ{ѼA{I Weather TC TXЫO SleetAB DD AustinA]qъAi Austin ЫO SleetC 4. ۃѼTO DB2 Ь MQSeries \ӿːBzCъA{ W WeatherANTÛe MQSeries IntegratorC 5. MQSI q Weather A{TA MQSI [cwqѶBz{A MwNqCM MQSI |NTӃXýhъߪCC 6. wq\ Weather A{Ab Austin nOnъ{ANbA {T SleetC Ynъʪw] NULL DDѼ۫AziъUCzG d 21G SELECT DB2MQ.MQPUBLISH (LASTNAME || ' ' || FIRSTNAME || ' ' || DEPARTMENT|| ' ' ||char(AGE)) FROM EMPLOYEE WHERE DEPARTMENT = '5LGA' ҬwʪЅ㿖TA„]t LASTNAMEAziӪpUьG d 22G SELECT DB2MQ.MQPUBLISH('HR_INFO_PUB', 'SPECIAL_POLICY', LASTNAME, 'ALL_EMP:5LGA', 'MANAGER') FROM EMPLOYEE WHERE DEPARTMENT = '5LGA' zъ SPECIAL_POLICY A{ANTѼ HR_INFO_PUB GA {CTXÛeO MANAGER DDCDDrۃiwъuGvs hDDCbdAъoԡDDiъnO ALL_EMP unO 5LGAAHoÛTC YnѼTAzѝѲNznnObTAT]twDD XTÛeъ߬A{WCnG`N AMI ъ߬A{ wqt̝ztA{A{Ct̝ztA{Oъ ߃PoѼ/q\t̝ztqHުA˜A{OXq\nDN eaC 7UCzbDD ALL_EMP nOnC d 23G DB2MQ.MQSUBSCRIBE('aSubscriber', 'ALL_EMP') @чq\Fъ{AHDD ALL_EMP ѼTANӃъ߬A{ʮw qA{C@˔ъ{iHhq\CYnoXz q\TAziHъѶìT^\CʪpAYъ߬A{ aSubscriber NA{wq aSubscriberReceiverA˽DUCz AhN|D}aa@˛TG d 24G DB2MQ.MQREAD('aSubscriberReceiver') YnMwHUnѼTPDDAziHъ@Ϭݫ\CUCz | aSubscriberReceiver e˛TAьTPDDG d 25G SELECT t.msg, t.topic FROM table (DB2MQ.MQRECEIVEALL('aSubscriberReceiver',5)) t YnHDD ALL_EMP ˚ʪTAziHvT SQL OAoXG d 26G SELECT t.msg FROM table (DB2MQ.MQREADALL('aSubscriberReceiver')) t WHERE t.topic = 'ALL_EMP' : nOzѝߩСY MQRECEIVEALL ъA˽Dъҡ˪CAh DuÛT|ѼDD ALL_EMPCoO]ݫ\ӽA~ъ C ݜzAq\SDDAzѝъzATaq\AʪpG d 27G DB2MQ.MQUNSUBSCRIBE('aSubscriber', 'ALL_EMP') @чoXzAoG/q\t̝ztNAÛeXq\TC G ۫wÛTt@ˡn̐NOѼCъ DB2 񬀑oAzi HѼTA@oIs@ѸCݿL۫Ѽ̐Nsb Ao{훏ެki̝z}oЪaπcTeAuaw qo@C`NAѶoъAѝIWvPуO ъCUCdʃopъ MQSeries DB2 \C UCdʚьCœъsuAѼTOeCѶq\ HR_INFO_PUB A{b NEW_EMP nOnъъ{AN|@TA] AC@suڗBWC d 28G CREATE TRIGGER new_employee AFTER INSERT ON employee REFERENCING NEW AS n FOR EACH ROW MODE DB2SQL VALUES DB2MQ.MQPUBLISH('HR_INFO_PUB&', 'NEW_EMP', current date || ' ' || LASTNAME || ' ' || DEPARTMENT) enable_MQFunctions enable_MQFunctions ъw۫w DB2 MQSeries \A DB2 MQSeries \i HAݪaCYхwP[c MQSeries M MQSeries AMIAON| C v UC@G * sysadm * dbadm * Y\ӬtTϪWsbAh IMPLICIT_SCHEMA b۫ wWC * YϪW DB2MQ sbAh CREATEIN MъvbWC Oyk >>-enable_MQFunctions---n--database---u--userid---p--password---> >--+-------+--+------------+----------------------------------->< '-force-' '-noValidate-' OЅ -n database wnъ۫wWC -u userid wъ ID Hs۫wC -p password wъ ID qXC -force wswo{iQC -noValidate w DB2 MQSeries \ӬʜNC d bUCdAwы DB2MQ \Cъsu۫w SAMPLECw ъw] DB2MQC enable_MQFunctions -n sample -u user1 -p password1 ъk`N DB2 MQ \ӪbOы DB2MQ UC OeG * TwwwF MQ AMIAB MQSeries уO 5.1 уC * Twwwqʚ $AMT_DATA_PATHC * Nϓ DB2PATH cfg ϓC b UNIX WG * ъ db2setAN AMT_DATA_PATH sW DB2ENVLISTC * TwP UDF ъb߼O mqm sC * TwnIsOъO mqm sC : MQSeries 5.2 ATX 4.2C disable_MQFunctions disable_MQFunctions ъw۫w DB2 MQSeries \C v UC@G * sysadm * dbadm * Y\ӬtTϪWsbAh IMPLICIT_SCHEMA b۫ wWC * YϪW DB2MQ sbAh CREATEIN MъvbWC Oyk >>-disable_MQFunctions---n--database---u--userid----------------> >---p--password------------------------------------------------>< OЅ -n database w۫wWC -u userid wъːs۫wъ IDC -p password wъ ID qXC d bUCdAwъ۫w SAMPLE DB2MQ \C disable_MQFunctions -n sample -u user1 -p password1 IV g ̝zu ueѪ]m ъ Linux WBI| YObt Glibc 2.2.x Linux AzѝѲъBI|AM~ӛ uvѬ DB2 Java GUI uCYnъBI|A𛧪UCB JAN LD_ASSUME_KERNEL ʚ]w 2.2.5G bash$ export LD_ASSUME_KERNEL=2.2.5 Linux ʃnSw Java h Linux ъbՔ񛧪 DB2 Java GUI u (puv) A nSw JDK hCʪpARed Hat Linux 6.2J/7J/7.1/7.2 ъъ IBMJava118-SDK-1.1.8-2.0.i386.rpm hC sV_miz_m۫w bъ GUI uҗ_m۫wAsV_m|z_m۫wC@ч zFA_m@~K|bIʛAB۫w|iJ_mm񬀬 ACYz߿˿@Abzt@_meA۫wNLkъC ̝z DB2 Server for VSE & VM AO DB2 Universal Database у 7 uvWj DB2 A for VSE M VM ۫wCuvʪ VSE M VM ۫wѾ DB2 A C P]ыBBspMssOC Mssnxs{A˩˔xs{Û VSE M VM DqW DB2 AC xs{МʗAAъ VSE M VM U DB2 A VSE M VM SC ҪXe\ъ̝z DB2AL DB2 A@ѡxCVSE M VM Ѿ DB2 AьbDAF DB2 Universal Database ѾC ѾA|Is̝zoìѾ@Mъ{C dA ъiHCьSO۫wA@˻̿N񺡽C ъ]i HCь۫wݫAspAwqݫgC [cAb VSE M VM Ѿ DB2 A̝z@~ۛTA DB2 Connect User's GuidewP[cR۫C Java 1.2 ъ Java 1.2 񬀘VAiHVyApȺByMB ˃yC uiъ Windows NT ѡxC ٖЮMъ Java 1.2AniwG 1. JDK 1.2.2 b DB2 UDB CD DB2\bidi\NT ϓUC ibm-inst-n122p-win32-x86.exe Ow{A ibm-jdk-n122p-win32-x86.exe O JDK eCNԡ˔΢swWϓAMߜqϓw {C 2. NѪwb \java\Java12 UA O DB2 w|C 3. JDK/JRE wьAn JDK/JRE t VMC Java 1.2 w\AHѓ`ުʛ񋫂|ъ Java 1.2C 񯿤ъ Java 1.2Ab \java\Java12 UЛw JDK/JREA \java\Java12 ϓWrC : nVc \java\Java12 M \Java12C \Java12 O DB2 w@ѸAB]A Java 1.2 JDBC C b Windows @~tUъuWuL«|v~ ъuWAzi|Jo~GuL«|vCpGz wFs Web s Web ssATw HTML M HTM ѾM LsXC Х\DDu}ʔΫ{ʛvC ͐tL bYÃyAw UNIX tP OS/2 WuvAú͐t] ^LkB@Cъㇽ˓C OS/2 tU Java ѝwb HPFS 㬀WC b Windows @~t񺝺ڃxwu@uήsv~ b DB2 Universal Database for Windows NT WAb}ʝڃx˔b uScript vʽыu@˫Aoсuήsv~C u@ AьC YuScript vыu@t START OAK|oсo CFκKoAbժMu@Aъ START/WAIT OA nъ START OC hmss hmssbу 7 uv\AυοʬуʡC uvs\ӜυοA̓nу 7Cbу 6 h mss\AbυοAbӛѪC DB2 for OS/390 QъOS/390 DB2 UDB ˀ̝zvъ{ъC OS/390 DB2 UDBAъ{OWыºûS񩻔AbѪQ DB2 ̝z eAѝvMwbC ۫w DB2 for OS/390 ltA|wq "CC390" ۫wA@ 񋬀Cnκ۫wC MbϓۛT@~ۛTASSO DB2 for OS/390 у 7.1AOAѾ OS/390 у 7.1 DB2 C h DB2 for OS/390 у 6 SݿAM DB2 for OS/390 у 7.1 C DB2 for OS/390 у 7.1 SݿAbϓSуWC b[c DB2 for OS/390 у 7.1 ltAʪˬуѾsvC sMъ Generate DDL Aw Generate DDL G * у 5Aъ DB2 for OS/390 у 5 ˪w DB2AdminC * у 6Awp{]p[j\A DB2 for OS/390 у 7.1 ̝zS˿їNp PTF C * у 7.1AGenerate DDL 㼛Wыw DB2 for OS/390 у 7.1 ̝zS@ѸC qsxs{ýϩmAbʛ DB2 UDB 񋫂Aѝiw CѪO DB2 ъ{}oq@ѸC bu@ OS/390 lts DB2A𓴥ъq[cU{uC 1. buv¡Aw[cP۫wsusC 2. buqHwv¡AAݬqHۛTC 3. bu۫wv¡A۫wWwltWC 4. bu`Iv¡A[c`I (ъ)񑓴C 5. b@~tuMVS/ESA, OS/390vC 6. @UAH[cC YnzLhDˢs DB2 for OS/390 ltAݗ`WzhDBJ 1-6CMG 1. bqAʛC 2. butv۫㺿W@UㇽkAAsWC 3. busWtvAbtWJhDWC 4. bοʑJ DB2DAS00C 5. w TCP/IP qHw (buqHwvЅ㩆)AbDqWw hDDqWC 6. bA{WJ 523C 7. @UTwsWtC ziHbt۫㺿UsWhDC 8. i}hDWC 9. buοv۫㺿W@UㇽkAAsWC 10. busWοvA@U_sACXhDWiъοC pG hD Windows NT tAh|bο DB2 Us DB2 for OS/390 l tC 11. οC ο|±gqHwЅC 12. @UTwsWοC 13. }ʫοʩ۫㺿AiH~sWοC 14. i}οC 15. b۫w۫㺿W@UㇽkAAsWC 16. @U_sAьhDWу۫wC pGznbusW۫wv sW DB2 ltAu۫wWvJltWC G Jlt (O۫w) уOWC 17. @UTwC {bAzwg\absWltC}ʩ۫wA|ь DB2 for OS/390 ltC " 390" `@˼qXG QъOS/390 DB2 UDB ˀ̝zvъ{ъC OS/390 DB2 UDBAъ{OWыºûS񩻔AbѪQ DB2 ̝z eAѝvMwbC `G OS/390 uDB2 viz̝zwv IBM DB2 ъ{ъCpG ъ{O˺Oq~ѾAhѝovwbzAH KuDB2 v̝zC OS/390 ѝnѓ{ N APAR PQ36382 ъ DB2 for OS/390 у 5 M DB2 for OS/390 у 6 390 ߻ӻSAъ DB2 UDB 񋬮у 7 ˛oltъ{C ъ APAR UC FMIDG DB2 for OS/390 Version 5 390 Enablement: FMID JDB551D DB2 for OS/390 Version 6 390 Enablement: FMID JDB661D uыhvϬ "<<" ">>" swuыhvhC DB2 񋬀 bu͐tJv@Ьu񋬀wP[cv@AuЩۛTv @`|iDzbNuvъ applet YoсDApqO 񡽐]zqs CLASSPATHC у`|pqezO sA oхМʛsOC Ynʛ Internet ExplorerA J start iexploreAM߽ Enter C Ynʛ NetscapeAJ start netscapeAM߽ Enter C oýOY]sw]bz PATH C p YMAN[Jz PATH AO񙗽swϓAsoX start OC UNIX t񋬀 pGzLkb UNIX tʛAh]w JAVA_HOME ʚ㽳V Java eG * Java wb /usr/jdk118A]w JAVA_HOME /usr/jdk118C * shBkshBbash shellG X JAVA_HOME=/usr/jdk118. * csh tcsh shellG setenv JAVA_HOME /usr/jdk118 OS/2 iӬ Infopop D pGzOb OS/2 WAъЬR 1024x768 256 AъF WorkPlace Shell Palette AwarenessAhWX{Ϭ Infopop |H˜ ժrьb˜ԡIUC ѓDAь]w 256 HWA 񯿤ъ Workplace Shell Palette AwarenessC jdk11_path [cЅ㬀 bAJDK 1.1 w| (jdk11_path) [cЅ㬀AlD ъUF@C uъvUҬCьG * уMq۫wA * q * Ҫуq۫wA * Ҫуq񔐊۫wA * ҪуqP۫wA ъuScript vuڃxvoс Solaris t~ (SQL10012N) buScript vuڃxv Solaris tAi|oсUC ~G SQL10012N - ݩJwΫw "/udbprod/db2as/sqllib/function/unfenced/ db2scdar!ScheduleInfoOpenScan"ADw@~t~C SQLSTATE=42724C oOЮ Solaris 񬀓~ʥPCzuъUCΩ{A YiѓDG 105490-06 (107733 makes 105490 obsolete) for Solaris Operating Environment 2.6 DPREPL.DFT ά buvAuuҐ]wvOуugv¬BJ 5d gDG NΔxsuvu@ϓ (ʪpASQLLIB\BIN)A p@AtiHъ@w]C gG NΔxsuvu@ϓ (SQLLIB\CC)A p@AtiHъ@w]C ʛh˜ applet zӪb@xWPʛ@HW appletCoAъʪ sʛ appletC H Applet uW uvOH applet ު훧AF1 uӛbҪ Infopop \Ӭ OуB@C ziHbUCѾ F1 AsX InfopopG * DB2 Universal Database for OS/390 * F WzH~uvѾLkъ F1 sXC Ynь ѪѾAъuvsuvU\ӬC b Applet ʪ (Windows 95) U Ywъ ID MKXLAKLk}uScript vC nJu vATwъ ID MKXO_C ъjqdG ޽Kъсê^jqC㬀dC˥AXъъˇwۃê^C Ciê^HdpHUpC㬀dAUCԡ˛DG 1. nOh~ӿoGC 2. njqqO~ӽOsGC FoːBz[KQADB2 NjqG›񔐊\hqCH@@q ު^ьdGC GpUG 1. ݼd@qiHAPw^ХlqA|͚ьC 2. ݪbѶwWq„xsdG@qA|͜qO ڃDC O񬀼dGCG 1. }uuҐ]wvOуu@v¡C 2. bjqAG * deAiudevьGCCbJ wG›qjp (C)C * ROAiuROvudGv¡WьGCC bJ񽳮wG›qjp (C)C ݿъudevuROvudGv¡WdGA OC㑵ьOdbO񬀼dCC|jj] wC@UU@BA^G›U@qCU@BD@ъAьz wFG›C RO {bROѵiHٖАzr {buROvuѵviHٖuuҐ]wv񽳮wuzv rCpGSwuzvrAh|ъw]rC ۛT ѓ Java dѾ ۛTuJava dvѾ java dʿC PluginEx.Java qOsCpuXRvsۛTAХ\ Java d README GPluginEx.java P"Example for Extending Control Center"C b Windows ѡxWAziHb x:\sqllib\samples\java README P PluginEx.java A x Ow DB2 C b UNIX WAziHb /u/db2inst1/sqllib/samples/java README P PluginEx.java A /u/db2inst1 Nݪw DB2 ϓC b Windows @~tUuL«|v~ ъۛTAz|o{pU~GuL«|vC pGzwFs Web s Web ssATw HTML M HTM ѾMLs XC Х\DDu}ʔΫ{ʛvC Netscape w}ʫAb Netscape Navigator }~ Web (UNIX t ) pGwg} Netscape NavigatorAьу DB2 HTML Ѿ~퀶A quۛTv}~퀶NP Netscape oс~C ~| "Netscape W ήϓ"C YnпMo˛DAb}~퀶eA}ʬ Netscape sC Netscape Nsʛ_l~퀶C `NAQъw}ʬ Netscape }у DB2 HTML Ѿ|oсo˓~C ʛuۛTvD bYÿtWAYzъu}l\ӬvBu@˿BJv db2icOˮIs uۛTvAʛt|D`CC YJo˛DAʛuvAM ߓ --> ۛTC xs{ýϩm z/OS OS/390 Java xs{ b FixPak 7 Auxs{ýϩmvsWFUC[j\AъHϩm DB2 for z/OS OS/390 у 7 Бª Java xs{G * Actual Cost * [j~TBz * LINUX/390 A߻ * bxs{ÀϪWъ @ bѶу z/OS OS/390 sª Java xs{ABLk ъuxs{ýϩmv˽ыCDB2 ʪуOpC DG * p DB2 for z/OS OS/390 WѲMѾw@~ۛTAХ\ APAR PQ52329C * u›X IDvѝXzb z/OS OS/390 Ws JDBC X{ʿъ IDC * κ DB2SPB.ini AH]tUCnG SPOPTION_WLM_JAVA_ENVIRONMENT = WLMENVJ SPOPTION_JAVAPROC_BUILDER = SYSPROC.DSNTJSPP SPOPTION_BIND_OPTIONS_JAVA = ACT(REP) SPOPTION_COLLIDJ = DSNJDBC Ynъuxs{ýϩmv˽ы z/OS OS/390 Java xs{A UCBJG 1. }uJ Java xs{vFG a. bMΥc z/OS OS/390 ۫wsuUAHㇽk@Ux s{é۫㺿C b. @UJ -> ъFJ Java xs{CYi}ʀFC 2. w z/OS OS/390 AFG * u›X IDvѝXzb z/OS OS/390 Ws JDBC X{A BIND PACKAGE(collid) Ww IDC * uJava MѾvw]O{êWAziHNѪκѶWC 3. @UTwCYiыxs{ACJMΥcC 4. Hㇽk@Uxs{A@UϩmC z/OS OS/390 SQL xs{ b FixPak 7 Auxs{ýϩmv[jFbϩm DB2 for z/OS OS/390 у 7 xs{ëъ ALTER { (APAR JR16764)C Ynъuxs{ýϩmv˽ы z/OS OS/390 SQL xs{A𛧪 UCBJG 1. }uJ SQL xs{vFG a. bMΥc z/OS OS/390 ۫wsuUAHㇽk@Ux s{é۫㺿C b. @UJ -> ъFJ SQL xs{CYi}ʀFC 2. w z/OS OS/390 AFG * u›X IDvѝXzb z/OS OS/390 Ws JDBC X{A BIND PACKAGE(collid) Ww IDC * uSQL ۫]vw]O{êWAziHNѪκѶWC 3. @UTwCYiыxs{ACJMΥcC 4. Hㇽk@Uxs{AϩmC z/OS OS/390 Ѿxs{ýϩm˺s buxs{ýϩmvuWuSQL xs{[vA IBM DB2 Universal Database SQL Procedures Guide and Reference у 6 wL C pb z/OS OS/390 AWϩm SQL xs{ìLۛTAziHЪG * DB2 UDB for z/OS or OS/390 SQL Reference * DB2 UDB for z/OS or OS/390 Application Programming and SQL Guide ]wG›e b FixPak 7 Auxs{ýϩmvb|ê^G›xs{ë wʺiC ъuxs{ýϩmvAziHxs{ÿiCъuxs{ý mvxs{iz۫w\ϩmAHO_G›CYz xs{ê^ejG›Azi|nGьC񊬢C Ynsޔxs{ìG›eAG 1. @U -> eC 2. @UuevOу񬀓XC 3. YnbGьxs{G›ʪCA𓴿ьʪC񑓴C YnGьCAMьʪC񑓴AbnьC 㑵J@˅rC 4. YnbGьxs{G›Cˬ񬀮ʪ۫A𓴿ьC ˬʪ۫񑓴CYnGьeAMь Cˬʪ۫񑓴AbeWJ@˅r (Nݪr )CьbGA۫|QI_AHKXweW C 5. @UTwъzC b Windows NT Wq DB2 ۫w{ beuxs{ýϩmvADROP PROCEDURE SLkAݪaqb Windows NT tW DB2 ۫w{C b FixPak 7 Auxs{ýϩmviHѓTaqb Windows NT tW DB2 ۫w{C F bы۫wF]wXRjp iHъы۫wFː]wsϩ۫w񺿤ъݫ (Oϓ ݫݫ) XRjpMwѲjpЅCuݿъݫb uъݫvFw@˛tmA~|ъSC MQSeries UF DB2 у 7.2 s MQSeries UFCFы@ˬݫAъ DB2 MQSeries Functions ˚ MQSeries CA DB2 MQSeries Functions у 7.2 s\Cz]wAFiNC@h MQSeries T @˪wrA@ˮTwάrCыݫiz ]wˡլRrANC@h MQSeries Tê^@CݫCFi zbݫWыAw MQSeries TMݫGCF iquxs{ýϩmvu۫㡌xvʛC уFDG * MQSeries у 5.2 * MQSeries ъ{ÛT¡ (AMI) * DB2 MQSeries Function oÃDȝ˩ۛTAХ\"MQSeries"C dʃP MQSeries UFýA𩧪 http://www.ibm.com/software/data/db2/udb/ide ýqC OLE DB UF FUzы@ˬݫAq Microsoft OLE DB ìt@˩۫ wЬ˚۫Ct~Aziы@ DB2 ݫA OLE DB ݫ˗ А㺗۫Aziы OLE DB ݫ㬀CFiquxs{ ϩmvu۫㡌xvʛC уFDG * OLE DB Ь (p Oracle Microsoft SQL Server) * OLE DB \ dʃP OLE DB UFýA𩧪 http://www.ibm.com/software/data/db2/udb/ide WýqC V g Business Intelligence Business Intelligence ý gLΡq Business Intelligence ý FixPak 2 ]AFΡqL Business Intelligence ý۫㡌xd ʩ۫w (ѓF\hу 7.1 ʪsbD)CFъΡqL۫㡌x dʩ۫wA𛧪UCG pGz|хwdʩ۫wAъu@˿BJvogx˽ыsdʩ۫ wC@U}lAMߓ{› --> IBM DB2 --> @˿BJC pGzbѲewwFdʩ۫wANdʩ۫w DWCTBCBTBC_MD TBC CpGzdʩ۫wsWFѶnOs۫Ab۫weN۫ ѸCYnoTˢdʩ۫wG 1. } DB2 OA@U}lAA{› --> IBM DB2 --> O C 2. b DB2 OAJUCTO (JC@߽ Enter)G db2 drop database dwctbc db2 drop database tbc_md db2 drop database tbc 3. DB2 OC 4. ъu@˿BJvogx˽ыsdʩ۫wC@U}lA {› --> IBM DB2 --> @˿BJC DB2 Universal Database ͐t u͐tvAъ DB2 for Linux Linux/390C Hptru͐tvAioGCziӃn Web s rjpAHѓTab OS/2 Wu͐tvC Web s AHoҪrjpۛTCYnѓTau͐tv(„Aъ SBCS)Aϑzъ 8 I Helv rCwу񊙷۽Aϑzъ 8 I Mincho rC]wrn]wATwun]wvur v¬uъw]rAmѾwrvC bYÿlAi|bG˘sߡʛu͐tvCYnѓo ˛DAu͐tvAݗ`"ʛ Netscape с~T" BJC ʛu͐tvAzi|UCԪ JavaScript ~G file:/C/Program Files/SQLLIB/doc/html/db2qt/index4e.htmA65 G хwqC o JavaScript ~|u͐tvʛ index4e.htmAbʛu͐t vߪCiЖь index4e.htm s˖u͐t vʛC busSvqAu̝۫zvDDUޗb 7.1 uY xOsvCWOoC]G ڃxjpq 4GB W[ 32GBC ylG ю{ڃxwq 4GB W[ 32GBC DB2 Data Links Manager q@ylpUG BAi Veritas XBSA ¡ъA HKъ NetBackup @Ѹ_mC ylG BAi XBSA ¡˛Θk^_C xsڀ̝z{ XBSA ¡]t Legato NetWorker Veritas NetBackupC ۫㡌x Administration Guide iъs ۫㡌x̝zUwgs FixPak 4 @CziHq http://www.ibm.com/software/data/db2/udb/winos2unix/support uWU s PDFCoì`N񬀩ۛTOъHRsCz]iHb CD oʪwsѾC zL DB2 Aъ PTF X U478862AYiq CDCziHq http://www.ibm.com/cgi-bin/db2www/data/db2/udb/winos2unix/support/help.d2w/report opuDB2 AvۛTC xA[j\ b FixPak 5 AwxAFUC\ӺiJ s[cЅ A|ANA{Wѡn[cЅ㺾srC T DWC7906 ws {bT DWC7906 biYDA|]t~˫BJWC b FixPak 4 AwxAFUC\ӺiJ Nz{~ (rc = 7170)An rc = 6106C Nz{ObAÛenDeYwAh|oс~C ~iOѝnAB|AiC NutTvPuvgJڃx ݿъwq{훧AutTvPuv|gJx xCz{biHbuivь񼦿oÛTC WqTw (Incremental commit) {biѓTB@ pGY@BJѓbJυ۫woс~ABuWqTwv j 0Ahb~oсewTwʪGN|X{bυ۫w Cb FixPak 4 eA|RѸGC lhLkxA~wѓ xA|qtʚ VWS_LOGGING ^ڃxϓWC pG|F VWS_LOGGINGAVLϓWAh|ъ TEMP t ʚNCpG|F TEMPAVLϓWAh xl|gJ c:\CoNiѓ FixPak 4 eуAЮq n^LڃxϓWʐy~C xs{TwO[ bъwqxs{ýAxA|ÛeTwONz{ C jde xAѝAѽNz{TAʪudeviH aC {biHlڃxjp z{biHъstʚ VWS_SERVER_LOG_MAX ˜l xjpCpGzN VWS_SERVER_LOG_MAX ]wj 0Ax A|bڃxjpjFѮ VWS_SERVER_LOG_MAX ʽw 񩝞㫂A[jڃxjpCڃxFjpWA| OdslڃxngnCbjqlAVWS_ SERVER_LOG_MAX=150000000 (150M) OXzjpC ъ OS/390 Nz{훧 Trillium ժt JCL {b OS/390 Nz{iHu۫㡌xJyz۫vOуы Trillium ժtъwq{CLh Trillium ժt JCL A ѝъ WindowsBAIX Solaris @~Nz{˃ JCLCFo sAziHъ OS/390 Nz{˜ʛ JCLC pGzъ Trillium ժtuJyz۫vOу˽ы Trillium tъwq{BJANѝ OS/390 Nz{suDq (Y JCL MNz{bPtW)CPA]ѝJDqsu ЅC ыn Trillium ժtъwq{BJAъ Trillium tBJuevOуANNz{퀦znъ OS/390 Nz{ 퀦C pG JCL X~WѶўAAzb Script JCL X ~JoêWAѝъ̩]ݐoêWC ۫㡌xGsd{ ۫㡌x񋪐Gsd{GEEE_Load M File_WaitCziHъ EEE_Load {Ab۫㡌x{ы DB2 UDB EEE J{BJCz]iH ъ File_Wait {˽ыѽάBJAݔiHъAA~{ U@˿BJCpo{ȝ˩ۛTAwF۫㡌x񋪰A tAХ\ ..\SQLLIB\TEMPLATES\SAMPLES ϓ README.UDP C ъ DB2 Warehouse Manager ˀ̝z ETI.Extract(R) ӗ{ws ъ DB2 Warehouse Manager ˀ̝z ETI.Extract(R) ӗ{wgsAziH q http://www.ibm.com/software/data/db2/udb/winos2unix/support suU C ъ Common Warehouse Metadata Interchange (CWMI) JXyz۫ FϽeьyєA۫㡌x{b]iHJXyz۫ X Common Warehouse Metamodel (CWM) ì XML AHq XML JXyz۫CJXoÿ CWM XML ΗNOʽ Common Warehouse Metadata Interchange (CWMI)C ziHqUC۫㡌x񋬽ѾJXyz۫G * x * xυ * DA]A{BBυBBJ񊡽|YC * ъwq{ CWMI JXъ{ϽeSwyz۫A]AG{Bx BъsC ۫㡌x|ы@]tJX{GڃxCq`ڃx|ыb x:\program files\sqllib\logging ϓ ( x: Ow DB2 )A Ozwb VWS_LOGGING ʚ㬀ϓCڃxOժrFziHъѶ rs{˔ѪC Jyz۫ ziHb۫㡌xJyz۫AqROJyz۫C zLJ{îʽыsѾ|w]۫㡌xwюsCYȝ ۛTAХ\у`NubJߺsKO@vC pGOJYBJyz۫AhiHNh˔΃PBJpCBJ yz۫|xsb XML AOBJ|p۫Oxs BLOBCBLOB yz۫㬀WP XML μPAOѪOb˺OA WrCʪBJΪbJѝbPϓC ݿBJbсʪsBJ BJѝb}oʪA۫㡌x~ӺsBJyz۫CpGBJOb сʪAhbJyz۫eNBJ}oʪG 1. nJ۫㡌xC 2. bnBJW@UㇽkAA@UʪC 3. @U}oC {bBJNb}oʪFCbJyz۫AANBJ^с C q۫㡌xJ۫ ziHb۫㡌xJyz۫G 1. nJ۫㡌xC 2. @UѬ񬀡xC 3. @U -> Jyz۫ -> ѵ...C 4. buJyz۫vAw]tnJyz۫㬀WCziHJ Wъs˺C * pGzDmAhJҬ|MnJΪWCѝ[W .xml 㔂WAHwznH XML Jyz۫A_hLkѓTa BzC * Ynъs˺G a. @U (...) sC b. buvANΖ XMLC c. ѓTϓAAnJC : ѝ .xml 㔂WC d. @UTwC 5. bJyz۫A@UTw˺Cb۫㡌xJΫ| ьiC ъROJyz۫ z]iHъROJyz۫CUCJOykG CWMImport XML_file dwcControlDB dwcUserId dwcPW [PREFIX = DWCtbschema] XML_file | nJ XML άҩ|M | ΪW (]Aϓ)C | OѝnC ----------------------------------+---------------------------------- dwcControlDB | yz۫ʡnJx۫w | WCЅOѝnC ----------------------------------+---------------------------------- dwcUserId | zъːsx۫wъ | IDC ЅOѝnC ----------------------------------+---------------------------------- dwcPW | zъːsx۫wъ | qXC ЅOѝnC ----------------------------------+---------------------------------- [PREFIX=DWCtbschema] | u۫㡌xvtݫ۫w | ϪWC pGSw PREF | IX=Ahw]ϪW IWHC | OiъC bJъ{ߺsyz۫ bJߺsKO@ @wюWqA۫㡌x|JXqXCzѝnbs ѾWsqXCYJ`Nȝ˩ۛTAХ\۫㡌x̝zU 12 uXMJ۫㡌xyz۫vC bJyz۫㫂AʪѾ|w]wюsCziHisѾ sG 1. nJ۫㡌xC 2. b]tnѾ۫㺿W@UㇽkC 3. @UeAA@UKO@C 4. qxsCьNshAqiъxsCьsWs C 5. @UTwC Xyz۫ ziHb۫㡌xXyz۫AqROXyz۫C ѸBJyz۫Oxs BLOBCBLOB yz۫|X˺OA WPBJ XML μPAO㔂WOr (.1B.2 )C q۫㡌xX۫ ziHb۫㡌xXyz۫G 1. nJ۫㡌xC 2. @UѬ񬀡xC 3. @U -> Xyz۫ -> ѵC 4. buXyz۫vAwN]tXyz۫㬀WCziHJ Wъs˺G * pGzDҬ|nъWAJWJCTw [W .xml 㔂WAHwnH XML Xyz۫C * Ynъs˺G a. @U (...) sC b. bANΖ XMLC c. ѓTϓAAnXC : Ѷzʓ{s|QXyz۫gC d. @UTwC 5. uXyz۫vьFѓTWAbiъѾCь@Un Xyz۫㬀ѾC 6. @U > NѾq iъѾCь񝥛ѾCьC HWBJAʪnXѾCьbѾCьC 7. @UTwC ۫㡌x|ы@˓J (Ѫ]tPnX۫㡌x񋬽Ѿ ۛT)AMXìѾyz۫Cb۫㡌xXyz۫㫂| ьiC ъROXyz۫ bqROXyz۫eAzѝѲы@˓JCJO@˛㔂 W .INP ժrAѪ|ˡnXѾCXʪѾCݜzb۫㡌 xXAJOыAOqROXAzѝѲы JCziHъѶժrs{˽ыJCJʪѾW (P ьb۫㡌x񬀪WP)CTwμOыb@igϓC zXъ{A۫㡌x|N XML ΅gJJʪbP C UC@ˢdʓJG ý۬ݫ{ ýο ýυ s{s b ({) qACXʪnX{Cb (ۛT) qA CXʪnXxυC۫㡌x|JPoÿυ pݫMCb (ъwq{) qACXʪnX{ sC YnXyz۫Ab DOS ьUJUCOG CWMExport INPcontrol_file dwcControlDB dwcUserID dwcPW [PREFIX= DWCtbschema] INPcontrol_file | ]tnXѾ .INP ά | |MΪW (]A | )CЅOѝnC ----------------------------------+---------------------------------- dwcControlDB | nqXx۫wWC | ЅOѝnC ----------------------------------+---------------------------------- dwcUserID | zъːsx۫wъ | IDC ЅOѝnC ----------------------------------+---------------------------------- dwcPW | zъːsx۫wq | XC ЅOѝnC ----------------------------------+---------------------------------- [PREFIX=DWCtbschema] | u۫㡌xvtݫ۫w | ϪWC pGSw PREF | IX=Ahw] IWHCЅOi | ъC ьyїyz۫J/Xъ{ wq pGbьyєʮwqDnP~˙M۫wwgwqDn P~˙OPAhtBzCpGoÙPwwqPAh|oс~C BJP{Ü{ Jъ{ARBJP{Ü{Cbьwq{{b|sW{ {CьCoi|y{CъbBJ@сʪeA ѲR㬀{C SAP BJۛT iӽыb̓W@Pݫ pGXUCʪѾAhGυݫb̓Wi|@PC 1. BO Ҫ GetList P GetDetail XЅABzwMʪDnC 2. b SAP BJuevOуuXЅvWAz GetList X SAP ЅWPъЅㇴMWPC : SAP ЅWOҪWyIeЅѸCʪpAYЅ DocList.DOCNUMBERAh DocList O SAP ЅWC 3. b SAP BJuevOуuXЅvWAz GetDetail X ЅC dJ DocumentNumber ODnCDocList.DOCNUMBER DocNumberSelection.OPTION O GetList XЅCDocData.USERNAME O@ GetDetail XЅC zN DocumentNumber M DocList.DOCNUMBERC(Ѿ 1) z DocNumberSelection.OPTION @XЅC(Ѿ 2A] DocNumberSelection P DocList OP SAP ЅWC) z DocData.USERNAME @XЅC(Ѿ 3A]ѪO@ GetDetail XЅC) oÜѾ|PυݫO GetList P GetDetail ЅCMAL kTOY̓@PC SAP Connector ۛT SAP Connector w SAP Connector „^լ SAP R/3 tC GetDetail BAPI pG GetDetail jqJЅAh GetDetail BAPI |wCC Web Connector ۛT WebSphere Site Analyzer у Web Connector „ WebSphere Site Analyzer у 4.0CϽeу 4.1C DB2 OLAP Starter Kit IBM DB2 OLAP Starter Kit 7.2 b@ú@~tWW[ OracleBMS-SQLBSybase Informix p۫w̝zt (RDBMS) Cу 7.2 ]tʪ RDBMS Script MuA]A DB2CѪ@áAȝ˩ۛTХ\"w DP"C DB2 OLAP Starter Kit for DB2 Universal Database у 7.2 A{ѻ ݮ Hyperion Essbase 6.1 Ω{ 2 [W Hyperion Integration Server 2.0 Ω{ 2C OLAP Server Y DB2 OLAP Starter Kit sw񊿤ъZAyX DB2 OLAP Server Library G http://www.ibm.com/software/data/db2/db2olap/library.html @~tA{ѻ OLAP Starter Kit for Version 7.2 AѾUC@~tMA{ ѻG * w SP 5 Windows NT 4.0 P Windows 2000 * AIX у 4.3.3 HW * Solaris @~tу 2.6B7 P 8 (Sun OS 5.6B5.7 5.8) qѾ Windows 95BWindows 98BWindows NT 4.0 SP5 P Windows 2000C DB2 OLAP Starter Kit b UNIX Ww w DB2 OLAP Starter Kit DB2 Universal Database for UNIX w у{iC~|Ъw{tϓG (AIXG /usr/lpp/db2_07_01F Solaris @~G/opt/IBMdb2/V7.1)C ыοʬѼqA|ыԡ DB2 OLAP ϓ (essbase P is) οʿъ _lϓU sqllibϓUCP@„\@ OLAP AοC YnwAъѝԛ]w is/bin ϓA]ѪLkt is/bin ϓCѪѝοʬ_lϓUigJϓC Ynb Solaris @~WwAHο ID nJA񙗽 sqllib/is ϓAMߓJUCOG rm bin mkdir bin cd bin ln -s /opt/IBMdb2/V7.1/is/bin/ismesg.mdb ismesg.mdb ln -s /opt/IBMdb2/V7.1/is/bin/olapicmd olapicmd ln -s /opt/IBMdb2/V7.1/is/bin/olapisvr olapisvr ln -s /opt/IBMdb2/V7.1/is/bin/essbase.mdb essbase.mdb ln -s /opt/IBMdb2/V7.1/is/bin/libolapams.so libolapams.so Solaris @~ʬ[[c b Solaris @~ApG OLAP Starter Kit хAݬ ODBC X{ Ah|oс~CFκKoÓ~A𛧪UCOA˽O|b $ARBORPATH/bin ыAHV OLAP X{ sqllib/lib/libdb2.soJ ln -s $HOME/sqllib/lib/libdb2.so libodbcinst.so ʪ@~t[[c q DB2 Universal database у 7 FixPak 3 }lA DB2 OLAP Starter Kit ]tFnъ Java Cw FixPak 3 sуAz|b OLAP Server DxWUC~TG Can not find [directory] [/export/home/arbor7sk/sqllib/essbase/java/], required to load JVM. Ynѓ~A𜑿UCBJG 1. H DB2 οʥͪѸnJC 2. Mw DB2 OLAP Starter Kit ϓCϓw]WO essbaseC 3. b essbase ϓAы@˪W java lϓC 4. b java lϓAыUCўJ * essbase.jar * essdefs.dtd * jaxp.jar * parser.jar * udf.policy [c OLAP Starter Kit ODBC IBM DB2 OLAP Starer Kit 7.2 n@ ODBC.ini A ODBC @~q OLAP Integration Server sp۫MuOLAP yz۫㽼vC * b Windows tWAΪtn HKEY_LOCAL_MACHINE/SOFTWARE/ODBC Cъ ODBC Data Source Administrator ˔xspsp۫ۛTC * b UNIX tWAw{ы@˅ʽ odbc.iniCxsps p۫ۛTAъznsޥˢsުC ODBC.ini ODBC nګMѾAt Microsoft Office n Cpw ODBC X{uODBC ̝zvъ{ۛTAyXU CGhttp://support.microsoft.com/C AIX W Oracle ъG[c ODBC for OracleAzѝs ODBC.ini ο˽V MERANT 3.6 X{C bу 7.2 AOLAP Starter Kit ̝z ODBC suːsp۫M uOLAP yz۫㽼vCFo ODBC sA OLAP Starter Kit b Windows NT 4.0BWindows 2000BAIX Solaris @~tWъ ODBC X{ C * DB2 Universal Database у 6 ۫wqGb Windows NT 4.0 SP5 Windows 2000BAIX 4.3.3 Solaris @~t 2.6B7 8 (Sun OS 5.6B 5.7 5.8)WO DB2 у 6 ODBC X{C * DB2 Universal Database 7.1 ۫wqGb Windows NT 4.0 SP5 Windows 2000BAIX 4.3.3 Solaris @~t 2.6B7 8 (Sun OS 5.6B 5.7 5.8) WO DB2 у 7 ODBC X{C * Oracle 8.04 M 8i SQL*Net 8.0 ۫wqGb Windows NT 4.0 SP5 Windows 2000BAIX 4.3.3BSolaris @~t 2.6B7 8 (Sun OS 5.6B 5.7 5.8) WO MERANT 3.6 ODBC X{C * MS SQL Server 6.5.201 (nu۫wqv)Gb Windows NT 4.0 SP5 Windows 2000 WO MS SQL Server 6.5 ODBC X{C * MS SQL Server 7.0 (nu۫wqv)Gb Windows NT 4.0 SP5 Windows 2000 WO MS SQL Server 7.0 ODBC X{C b UNIX tW[c۫ b AIX M Solaris tWAzѝԛ]w ODBC ʚAs odbc.ini ο˼[cp۫MuOLAP yz۫㽼vCYzsW X{۫Aѝs odbc.ini C pGzOnb AIX Solaris tWъ DB2 OLAP Starter Kit ˪s Merant ODBC DB2 ۫wAb .odbc.ini ά DB2 q񚌺 "Driver=" ApUьG AIXGX{W /usr/lpp/db2_07_01/lib/db2_36.o AIX d ODBC nG [SAMPLE] Driver=/usr/lpp/db2_07_01/lib/db2_36.o Description=DB2 ODBC Database Database=SAMPLE Solaris @~JX{W /opt/IBMdb2/V7.1/lib/libdb2_36.so Solaris @~ʬd ODBC nJ [SAMPLE] Driver=/opt/IBMdb2/V7.1/lib/libdb2_36.so Description=DB2 ODBC Database Database=SAMPLE [c ODBC ʚ b UNIX tWAzѝ]wʚ~Ӫs ODBC ѾCStarter Kit _lϓ is.sh M is.csh Shell Script ː]wѝnCbъ ODBC ːs۫eAzѝ@ ScriptCzъ˛ OLAP Starter Kit ъWAz˪bnJ Script ]to ScriptC s odbc.ini odbc.ini [c۫AzѝsW ODBC ۫WMA bzw۫Wʽыq ODBC X{|BWL X{]wCw{b ISHOME ϓw@ˢdʔ odbc.iniC ]tqъ ODBC sM ODBC X{[cۛTCъΛ _IANzъ ODBC X{퇴Mp۫MuOLAP yz۫㽼 vC YzъO odbc.iniAN ODBCINI ʚ]wzъWC sW۫ odbc.ini 1. b OLAP Starter Kit AtWAъЪp vi ժrs{ } odbc.ini C 2. [ODBC Data Sources] qAsW@۫WMA pG mydata=data source for analysisCFκKVcA۫W ˝X RDBMS 񬀩۫wWC 3. sW@H޼AtAs۫WAʪp [mydata]AbsW@ sqC 4. b۫WUˬXAsW۫WѶѝn ODBC X {ۛTʃ ODBC X{񺺇ҩ|MΪWCUCX`ь dʿˇMz RDBMS W۫CTw ODBC X{픂΢T۪s bzb Driver= ]w񽳮wmC 5. ݜzs odbc.ini AxsAժrs{C ODBC DB2 ]wd UCdʚьps odbc.iniAъ IBM DB2 l ODBC X{ːs AIX W DB2 Universal Database у 6.1 p۫ db2dataCb vi sޥAъ $ODBCINI Oˢs odbc.iniAJUCzG [ODBC Data Sources] db2data=DB2 Source Data on AIX ... [db2data] Driver=/home/db2inst1/sqllib/lib/db2.o Description=DB2 Data Source - AIX, native ODBC Oracle ]wd HUdʃps odbc.iniAъ MERANT у 3.6 ODBC X{ːs Oracle у 8 (b Solaris @~W) p۫ oradataCd ALogonID M Password H OLAP Starter Kit ъWMqXۃ ±JC [ODBC Data Sources] oradata=Oracle8 Source Data on Solaris ... [myoracle] Driver= /export/home/users/dkendric/is200/odbclib/ARor815.so Description=my oracle source b UNIX tW[c OLAP yz۫㽼 b AIX M Solaris tW[cu OLAP yz۫㽼v[c@˩۫C u OLAP yz۫㽼v۫wAb odbc.ini sW@˩۫ WMqAp"s odbc.ini "ʡzCnѪC zѝѲb RDBMS ы@uOLAP yz۫㽼v۫wA~ӜNѪ [c ODBC ۫C HUdʃps odbc.iniAъl ODBC X{ːs DB2 у 6.1 (b Solaris @~W) uOLAP yz۫㽼vTBC_MDC [ODBC Data Sources] ocd6a5a=db2 v6 ... [ocd6a5a] Driver=/home/db2instl/sqllib/lib/db2.0 Description=db2 b Windows tW[c۫ Windows NT Windows 2000 tW[cp۫Azѝʛ uODBC ̝z{vAM߽ыsuːsznъ˽ы OLAP ʽM metaoutline ۫Cq Windows xuODBC ̝z{vъ{ CUCdʽы@ DB2 ۫FL RDBMS |PC ъuODBC ̝z{v˼[cp۫A𺇪UCBJG 1. b Windows W̝z{A}uxvC 2. buxvAUC@BJG a. b Windows NT WAU ODBC ьA}uODBC ̝۫z{v C b. b Windows 2000AUt̝zu҇ьAAU۫ (ODBC) ьA}uODBC ̝۫zvC 3. buODBC ̝۫z{vA@UtWC 4. @UsW}uыs۫vC 5. buODBC ̝z{vuыs۫vϬX{CьA AݬX{Aʪp IBM DB2 ODBC X{A@U}uODBC IBMDB2 X{ - sWvC 6. buODBC IBM DB2 X{ - sWvAb۫wOWUȪCьA zp (ʪpAdʔъ{ TBC) ۫wWC 7. bժrAJъˬьznpъX{A@Us WCʪpAJUCժr˃ My Business ۫wG Customers, products, markets ziJUCժr˃dʔъ{۫wG Sample relational data source oÃibzq OLAP Starter Kit Desktop suAUzкOi ۫C 8. @UuTwvˬ^uODBC ̝۫zvCzJ۫ WzMX{ьbtWʬt۫Cь C sީ۫[cۛTG 1. ۫WA@U[c}uODBC IBM DB2 - sWvC 2. ѓznѶۛTC 3. ԪTwHC b Windows tW[c OLAP yz۫㽼 Windows NT Windows 2000 W[cuOLAP yz۫㽼vAʛ uODBC ̝z{vAM߽ыsuːstuOLAP yz۫㽼v۫w ۫C UCdʽы@ DB2 ۫FL RDBMS |PCыuOLAP yz۫㽼v۫A𺇪UCBJG 1. bW̝z{A}uxvC 2. buxvAUC@BJG a. b Windows NT WAU ODBC ьA}uODBC ̝۫z{v C b. b Windows 2000AUt̝zu҇ьAAU۫ (ODBC) ьA}uODBC ̝۫zvC 3. buODBC ̝۫z{vA@UtWC 4. @UsW}uыs۫vC 5. buODBC ̝z{vuыs۫vϬX{CьA AݬX{Aʪp IBM DB2 ODBC X{A@U}uODBC IBMDB2 X{ - sWvC 6. buODBC IBM DB2 X{ - sWvAb۫wOWUȪCьA zuOLAP yz۫㽼v(ʪpAdʔъ{ TBC_MD) wWC۫wW|ьb۫WժrC 7. Yzn۫WA𓴿۫WժrьWAJ sWˬьznpъX{A@UsWCʪpAziJUC WˬьznъX{ːs@uOLAP yz۫㽼vG OLAP Catalog first ziJUCWˬьznsdʔъ{uOLAP yz۫㽼v wG TBC_MD 8. bժrAJˬьznpъX{CʪpAziJ UCժr˃uOLAP yz۫㽼vG My first models and metaoutlines ziJUCժr˃dʔъ{uOLAP yz۫㽼v۫wG Sample models and metaoutlines oÃibzq OLAP Starter Kit Desktop suOLAP yz۫㽼 vAUzкOQnC 9. @UuTwvˬ^uODBC ̝۫zvCzJ۫ WzMX{ьbtWʬt۫Cь C sީ۫[cۛTG 1. ۫WA@U[c}uODBC IBM DB2 - sWvC 2. ѓznѶۛTC 3. ԪTwHC bz[c۫ b[cp۫MuOLAP yz۫㽼vAYiq OLAP Starter Kit ːsCMiHыBκxs OLAP ʽM metaoutlineC bIs SQL Server ۫wASQL Server ODBC X{i|OC ۫wDuCW[X{OiκKDCȝ˩ۛTAХ\ zʿъX{ ODBC ѾC ODBC sDPпMޫAХ\ OLAP Integration Server System Administrator's GuideC q OLAP Starter Kit W̝z{nJ ъ OLAP Starter Kit W̝z{˽ы OLAP ʽM MetaoutlineAN qnڐsԡ˪AGDB2 OLAP ҪXAM DB2 OLAP ACnJ ьW̝z{soԡ˪AѝnۛTCbѬAJ DB2 OLAP ҪXAۛTCbkAJ DB2 OLAP A ۛTC s DB2 OLAP ҪXAG * AGJҪXADqW IP }CpGzwwҪXA MW̝z{P@u@Aս "localhost" "127.0.0.1"C * OLAP yz۫㽼GsuOLAP ҪXAvAѝwuyz۫㽼 vC uOLAP ҪXAvxs OLAP ʽMWuyz۫㽼v p۫wʽы metaoutline ۛTC p۫wѝnO ODBCC ϓ۫w@uOLAP ҪXAvӓٖЬpݫCbnJ AwҪXAAi} OLAP yz۫㽼vU\ӬA ziHuOLAP ҪXAvʬD ODBC ۫WCC tyz۫㽼ݫ ODBC ۫wC * ъWMqXGъzbeʽwъWMqXAuOLAP ҪXAvNPyz۫㽼sCoOnJbAsbA (Oq ADAMqbP@x)CъWѝы OLAP yz۫㽼vъC_hAuOLAP ҪXAvNϓ۫w 񀬀pݫA]ݫϬW@C uDB2 OLAP AvۛTъAHAbnJkJiӼO ўCOAëW̝z{M̝z{@~nMuDB2 OLAP Av sCpGzԐoÑUAݥҪXAnMuDB2 OLAP Avs HzʡnD@~AW̝z{|A@ьnJC ϑzbnJ uDB2 OLAP Av±J۫C suDB2 OLAP AvG * AGJuDB2 OLAP AvDqW IP }CpGzb OLAP Starter KitAhuOLAP AvMuҪXAvPCpGuҪX AvMuOLAP AvwbPDqAJwquOLAP ҪX Av񀬀DqW IP }C * ъWMqXGъzbeʽwъWMqXAuOLAP ҪXAvNPuDB2 OLAP AvsCъWMqXѝw gwqbuDB2 OLAP AvCuOLAP Av@~tt~a̝zѪ ʥͪъWMqXC Starter Kit nJd UCdʛ]Ab OLAP Starter Kit wAzыF OLAP dAF db2admin @̝zъ IDApassword ̝zqXC * OLAP ҪXAGAO localhostA OLAP yz۫㽼O TBC_MDA ъWO db2adminAqXO password * DB2 OLAP AGAO localhostAъWO db2admin ы[c OLAP Starter Kit dʩ۫w w OLAP Starter Kit Adʩ۫w|ыCUCьБAѝnA pwϓMdʩ۫wC 1. bUA@U }l -->{›-->DB2 for Windows NT--> OAH }uROvC 2. ыϓ۫wG a. J db2 create db OLAP_CAT b. J db2 connect to OLAP_CAT 3. ы۫w񀬀ݫG a. \SQLLIB\IS\ocscript\ocdb2.sql b. J db2 -tf ocdb2.sql 4. ыdʿ۫wG a. J db2 connect reset b. J db2 create db TBC c. J db2 connect to TBC 5. ы۫w񀬀ݫG a. \SQLLIB\IS\samples\ b. s tbcdb2.sql \SQLLIB\samples\db2sampl\tbc c. s lddb2.sql \SQLLIB\samples\db2sampl\tbc d. \SQLLIB\samples\db2sampl\tbc e. J db2 -tf tbcdb2.sql f. J db2 - vf lddb2.sql AHJdʿ۫ݫC 6. ыdϓ۫wG a. J db2 connect reset b. J db2 create db TBC_MD c. J db2 connect to TBC_MD 7. ы۫w񀬀ݫG a. \SQLLIB\IS\samples\tbc_md b. s ocdb2.sql \SQLLIB\samples\db2sampl\tbcmd c. s lcdb2.sql \SQLLIB\samples\db2sampl\tbcmd d. \SQLLIB\samples\db2sampl\tbcmd e. J db2 -tf ocdb2.sql f. J db2 -vf lcdb2.sqlAHJdʗyz۫ݫC 8. [c ODBC for TBC_MD, TBC, AND OLAP_CATG a. @U}l-->]w-->xAH} NT x b. qCь񓴿 ODBC ( ODBC ۫)C c. ut DSNvC d. @UusWvC ыs۫}C e. qCь񓴿 IBM DB2 ODBC DRIVERC f. @UuvC ODBC IBM D2 X{ - sW}C g. b۫WAJ۫ (OLAP_CAT) WC h. b۫wOWAJOWAO@UAbCь񓴿 OLAP_ CATC i. @UuTwvC j. TBC_MD M TBC ۫wA𡽢HWBJC Ӕъ{ OLAP Starter Kit у 7.2 w{sw OLAP Starter Kit dʔъ{B۫w۫㔂Cz {sъ{M۫wvTCMAbweAnѲѸzъ{ M۫wC zъ{b}ʫ|Ӫу 7.2C wDP уqCь DB2 OLAP Starter Kit wC Windows ѡx Informix RDBMS M Merant X{e F Windows ѡx Merant X{ӛM Informix RDBMS @ _B@APATH zѝsWUCԡG * C:\Informix * C:\Informix\bin oԡѝ PATH }YC OLAP ʽ񬀀ήM Metaoutline iӬ@P bYÜpUAzыΪb OLAP ʽLCbUC ۛ|oсoÜG 1. ыxs@s OLAP ʽC 2. ʽ˽ы@ metaoutlineAхxs metaoutlineC 3. ^ OLAP ʽAR@ metaoutline ήʿӬC 4. ^ metaoutlineA}BAAs}CmetaoutlineN]t @ˀAΪb OLAP ʽLC OLAP Starter Kit LkoϜpUы@PήM metaoutlin 񬀿ъwqC]A@P|ьb metaoutline A metaoutline Ѫ@˿ъwqA] OLAP ʽLΪsbC b Windows 2000 ѡxWATMP ʚ]wPM۫㩳J ] Windows 2000 M Windows NT ATMP w]tMъ ʚ]wʫtA OLAP Starter Kit b Windows 2000 ѡxW AM۫㩳J|Cy~TiDъLkы sCziUCBJ˩пM Windows 2000 G 1. ы@ϓ C:\TEMP 2. NtMъʚ TMP ]w TMP=C:\TEMP w ODBC N{s Merant X{ {s 3.6 Merant ODBC X{Hw˺sCYzq OLAP Starter Kit у 7.1 ѓMѾ 2 у񂻚Azˑ~ ъѲew ODBC X{ b UNIX ѡxWъ Merant Informix ODBC X{ UNIX ѡxWъ Merant Informix ODBC X{Azѝ UC@@G * bʛ Starter Kit eAN LANG ʚ] en_USCʪpA YO korn shellAJG export LANG='en_US' Cʛ OLAP Starter Kit ʐ]wC * Yz LANG ʚw]wPA𮾪w߽ыUC G ln -s $ISHOME/locale/en_US $ISHOME/locale/$LANG VX OLAP qMAA{ѻ IBM ϑzN DB2 OLAP Starter Kit qMAѾOb PуMѓMѾhCbYìpUAziVXqMA ѾA{ѻG ъP@уPA{ѻqMA IBM MϑPъsqMAC LAM IBM AziPъqM sACzi|DJ@ÛDCʪpG * ˪ATiѓTCzi񂻚q message.MDB ο˝XAhAYiпM DC * sASS@ъCݜzъsSAq BAԬiC * qiLkAݪasAC bP@ˬуъhAM@q YznN@˜qsP@~tWX OLAP AAIBM ϑzoêAюъPуMA {ѻCzq͔˃PChAPC YzDJDAhiӃnъPq˛tXA DqANʪqMA񂻚PA{ ѻC VXPуqMA IBM Pъ OLAP Starter Kit qMAу 7.1 PqMAу 7.2C IBM OLAP ~񂻚 sуhAsM۫㫵회q`nDq MAPуhC VX IBM ~ (DB2 OLAP Starter Kit) M Hyperion ~ (Hyperion Essbase M Hyperion Integration Server) IBM VX IBM OLAP qMAP Hyperion Solutions OLAP qMACMVXoѾb YÜpUiHB@ASWѸti|yDC OLAP Ԭ݅Wq› EQD Γ b DB2 OLAP Starter Kit 񬀩Ԭ݅Wq›Ҫ Query Designer (EQD) ѾC EQD uW\ӬʺtýsA|ьѶeCʔь 𺸼 OLAP Spreadsheet Add-in User's Guide for Excel 2 AH OLAP Spreadsheet Add-in User's Guide for 1-2-3C EQD ý񬀮ʪ TAiHquۛTvoëБy HTML PDF dC ۛT̝z{̝zU ۛT̝z{_l]wъ{ ъ_l]wۛT̝z{ (ICM) ъ{Az{biHQъUCOAK [ SQL z CREATE TABLE zG CREATEIC \DBTYPE dbtype \DGNAME dgname \USERID userid \PASSWORD password \KA1 userid \TABOPT "directory:\tabopt.file" ziHqw DB2 ϓAb CREATEIC ъ{񽳮w TABOPT rC TABOPT r߬O tabopt.fileAΪWOtҬ|CpGϓ WўAH̩Aݩ˪WCtabopt.file άeѝtۛTA~ ӝK[ CREATE TABLE zCziHъUCѶ@ SQL zgJ tabopt.file CICM ъ{NAMߜNѪK[ CREATE TABLE zC 9. SQL z +-------------------------+-------------------------------------------+ | IN MYTABLESPACE | H MYTABLESPACE ۫ыݫ | +-------------------------+-------------------------------------------+ | DATA CAPTURE CHANGES | HXRыݫO SQL | +-------------------------+-------------------------------------------+ | IN ACCOUNTING INDEX IN | H ACCOUNTING ۫ ACCOUNT_IDX ̽ | | ACCOUNT_IDX | ыݫ | +-------------------------+-------------------------------------------+ eάjjpO 1000 @񩝞rC os\uӪb Windows UNIX tWъC vD pGzoFUCTG FLG0083EGzSuIBM ۛT̝z{_l]wvъ{vC 󩋜zݪanکgPˮ IBM ~NC zѝR DB2 Warehouse Manager IBM DB2 OLAP ServerAwuۛT ̝z{vѾA]tFuۛT_l]wvъ{C wD YzbwF DB2 Warehouse Manager IBM DB2 OLAP Server ASb Pu@WwѪuۛT̝z{̝zvѾ (Qъ DB2 Universal Database CD-ROM)AK|gۛT_l]wъ{CAziHq \sqllib\bin ϓUAX createic.bak P flgnmwcr.bak ANO W createic.exe flgnmwcr.exeC Yznt~w DB2 Universal Database WuۛT̝z{vѾAh oѾӪwb Data Warehouse Manager ʪwP@u@WCzi HХ\uDB2 Warehouse Manager wUv 3 uwۛT̝z{ ѾvAdi@BۛTC ۛT̝z{[j\ uۛT̝z{vtUC[j\J ICM {bυ۫wBݫ ETI LoۛTJCuxv inOAziHъs ICM ѾuETI ӗ۫v˔xsLo TCMAoìѾ|wqυ۫wBݫC NPuETI ӗvnOP ICM Ah ICM NiHъhuETI ӗ۫vѾ˖Swυ۫wBݫC P\]iHъuӗvANPuETI ӗvnOP ICM AhSwυ𬢑{bYithuӗvCp@AICM bJ ETI*Extract M|uӗvC pъoûSAъ ETI*Extract 4.2.1 P MetaScheduler 4.1.0 n Ou۫㡌x̝z{vCХ\ http://www.ibm.com/software/data/db2/datawarehouse/support.html W DB2 Warehouse ManagerAziHb Hints and Tips `񿷜oъoûS ۛTCjMr "ETI" "Application Data"C b Windows uۛT̝z{v Sybase e uۛT̝z{vу 7 M Sybase Open Client wbP@x Windows NT Windows 2000 |y~AB Sybase ъ{|B@C|X{ UC~TG Lk_l LIBTCL.DLLCTw SYBASE wѓT]wC κKoϜʬެkOq Windows ʛЅNʛЅ LC_ALL hC LC_ALL O@˃yєʀϖЅC yєʀϖOуg`ʿъҬ`AH w{nъyєʩۛTѸC yєʼOa]۫a/a^A{ YޡiHwaqCyєʼ]AAʪpڗf ьCLC_ALL |vTʪyєʻSw (ʪϖ)C pGzN LC_ALL ʛЅhAo ICM NiM Sybase Psb Windows NT ѡxWAUC|LkB@G * ۛTъ * ۛT̝z * ۛT̝z{ h LC_ALL ЅAvT ICM H~LC H DB2 у 7 ۛT̝z{s DB2 у 5 ۛT DB2 у 7 w{îʼ[c DB2 у 7 ۛT̝z{ѾA sxsb DB2 у 6 M DB2 у 7 ۫wۛTCκѾ[ cAsxsb DB2 у 5 ۫wۛTCDB2 у 7 ۛT̝z{ Ѹs DB2 у 2 eу۫C ]wۛT̝zAsۛTۛTъMۛT_l]wъ{ Axsb DB2 у 5 ۫wG 1. bSw DB2 у 7 ۛT̝z{u@Aw DB2 Connect Enterprise Edition у 6C DB2 Connect Enterprise Edition O DB2 Universal Database Enterprise Edition M DB2 Universal Database Enterprise - Extended Edition @ CpGwo DB2 ~у 6ALt~w DB2 ConnectC : bP Windows NT OS/2 u@AӪw DB2 hуCz iHbѪ Windows NT u@B OS/2 u@ UNIX u@Ww DB2 ConnectC 2. [cۛT̝z{M DB2 Connect у 6As DB2 у 5 ۫C ȝ˩ۛTAХ\ DB2 Connect User's GuideCHUѝnBJ[G a. b DB2 у 5 tAъ DB2 ROBzsϬу 5 ۫wAs ۛT̝z{C b. b DB2 Connect tAъ DB2 ROBzisG * DB2 у 5 t TCP/IP `I * DB2 у 5 t۫w * DB2 у 5 t DCS n c. bۛT̝z{u@Aъ DB2 ROBzisG * DB2 Connect t TCP/IP `I * DB2 Connect t۫w sϩ۫wۛTAХ\ DB2 Universal Database wP[cRC 3. ۛT̝z{xAN DB2 CLI MnڮMzL DB2 Connect ʪs U˩۫wisC UC DB2 OАs v5database dA@˛] DB2 у 5 ۫wCъ DB2 ROBzoXUCOCdb2cli.lst db2ajgrt mb \sqllib\bnd ϓC db2 connect to v5database user ъ ID using qX db2 bind db2ajgrt.bnd db2 bind @db2cli.lst blocking all grant public ъ ID O v5database ъA qXOъ ID qXC db2cli.list Qs DB2 у 5 ۫wA|oс~Coс~AO] [cjѾCo~|vTxNz{퇴 DB2 у 5 ۫wsC n DB2 Universal Database у 5 FixPak 14 ( 2000 ~ 6 o )A~ӐzL DB2 Connect ˪s DB2 у 5 ۫C FixPak APAR s JR14507C ]mۛT b 1 1 qBJ 2u]mۛTvG ݜzwF DB2 Warehouse Manager DB2 OLAP ServerA Y|b DB2 Universal Database for Windows NT ыw]ۛTC oːzOѓTCzѝwqsۛTCȝ˩ۛTAХ\uы TvѸC PѪ~ѵyz۫ b 6 uPѪ~ѵyz۫vuкOnG OLAP ѾvqAb Gq@ylG ݜzG DB2 OLAP ҪXAyz۫㫂A |bۛTuhΩ۫wvP OLAP ҪXAݫѾыYC oqpUьG ݜzG DB2 OLAP ҪXAyz۫㫂A |bۛTuhΩ۫wѾݫѾ񬀀v ыYC o@y]X{b C uyz۫ㇴMvuۛT̝z{P OLAP A yz۫ㇴMvqC ъ flgnxoln Oѵyz۫ b 6 uѵyz۫v@˼qDOuкOnG OLAP ѾvCbqߡъ flgnxoln OG OLAP Ayz۫ TdCdʚь db2olap.ctl M db2olap.ff άϓ x:\Program Files\sqllib\loggingAoOѓTCϓ˪p 87 ®ʃG x:\Program Files\sqllib\exchangeC ъ MDISDGC Oѵyz۫ 6 uPѪ~ѵyz۫vuNX MDIS yz۫ӗьy єv( 89 )CziHq MS-DOS OьUoX MDISDGC OA˔ q DB2 OoX˽OCː`@ygDGuN MDIS yz ӗьyєvzѝq MS-DOS OьoX DGMDISC OCz ѝq DB2 OoX DGMDISC OC Is{ uۛT̝zUv񔬀d񬀽O]tF Program Files ϓW CݜzIs@]t Program Files ϓWOAzѝN{Is] b̩Cʪpb B uwѲwqۛT̝z{ѾvuHw ѲwqѾ_l]wzۛTvq@ˢdCpGzъo dAݜzq DOS ьѪ|o~TCUCOѓTdG "X:Program Files\SQLLIB\SAMPLES\SAMPDATA\DGWDEMO" /T userid password dgname Information Catalog Manager Programming Guide and Reference (Lլ) Information Catalog Manager Reason Codes In Appendix D: Information Catalog Manager reason codes, some text might be truncated at the far right column for the following reason codes: 31014, 32727, 32728, 32729, 32730, 32735, 32736, 32737, 33000, 37507, 37511, and 39206. If the text is truncated, please see the HTML version of the book to view the complete column. ۛT̝z{ъU b 2 A@˼qunOA`IPۛTvCqCXF zbъuۛT̝z{vnOۛTiquDB2 v BJCoː`@˼qbquDB2 voÿBJ (sWtBsWοsW۫w)Ab}uۛT̝z{veѝ uvCoۛTѓTCb}uۛT̝z{ve nuvC Pѓ]AъunOA`IۛTv@~uWAH unOA`IۛTvuWC ۛT̝z{GuWT ѓ FLG T T FLG0260E TGyG ~|yЬۛT rollbackC ۛTpwA хiѶC T FLG0051E T񀬀GϝG ۛTt˪hѾѾC ̝z^G ъJqϽeۛTRѸѾѾC T FLG0003E TG ۛTѝbъeinOC ۛTinO~C T FLG0372E T@yG ATTACHMENT-IND ѾʮA]ˬѾO Attachment ѾC T FLG0615E TGyG uۛT̝z{vJDw۫w~A bϽeϓ|sC ۛT̝z{GuW ۛTG\Ӭ}ϬuW~au}ʓ ѾvCѪ˃u}ʮwqjMvC Web ۛT̝z{ ъ DB2 UDB for OS/390 system ۛTASjpgjM\ CjMMijMpOpCuWSБAj MADB2 UDB for OS/390 ۛTʪjMjpgC~Aʪ񔝞 ϖѾiHXRAYѪOѾC DB2 Warehouse Manager wU iHъ DB2 Warehouse Manager wUs uDB2 Warehouse Manager wUvwgsA˜ziHq http://www.ibm.com/software/data/db2/udb/winos2unix/support uWU s .pdfCz]iHb CD 񿷜oʪwsѾCzLA{ъ PTF X U478862AYiq CDCoì`N񬀩ۛTOъHRsC xӗ{nڃD bzpnъxӗ{۫wWAѝѲw Java Developer's Kit (JDK) у 1.1.8 (HW)C SAP R/3 Connector q SAP R/3 ~ѾM DB2 ݫAÝсWi| WL 30 rCbpUAсWu|M SAP We 30 rCYсWDzʡnAziHъuevOуݫC wѲMѾ pGb SAP ¬ϬawwAh]w RFC_INI CʪpA Set RFC_INI=c:\rfcapl.iniCb]wAzѝsʛqC Web Connector Yzb Web Connector oсDAIBM A{i|nDzÛe Connector lC Ynъ Web Connector lAN Warehouse Center Nz{l]w j 0ClW WSApid.logA{ ID ONz{ Windows { IDCl|ы \sqllib\logging ϓUC wѲMѾ w Java (JRE) Java Virtual Machine (JVM) у 1.2.2 ( HW)ANѪ]zw]CYnы JRE у@zw]AN 1.2.2 JRE |sWzt PATH (p C:\JDKs\IBM\java12\bin;)Cbw ] JRE AzѝsʛqCYzхw JavaAziHqw Data Warehouse Connector CD ˪wC iSeries Nz{ߩmw`N b 4 Auw AS/400 (iSeries) xNz{vquߩmw`N vqAN@˼qG xNz{|b@u@񛧪ʪBJCb V4R5 eADB2 Universal Database for iSeries N@TwdiHJC㡡 4 UCb V4R5 wW[ 500 UCCpGzъO V4R4 (HU) tBdWXjpAhdъx Ь FTP {˝۫C ъӗ{P iSeries xNz{e b 4 Ahquъӗ{P iSeries Nz{evPʪ lqC Query Patroller Administration Guide (Lլ) DB2 Query Patroller Client is a Separate Component The DB2 Query Patroller client is a separate component that is not part of the DB2 Administration client. This means that it is not installed during the installation of the DB2 Administration Client, as indicated in the Query Patroller Installation Guide. Instead, the Query Patroller client must be installed separately. The version and level of the Query Patroller client and the Query Patroller server must be the same. Changing the Node Status The following is an update to the Node Administration section of the Query Patroller Administration Guide. Use the following procedure to change the node status: 1. On the Node Administration page, select a node. 2. Click on View / Edit. The Detailed Information for Node window opens. 3. Select the new status in the Status Requested field. : Status Requested is the only field in the Detailed Information for Node window that can be changed; all other fields display values that have been supplied by DB2 Query Patroller. 4. Click on OK. The following list provides information for each node parameter: Node ID Provides the ID for the node. Node Status Contains the current node status: * Active indicates that the node is able to run jobs. * Inactive indicates that the node's DB2 Query Patroller component is shut down. The node is not available to DB2 Query Patroller. To reactivate the node, use the iwm administrative user account to issue the dqpstart command. * Quiescing indicates that the node is in transition to the quiescent state. Running jobs will complete, but no new jobs will be scheduled on the node. * Quiesced indicates that the node is quiescent. The node is available to DB2 Query Patroller but no new jobs are being scheduled to that node. Status Requested Indicates what the node status will be changed to: * Active indicates that the node will be made active. * Inactive indicates that the node will be made inactive. Running jobs will complete and no new jobs will be scheduled. * Force indicates that the node will be made inactive immediately. Running jobs are terminated immediately and no new jobs will be scheduled. * Quiesced indicates that the node will be made quiescent. Running jobs will complete. Date/Time Last Status Indicates the date and time node status was last changed. Scheduled Jobs Provides the number of jobs scheduled to run plus the number of jobs running on this node. CPU Utilization Provides the CPU utilization of the node as a percentage (0 - 100). If CPU utilization information is not being collected, the value is -1. Disk Available Indicates the bytes available in the file system where results are created. If disk utilization is not being monitored, the value is -1. Node Manager PID Indicates the process ID of the node manager process. Migrating from Version 6 of DB2 Query Patroller Using dqpmigrate The dqpmigrate command must be used if the Version 7 Query Patroller Server was installed over the Version 6 Query Patroller Server. For FixPak 2 or later, you do not have to run dqpmigrate manually as the installation of the FixPak runs this command for you. Without using this command, the existing users defined in v6 have no EXECUTE privileges on several new stored procedures added in Version 7. : dqpmigrate.bnd is found in the sqllib/bnd directory and dqpmigrate.exe is found in the sqllib/bin directory. To use dqpmigrate manually to grant the EXECUTE privileges, perform the following after installing the FixPak: 1. Bind the /sqllib/bnd/dqpmigrate.bnd package file to the database where the Query Patroller server has been installed by entering the following command: db2 bind dqpmigrate.bnd 2. Execute dqpmigrate by entering the following: dqpmigrate dbalias userid passwd Enabling Query Management In the "Getting Started" chapter under "Enabling Query Management", the text should read: You must be the owner of the data base, or you must have SYSADM, SYSCTRL, or SYSMAINT authority to set database configuration parameters. Location of Table Space for Control Tables In Chapter 1, System Overview, under DB2 Query Patroller Control Tables, the following text is to be added at the end of the section's first paragraph: The table space for the DB2 Query Patroller control tables must reside in a single-node nodegroup, or DB2 Query Patroller will not function properly. New Parameters for dqpstart Command In Chapter 2, Getting Started, under Starting and Stopping DB2 Query Patroller, the following text is to be added following the last paragraph: New Parameters for the dqpstart command: RESTART parameter: Allows the user to replace the host name and/or the node type of the specified node in the dqpnodes.cfg file. DB2 Query Patroller will be started on this node. : Before running the DQPSTART command with the RESTART parameter, ensure the following: 1. DB2 Query Patroller is already stopped on the host that is going to be replaced. 2. DB2 Query Patroller is not already running on the new host. The syntax is as follows: dqpstart nodenum node_num restart hostname server | agent | none ADDNODE parameter: Allows the user to add a new node to the dqpnodes.cfg file. DB2 Query Patroller will be started on this node after the new node entry is added to the dqpnodes.cfg file. The syntax is as follows: dqpstart nodenum node_num addnode hostname server | agent | none DROPNODE parameter: Allows the user to drop a node from the dqnodes.cfg file. DB2 Query Patroller will be stopped on this node before the node entry is dropped from the dqpnodes.cfg file. The syntax is as follows: dqpstop nodenum node_num dropnode New Parameter for iwm_cmd Command A new -v parameter has been added to the iwm_cmd command to allow the user to recover the status of the jobs that were running on the node specified. Only jobs on an inactive node are allowed to be recovered. This command should be issued when there is a node failure and there are some jobs running on that node or being cancelled at the time. Jobs that were in "Running" state will be resubmitted and set back to "Queued" state. Jobs that were in "Cancelling" state will be set to "Cancelled" state. The partial syntax is as follows: >>-iwm_cmd--+-------------------------------+-------------------> '--u--user_id--+--------------+-' '--p--password-' >---v--node_id_to_recover-------------------------------------->< node_id_to_recover Specifies the node on which the jobs are to be recovered. New Registry Variable: DQP_RECOVERY_INTERVAL There is a new registry variable called DQP_RECOVERY_INTERVAL which is used to set the interval of time in minutes that the iwm_scheduler searches for recovery files. The default is 60 minutes. Starting Query Administrator In the "Using QueryAdministrator to Administer DB2 Query Patroller" chapter, instructions are provided for starting QueryAdministrator from the Start menu on Windows. The first step provides the following text: If you are using Windows, you can select DB2 Query Patroller --> QueryAdministrator from the IBM DB2 program group. The text should read: DB2 Query Patroller --> QueryAdmin. User Administration In the "User Administration" section of the "Using QueryAdministrator to Administer DB2 Query Patroller" chapter, the definition for the Maximum Elapsed Time parameter indicates that if the value is set to 0 or -1, the query will always run to completion. This parameter cannot be set to a negative value. The text should indicate that if the value is set to 0 , the query will always run to completion. The Max Queries parameter specifies the maximum number of jobs that the DB2 Query Patroller will run simultaneously. Max Queries must be an integer within the range of 0 to 32767. Data Source Administration In Chapter 3, Using Query Administrator to Administer DB2 Query Patroller, there are some new and changed descriptions for the data source parameters. Static Cost is the DB2 estimated cost of the query in timerons. This cost is stored in the job entry for each job. You can see it as the Estimated Cost when using Query Monitor to look at the job details of a job. Zero Cost Query is the query with a static cost, or estimated cost, of zero. No query actually has an estimated cost of zero (even the very simplest ones have a cost of around 5). Rather, this occurs if a job is submitted with the do not do cost analysis option. You can only choose this option if you have set up the user profile to allow it. In most cases, you will not have your user profiles set up in this way. You should keep this option for superusers like other administrators, selected special users, or yourself. These users can then run whatever queries they want. The system treats queries from these users as zero cost so that the queries are treated as high priority. Cost Time Zero, Cost Time Slope, Cost Time Interval, and Cost Time Min are no longer used. The Cost Factor is the multiplier to convert the Static Cost in timerons is not the cost in the accounting table. The cost in the accounting table is equal to the Static Cost multiplied by the Cost Factor. Creating a Job Queue In the "Job Queue Administration" section of the "Using QueryAdministrator to Administer DB2 Query Patroller" chapter, the screen capture in the steps for "Creating a Job Queue" should be displayed after the second step. The Information about new Job Queue window opens once you click New on the Job Queue Administration page of the QueryAdministrator tool. References to the Job Queues page or the Job Queues tab should read Job Queue Administration page and Job Queue Administration tab, respectively. Job Accounting Table In chapter 11, Monitoring the DB2 Query Patroller System, the section on Job Accounting describes the columns in the Job Accounting table. The table name is IWM.IWM003_JOB_ACCT. Using the Command Line Interface For a user with User authority on the DB2 Query Patroller system to submit a query and have a result table created, the user may require CREATETAB authority on the database. The user does not require CREATETAB authority on the database if the DQP_RES_TBLSPC profile variable is left unset, or if the DQP_RES_TBLSPC profile variable is set to the name of the default table space. The creation of the result tables will succeed in this case because users have the authority to create tables in the default table space. Query Enabler Notes * When using third-party query tools that use a keyset cursor, queries will not be intercepted. In order for Query Enabler to intercept these queries, you must modify the db2cli.ini file to include: [common] DisableKeySetCursor=1 * For AIX clients, please ensure that the environment variable LIBPATH is not set. Library libXext.a, shipped with the JDK, is not compatible with the library in the /usr/lib/X11 subdirectory. This will cause problems with the Query Enabler GUI. DB2 Query Patroller Tracker may Return a Blank Column Page FixPak 3 includes a fix for the DB2 Query Patroller Tracker. The Tracker will now correctly report queries which hit no columns. An example of such a query is "SELECT COUNT(*) FROM ...". Since this kind of query does not hit any column in the table, the Tracker will present a blank page for the column page. This blank column page is not a defect. Additional Information for DB2 Query Patroller Tracker GUI Tool The accounting table is used by the Tracker tool when used to display or analyze historical job data. In order to use Tracker, the administrator must first use Query Administrator to change the Accounting Status on the System Administrator panel to Write To Table. Then, whenever a job completes, extra information is saved in a job accounting table. Next, the administrator must log on to the Query Patroller server as user iwm and run the iwm_tracker (Tracker backend) tool. This tool should be run periodically when the system load is low, or just before when the Tracker tool is used. Finally, when these two tasks are completed, you can run the Tracker GUI tool to view or analyze the job data. If the cost factor is one, which is the default, then the cost displayed for each job using the Tracker is the same value as the cost displayed using Query Monitor. In both cases, the time is in timerons. However, you may want to use other units of value. Suppose you want to bill each user for their use of the system. If, for example, the charge is one dollar for 10 000 timerons of work, then you would enter a cost factor of 0.0001. This has the Tracker converting, storing, and displaying each job's cost in dollars. The Query Patroller Administration Guide discusses dollars per megabyte which is incorrect and should be replaced by dollars per timeron. Query Patroller and Replication Tools Query Patroller Version 7 will intercept the queries of the replication tools (asnapply, asnccp, djra and analyze) and cause these tools to malfunction. A workaround is to disable dynamic query management when running these tools. Improving Query Patroller Performance The following text should appear at the end of Chapter 6, Performance Tuning: Using the BIND Option, INSERT BUF to Improve DB2 Query Patroller Performance By default, DB2 Query Patroller creates result tables to store the results of the queries it manages. To increase the performance of inserts to these result tables, include the INSERT BUF option when binding one of the DB2 Query Patroller bind files. Bind the DB2 Query Patroller bind files to the database as follows: From the DB2_RUNTIME\bnd directory on Windows, or the DB2_RUNTIME/bnd path on UNIX, enter the following commands: db2 connect to database user iwm using password db2 bind @db2qp.lst blocking all grant public db2 bind iwmsx001.bnd insert buf db2 bind @db2qp_sp.lst db2 commit where database is the database the replacement database that will be managed by DB2 Query Patroller, and password is the password for the administrative user account, iwm. Lost EXECUTE Privilege for Query Patroller Users Created in Version 6 Because of some new stored procedures (IWM.DQPGROUP, IWM.DQPVALUR, IWM.DQPCALCT, and IWM.DQPINJOB) added in Query Patroller Version 7, existing users created in Query Patroller Version 6 do not hold the EXECUTE privilege on those packages. An application to automatically correct this problem has been added to FixPak 1. When you try to use DQP Query Admin to modify DQP user information, please do not try to remove existing users from the user list. Query Patroller Restrictions Because of JVM (Java Virtual Machine) platform restrictions, the Query Enabler is not supported on HP-UX and NUMA-Q. In addition, the Query Patroller Tracker is not supported on NUMA-Q. If all of the Query Patroller client tools are required, we recommend the use of a different platform (such as Windows NT) to run these tools against the HP-UX or NUMA-Q server. Appendix B. Troubleshooting DB2 Query Patroller Clients In Appendix B, Troubleshooting DB2 Query Patroller Clients, section: Common Query Enabler Problems, problem #2, the text of the first bullet is replaced with: Ensure that the path setting includes jre. VI g ъ{}o Administrative API Reference (Lլ) db2ArchiveLog (new API) db2ArchiveLog Closes and truncates the active log file for a recoverable database. If user exit is enabled, issues an archive request. v One of the following: * sysadm * sysctrl * sysmaint * dbadm ѝnsu This API automatically establishes a connection to the specified database. If a connection to the specified database already exists, the API will return an error. API J db2ApiDf.h C API yk /* File: db2ApiDf.h */ /* API: Archive Active Log */ SQL_API_RC SQL_API_FN db2ArchiveLog ( db2Uint32 version, void *pDB2ArchiveLogStruct, struct sqlca * pSqlca); typedef struct { char *piDatabaseAlias; char *piUserName; char *piPassword; db2Uint16 iAllNodeFlag; db2Uint16 iNumNodes; SQL_PDB_NODE_TYPE *piNodeList; db2Uint32 iOptions; } db2ArchiveLogStruct P API yk /* File: db2ApiDf.h */ /* API: Archive Active Log */ SQL_API_RC SQL_API_FN db2gArchiveLog ( db2Uint32 version, void *pDB2ArchiveLogStruct, struct sqlca * pSqlca); typedef struct { db2Uint32 iAliasLen; db2Uint32 iUserNameLen; db2Uint32 iPasswordLen; char *piDatabaseAlias; char *piUserName; char *piPassword; db2Uint16 iAllNodeFlag; db2Uint16 iNumNodes; SQL_PDB_NODE_TYPE *piNodeList; db2Uint32 iOptions; } db2ArchiveLogStruct API Ѕ version Input. Specifies the version and release level of the variable passed in as the second parameter, pDB2ArchiveLogStruct. pDB2ArchiveLogStruct Input. A pointer to the db2ArchiveLogStruct structure. pSqlca Output. A pointer to the sqlca structure. iAliasLen Input. A 4-byte unsigned integer representing the length in bytes of the database alias. iUserNameLen A 4-byte unsigned integer representing the length in bytes of the user name. Set to zero if no user name is used. iPasswordLen Input. A 4-byte unsigned integer representing the length in bytes of the password. Set to zero if no password is used. piDatabaseAlias Input. A string containing the database alias (as cataloged in the system database directory) of the database for which the active log is to be archived. piUserName Input. A string containing the user name to be used when attempting a connection. piPassword Input. A string containing the password to be used when attempting a connection. iAllNodeFlag MPP only. Input. Flag indicating whether the operation should apply to all nodes listed in the db2nodes.cfg file. Valid values are: DB2ARCHIVELOG_NODE_LIST Apply to nodes in a node list that is passed in piNodeList. DB2ARCHIVELOG_ALL_NODES Apply to all nodes. piNodeList should be NULL. This is the default value. DB2ARCHIVELOG_ALL_EXCEPT Apply to all nodes except those in the node list passed in piNodeList. iNumNodes MPP only. Input. Specifies the number of nodes in the piNodeList array. piNodeList MPP only. Input. A pointer to an array of node numbers against which to apply the archive log operation. iOptions Input. Reserved for future use. db2ConvMonStream In the Usage Notes, the structure for the snapshot variable datastream type SQLM_ELM_SUBSECTION should be sqlm_subsection. db2DatabasePing (new API) db2DatabasePing - Ping Database Tests the network response time of the underlying connectivity between a client and a database server. This API can be used by an application when a host database server is accessed via DB2 Connect either directly or through a gateway. v None ѝnsu Database API J db2ApiDf.h C API yk /* File: db2ApiDf.h */ /* API: Ping Database */ /* ... */ SQL_API_RC SQL_API_FN db2DatabasePing ( db2Uint32 versionNumber, void *pParmStruct, struct sqlca *pSqlca); /* ... */ typedef SQL_STRUCTURE db2DatabasePingStruct { char iDbAlias[SQL_ALIAS_SZ + 1]; db2Uint16 iNumIterations; db2Uint32 *poElapsedTime; } P API yk /* File: db2ApiDf.h */ /* API: Ping Database */ /* ... */ SQL_API_RC SQL_API_FN db2gDatabasePing ( db2Uint32 versionNumber, void *pParmStruct, struct sqlca *pSqlca); /* ... */ typedef SQL_STRUCTURE db2gDatabasePingStruct { db2Uint16 iDbAliasLength; char iDbAlias[SQL_ALIAS_SZ]; db2Uint16 iNumIterations; db2Uint32 *poElapsedTime; } API Ѕ versionNumber Input. Version and release of the DB2 Universal Database or DB2 Connect product that the application is using. : Constant db2Version710 or higher should be used for DB2 Version 7.1 or higher. pParmStruct Input. A pointer to the db2DatabasePingStruct Structure. iDbAliasLength Input. Length of the database alias name. : This parameter is not currently used. It is reserved for future use. iDbAlias Input. Database alias name. : This parameter is not currently used. It is reserved for future use. iNumIterations Input. Number of test request iterations. The value must be between 1 and 32767 inclusive. poElapsedTime Output. A pointer to an array of 32-bit integers where the number of elements is equal to iNumIterations. Each element in the array will contain the elapsed time in microseconds for one test request iteration. : The application is responsible for allocating the memory for this array prior to calling this API. pSqlca Output. A pointer to the sqlca structure. For more information about this structure, see the Administrative API Reference. ъk`N A database connection must exist before invoking this API, otherwise an error will result. This function can also be invoked using the PING command. For a description of this command, see the Command Reference. db2HistData The following entries should be added to Table 11. Fields in the db2HistData Structure: +-----------------------+----------------------+----------------------+ | Field Name | Data Type | Description | +-----------------------+----------------------+----------------------+ | oOperation | char | See Table 12. | +-----------------------+----------------------+----------------------+ | oOptype | char | See Table 13. | +-----------------------+----------------------+----------------------+ The following table will be added following Table 11. Table 12. Valid event values for oOperation in the db2HistData Structure +-----+-------------+-------------------------+-----------------------+ | Val | Description | C Definition | COBOL/FORTRAN | | ue | | | Definition | +-----+-------------+-------------------------+-----------------------+ | A | add | DB2HISTORY_OP_ADD_TABLE | DB2HIST_OP_ADD_TABLES | | | tablespace | SPACE | PACE | +-----+-------------+-------------------------+-----------------------+ | B | backup | DB2HISTORY_OP_BACKUP | DB2HIST_OP_BACKUP | +-----+-------------+-------------------------+-----------------------+ | C | load-copy | DB2HISTORY_OP_LOAD_COPY | DB2HIST_OP_LOAD_COPY | +-----+-------------+-------------------------+-----------------------+ | D | dropped | DB2HISTORY_OP_DROPPED_T | DB2HIST_OP_DROPPED_TA | | | table | ABLE | BLE | +-----+-------------+-------------------------+-----------------------+ | F | roll | DB2HISTORY_OP_ROLLFWD | DB2HIST_OP_ROLLFWD | | | forward | | | +-----+-------------+-------------------------+-----------------------+ | G | reorganize | DB2HISTORY_OP_REORG | DB2HIST_OP_REORG | | | table | | | +-----+-------------+-------------------------+-----------------------+ | L | load | DB2HISTORY_OP_LOAD | DB2HIST_OP_LOAD | +-----+-------------+-------------------------+-----------------------+ | N | rename | DB2HISTORY_OP_REN_TABLE | DB2HIST_OP_REN_TABLES | | | tablespace | SPACE | PACE | +-----+-------------+-------------------------+-----------------------+ | O | drop | DB2HISTORY_OP_DROP_TABL | DB2HIST_OP_DROP_TABLE | | | tablespace | ESPACE | SPACE | +-----+-------------+-------------------------+-----------------------+ | Q | quiesce | DB2HISTORY_OP_QUIESCE | DB2HIST_OP_QUIESCE | +-----+-------------+-------------------------+-----------------------+ | R | restore | DB2HISTORY_OP_RESTORE | DB2HIST_OP_RESTORE | +-----+-------------+-------------------------+-----------------------+ | S | run | DB2HISTORY_OP_RUNSTATS | DB2HIST_OP_RUNSTATS | | | statistics | | | +-----+-------------+-------------------------+-----------------------+ | T | alter | DB2HISTORY_OP_ALT_TABLE | DB2HIST_OP_ALT_TBS | | | tablespace | SPACE | | +-----+-------------+-------------------------+-----------------------+ | U | unload | DB2HISTORY_OP_UNLOAD | DB2HIST_OP_UNLOAD | +-----+-------------+-------------------------+-----------------------+ The following table will also be added. Table 13. Valid oOptype values db2HistData Structure +--------+--------+--------------------+-----------------------------+ | oOpera | oOptyp | Description | C/COBOL/FORTRAN Definition | | tion | e | | | +--------+--------+--------------------+-----------------------------+ | B | F | Offline | DB2HISTORY_OPTYPE_OFFLINE | | |--------|--------------------|-----------------------------| | | N | Online | DB2HISTORY_OPTYPE_ONLINE | | |--------|--------------------|-----------------------------| | | I | Incremental | DB2HISTORY_OPTYPE_INCR_OFFL | | | | offline | INE | | |--------|--------------------|-----------------------------| | | O | Incremental online | DB2HISTORY_OPTYPE_INCR_ONLI | | | | | NE | | |--------|--------------------|-----------------------------| | | D | Delta offline | DB2HISTORY_OPTYPE_DELTA_OFF | | | | | LINE | | |--------|--------------------|-----------------------------| | | E | Delta online | DB2HISTORY_OPTYPE_DELTA_ONL | | | | | IN | +--------+--------+--------------------+-----------------------------+ | F | E | End of log | DB2HISTORY_OPTYPE_EOL | | |--------|--------------------|-----------------------------| | | P | Point in time | DB2HISTORY_OPTYPE_PIT | +--------+--------+--------------------+-----------------------------+ | L | I | Insert | DB2HISTORY_OPTYPE_INSERT | | |--------|--------------------|-----------------------------| | | R | Replace | DB2HISTORY_OPTYPE_REPLACE | +--------+--------+--------------------+-----------------------------+ | Q | S | Quiesce share | DB2HISTORY_OPTYPE_SHARE | | |--------|--------------------|-----------------------------| | | U | Quiesce update | DB2HISTORY_OPTYPE_UPDATE | | |--------|--------------------|-----------------------------| | | X | Quiesce exclusive | DB2HISTORY_OPTYPE_EXCL | | |--------|--------------------|-----------------------------| | | Z | Quiesce reset | DB2HISTORY_OPTYPE_RESET | +--------+--------+--------------------+-----------------------------+ | R | F | Offline | DB2HISTORY_OPTYPE_OFFLINE | | |--------|--------------------|-----------------------------| | | N | Online | DB2HISTORY_OPTYPE_ONLINE | | |--------|--------------------|-----------------------------| | | I | Incremental | DB2HISTORY_OPTYPE_INCR_OFFL | | | | offline | INE | | |--------|--------------------|-----------------------------| | | O | Incremental | DB2HISTORY_OPTYPE_INCR_ONLI | | | | online | NE | +--------+--------+--------------------+-----------------------------+ | T | C | Add containers | DB2HISTORY_OPTYPE_ADD_CONT | | |--------|--------------------|-----------------------------| | | R | Rebalance | DB2HISTORY_OPTYPE_REB | +--------+--------+--------------------+-----------------------------+ db2HistoryOpenScan The following value will be added to the iCallerAction parameter. DB2HISTORY_LIST_CRT_TABLESPACE Select only the CREATE TABLESPACE and DROP TABLESPACE records that pass the other filters. db2Runstats When the db2Runstats API is collecting statistics on indexes only, then previously collected distribution statistics are retained. Otherwise, the API will drop previously collected distribution statistics. db2GetSnapshot - Get Snapshot The syntax for the db2GetSnapshot API should be as follows: int db2GetSnapshot( unsigned char version; db2GetSnapshotData *data, struct sqlca *sqlca); The parameters described in data are: typedef struct db2GetSnapshotData{ sqlma *piSqlmaData; sqlm_collected *poCollectedData void *poBuffer; db2uint32 iVersion; db2int32 iBufferSize; db2uint8 iStoreResult; db2uint16 iNodeNumber; db2uint32 *poOutputFormat; }db2GetSnapshotData; db2XaGetInfo (new API) db2XaGetInfo - Get Information for Resource Manager Extracts information for a particular resource manager once an xa_open call has been made. v None ѝnsu Database API J sqlxa.h C API yk /* File: sqlxa.h */ /* API: Get Information for Resource Manager */ /* ... */ SQL_API_RC SQL_API_FN db2XaGetInfo ( db2Uint32 versionNumber, void * pParmStruct, struct sqlca * pSqlca); typedef SQL_STRUCTURE db2XaGetInfoStruct { db2int32 iRmid; struct sqlca oLastSqlca; } db2XaGetInfoStruct; API Ѕ versionNumber Input. Specifies the version and release level of the structure passed in as the second parameter, pParmStruct. pParmStruct Input. A pointer to the db2XaGetInfoStruct structure. pSqlca Output. A pointer to the sqlca structure. For more information about this structure, see the Administrative API Reference. iRmid Input. Specifies the resource manager for which information is required. oLastSqlca Output. Contains the sqlca for the last XA API call. : Only the sqlca that resulted from the last failing XA API can be retrieved. db2XaListIndTrans (new API that supercedes sqlxphqr) db2XaListIndTrans - List Indoubt Transactions Provides a list of all indoubt transactions for the currently connected database. d This API affects only the node on which it is issued. v One of the following: * sysadm * dbadm ѝnsu Database API J db2ApiDf.h C API yk /* File: db2ApiDf.h */ /* API: List Indoubt Transactions */ /* ... */ SQL_API_RC SQL_API_FN db2XaListIndTrans ( db2Uint32 versionNumber, void * pParmStruct, struct sqlca * pSqlca); typedef SQL_STRUCTURE db2XaListIndTransStruct { db2XaRecoverStruct * piIndoubtData; db2Uint32 iIndoubtDataLen; db2Uint32 oNumIndoubtsReturned; db2Uint32 oNumIndoubtsTotal; db2Uint32 oReqBufferLen; } db2XaListIndTransStruct; typedef SQL_STRUCTURE db2XaRecoverStruct { sqluint32 timestamp; SQLXA_XID xid; char dbalias[SQLXA_DBNAME_SZ]; char applid[SQLXA_APPLID_SZ]; char sequence_no[SQLXA_SEQ_SZ]; char auth_id[SQL_USERID_SZ]; char log_full; char connected; char indoubt_status; char originator; char reserved[8]; } db2XaRecoverStruct; API Ѕ versionNumber Input. Specifies the version and release level of the structure passed in as the second parameter, pParmStruct. pParmStruct Input. A pointer to the db2XaListIndTransStruct structure. pSqlca Output. A pointer to the sqlca structure. For more information about this structure, see the Administrative API Reference. piIndoubtData Input. A pointer to the application supplied buffer where indoubt data will be returned. The indoubt data is in db2XaRecoverStruct format. The application can traverse the list of indoubt transactions by using the size of the db2XaRecoverStruct structure, starting at the address provided by this parameter. If the value is NULL, DB2 will calculate the size of the buffer required and return this value in oReqBufferLen. oNumIndoubtsTotal will contain the total number of indoubt transactions. The application may allocate the required buffer size and issue the API again. oNumIndoubtsReturned Output. The number of indoubt transaction records returned in the buffer specified by pIndoubtData. oNumIndoubtsTotal Output. The Total number of indoubt transaction records available at the time of API invocation. If the piIndoubtData buffer is too small to contain all the records, oNumIndoubtsTotal will be greater than the total for oNumIndoubtsReturned. The application may reissue the API in order to obtain all records. : This number may change between API invocations as a result of automatic or heuristic indoubt transaction resynchronisation, or as a result of other transactions entering the indoubt state. oReqBufferLen Output. Required buffer length to hold all indoubt transaction records at the time of API invocation. The application can use this value to determine the required buffer size by calling the API with pIndoubtData set to NULL. This value can then be used to allocate the required buffer, and the API can be issued with pIndoubtData set to the address of the allocated buffer. : The required buffer size may change between API invocations as a result of automatic or heuristic indoubt transaction resynchronisation, or as a result of other transactions entering the indoubt state. The application may allocate a larger buffer to account for this. timestamp Output. Specifies the time when the transaction entered the indoubt state. xid Output. Specifies the XA identifier assigned by the transaction manager to uniquely identify a global transaction. dbalias Output. Specifies the alias of the database where the indoubt transaction is found. applid Output. Specifies the application identifier assigned by the database manager for this transaction. sequence_no Output. Specifies the sequence number assigned by the database manager as an extension to the applid. auth_id Output. Specifies the authorization ID of the user who ran the transaction. log_full Output. Indicates whether or not this transaction caused a log full condition. Valid values are: SQLXA_TRUE This indoubt transaction caused a log full condition. SQLXA_FALSE This indoubt transaction did not cause a log full condition. connected Output. Indicates whether or not the application is connected. Valid values are: SQLXA_TRUE The transaction is undergoing normal syncpoint processing, and is waiting for the second phase of the two-phase commit. SQLXA_FALSE The transaction was left indoubt by an earlier failure, and is now waiting for resynchronisation from the transaction manager. indoubt_status Output. Indicates the status of this indoubt transaction. Valid values are: SQLXA_TS_PREP The transaction is prepared. The connected parameter can be used to determine whether the transaction is waiting for the second phase of normal commit processing or whether an error occurred and resynchronisation with the transaction manager is required. SQLXA_TS_HCOM The transaction has been heuristically committed. SQLXA_TS_HROL The transaction has been heuristically rolled back. SQLXA_TS_MACK The transaction is missing commit acknowledgement from a node in a partitioned database. SQLXA_TS_END The transaction has ended at this database. This transaction may be re-activated, committed, or rolled back at a later time. It is also possible that the transaction manager encountered an error and the transaction will not be completed. If this is the case, this transaction requires heuristic actions, because it may be holding locks and preventing other applications from accessing data. ъk`N A typical application will perform the following steps after setting the current connection to the database or to the partitioned database coordinator node: 1. Call db2XaListIndTrans with piIndoubtData set to NULL. This will return values in oReqBufferLen and oNumIndoubtsTotal. 2. Use the returned value in oReqBufferLen to allocate a buffer. This buffer may not be large enough if there are additional indoubt transactions because the initial invocation of this API to obtain oReqBufferLen. The application may provide a buffer larger than oReqBufferLen. 3. Determine if all indoubt transaction records have been obtained. This can be done by comparing oNumIndoubtsReturned to oNumIndoubtTotal. If oNumIndoubtsTotal is greater than oNumIndoubtsReturned, the application can repeat the above steps. Х\ "sqlxhfrg - Forget Transaction Status", "sqlxphcm - Commit an Indoubt Transaction", and "sqlxphrl - Roll Back an Indoubt Transaction" in the Administrative API Reference. Forget Log Record The following information will be added to Appendix F following the MPP Subordinator Prepare section. This log record is written after a rollback of indoubt transactions or after a commit of two-phase commit. The log record is written to mark the end of the transaction and releases any log resources held. In order for the transaction to be forgotten, it must be in a heuristically completed state. 10. Forget Log Record Structure +-----------------------+----------------------+----------------------+ | Description | Type | Offset (Bytes) | +-----------------------+----------------------+----------------------+ | Log header | LogManagerLogRecordH | 0(20) | | | eader | | +-----------------------+----------------------+----------------------+ | time | sqluint64 | 20(8) | +---------------------------------------------------------------------+ | Total Length: 28 bytes | +---------------------------------------------------------------------+ sqlaintp - Get Error Message The following usage note is to be added to the description of this API: In a multi-threaded application, sqlaintp must be attached to a valid context; otherwise, the message text for SQLCODE -1445 cannot be obtained. sqlbctcq - Close Tablespace Container Query Load is not a valid Authorization level for this API. sqleseti - Set Client Information The data values provided with the API can also be accessed by SQL special register. The values in these registers are stored in the database code page. Data values provided with this API are converted to the database code page before being stored in the special registers. Any data value that exceeds the maximum supported size after conversion to the database code page will be truncated before being stored at the server. These truncated values will be returned by the special registers. The original data values will also be stored at the server and are not converted to the database code page. The unconverted values can be returned by calling the sqleqryi API. sqlubkp - Backup Database For the BackupType parameter the SQLUB_FULL value will be replaced by the SQLUB_DB. A backup of all tablespaces in the database will be taken. To support the new incremental backup functionality the SQLUB_INCREMENTAL and SQLUB_DELTA parameters will also be added. An incremental backup image is a copy of all database data which has changed since the most recent successful, full backup. A delta backup image is a copy of all database data that has changed since the most recent successful backup of any type sqlureot - Reorganize Table The following sentence will be added to the Usage Notes: REORGANIZE TABLE cannot use an index that is based on an index extension. sqlurestore - Restore Database For the RestoreType parameter the SQLUD_FULL value will be replaced by the SQLUD_DB. A restore of all table spaces in the database will be taken. This will be run offline. To support the new incremental restore functionality the SQLUD_INCREMENTAL parameter will also be added. An incremental backup image is a copy of all database data which has changed since the most recent successful full backup. Documentation Error Regarding AIX Extended Shared Memory Support (EXTSHM) In "Appendix E. Threaded Applications with Concurrent Access", Note 2 should now read: 2. By default, AIX does not permit 32-bit applications to attach to more than 11 shared memory segments per process, of which a maximum of 10 can be used for local DB2 connections. To use EXTSHM with DB2, do the following: In client sessions: export EXTSHM=ON When starting the DB2 server: export EXTSHM=ON db2set DB2ENVLIST=EXTSHM db2start On EEE, also add the following lines to sqllib/db2profile: EXTSHM=ON export EXTSHM SQLFUPD locklist The name of the token has changed from SQLF_DBTN_LOCKLIST to SQLF_DBTN_LOCK_LIST. The locklist parameter has been changed from a SMALLINT to a 64-bit unsigned INTEGER. The following addition should be made to the table of Updatable Database Configuration Parameters. +-----------------+-----------------+----------------+----------------+ | Parameter Name | Token | Token Value | Data Type | +-----------------+-----------------+----------------+----------------+ | locklist | SQLF_DBTN_LOCK_ | 704 | Uint64 | | | LIST | | | +-----------------+-----------------+----------------+----------------+ The new maximum for this parameter is 524 288. Additionally, in "Chapter 3. Data Structures", Table 53. Updatable Database Configuration Parameters incorrectly lists the token value for dbheap as 701. The correct value is 58. SQLEDBDESC Two values will be added to the list of valid values for SQLDBCSS (defined in sqlenv). They are: SQL_CS_SYSTEM_NLSCHAR Collating sequence from system using the NLS version of compare routines for character types. SQL_CS_USER_NLSCHAR Collating sequence from user using the NLS version of compare routines for character types. ъ{}oU iъs ъ{}oUwgs FixPak 4 @CziHq http://www.ibm.com/software/data/db2/udb/winos2unix/support uWU s PDFCz]iHb CD 񿷜oʪwsѾCzL DB2 Aъ PTF X U478862AYiq CDCziHq http://www.ibm.com/cgi-bin/db2www/data/db2/udb/winos2unix/support/help.d2w/report opuDB2 AvۛTC S/390 zSeries W Linux S/390 zSeries W DB2 for Linux UC@~tG * SuSE v7.0 * SuSE SLES 7 * TurboLinux v6.1 : Ynb SuSE SLES 7 W DB2 у 7Aznw libstdc++ v6.1 compat RPMAѪ SuSE Linux Enterprise Server Developer's Edition CD @ CD W| CD1/suse/a1/compat.rpm Coѝ H root Ѹ˛CYnw RPMAN CD M@ϓC ʪpAYnNѪϓ /mntAHUo˽O˪w RPMG rpm -Uh /mnt/CD1/suse/a1/compat.rpm MߪA ldconfigC Linux Rexx DB2 for Linux for Intel x86 (32 ) Object REXX Interpreter for Linux у 2.1C DB2 for Linux on S/390 Object REXX 2.2.0 for Linux/390C es SQL {ì[`N b UNIX tWATwοʥͪ (pAb DB2 ̔Uъ) $DB2PATH/adm/.fenced άͪOPDsCt~Aoԡ˿ъ 񔑦ѪDsC Y GET ROUTINE PUT ROUTINE @~ ({) LkºQ \AN@ê^~ (SQLSTATE 38000)APE_ժr@_С]ۛTC ʪpAY GET ROUTINE {êWхкO SQL {A|ê^E_ "100, 02000" ժrA "100" M "02000" SQLCODE SQLSTATEAOaкO D]Cуd SQLCODE SQLSTATE ьbݫw w{êWCC Application Development Guide (Lլ) Update Available The Application Development Guide was updated as part of FixPak 4. The latest PDF is available for download online at http://www.ibm.com/software/data/db2/udb/winos2unix/support. The information in these notes is in addition to the updated reference. All updated documentation is also available on CD. This CD can be ordered through DB2 service using the PTF number U478862. Information on contacting DB2 Service is available at http://www.ibm.com/cgi-bin/db2www/data/db2/udb/winos2unix/support/help.d2w/report . Precaution for registering C/C++ routines (UDFs, stored procedures, or methods) on Windows When registering a C or C++ routine (UDF, stored procedure, or method) on Windows(R) operating systems, take the following precaution when identifying a routine body in the CREATE statement's EXTERNAL NAME clause. If you use an absolute path id to identify the routine body, you must append the .dll extension. For example: CREATE PROCEDURE getSalary( IN inParm INT, OUT outParm INT ) LANGUAGE c PARAMETER STYLE sql DYNAMIC RESULT SETS 1 FENCED THREADSAFE RETURNS NULL ON NULL INPUT EXTERNAL NAME 'd:\mylib\myfunc.dll' Correction to "Debugging Stored Procedures in Java" In the section "Preparing to Debug", Chapter 21, you are directed to use the db2dbugd command. This is incorrect. Instead, use the following command: idebug -qdaemon -quiport=portno The default port number is 8000. idebug is a client-side daemon of the IBM Distributed Debugger, and ships with VisualAge for Java, and WebSphere Studio Application Developer. New Requirements for executeQuery and executeUpdate To comply with the J2EE 1.3 standard, the DB2 JDBC driver, as of FixPak 5, no longer allows the use of a non-query statement with executeQuery, nor a query statement with executeUpdate. Attempting to do so will result in one of the following exceptions: * CLI0637E QUERY cannot be found, * CLI0637E UPDATE cannot be found. If the type of statement is unknown, use execute(). JDBC Driver Support for Additional Methods CallableStatement.getBlob() and CallableStatement.getClob() The JDBC driver now supports the methods CallableStatement.getBlob() and CallableStatement.getClob(). Since DB2 does not support LOB locators in stored procedure parameters, enough system memory must be available to hold the maximum possible size of your LOB data, the value specified in CREATE PROCEDURE. An out of memory exception will result if there is not sufficient memory. This support is unavailable for uncataloged stored procedures. Statement.setFetchSize(int rows) and ResultSet.setFetchSize(int rows) The JDBC driver now supports Statement.setFetchSize(int rows) and ResultSet.setFetchSize(int rows). These methods can now be used to improve ResultSet performance. JDBC and 64-bit systems JDBC is not supported for instances or clients using 64-bit addressing. This limitation includes systems running 64-bit DB2 UDB Version 7 for AIX 4.3.3, for AIX 5, for Solaris operating systems, and for HP-UX. However, JDBC is supported on 32-bit instances regardless of whether the system is running the 64-bit or 32-bit version of DB2 UDB. IBM OLE DB Provider for DB2 UDB For information on using the IBM OLE DB Provider for DB2, refer to http://www.ibm.com/software/data/db2/udb/ad/v71/oledb.html. CLI Guide and Reference (Lլ) ъ Run-Time Client s۫wъ{ Run-Time Client ъːs۫wъ{ (JBXBBROB z)AB DB2 CLI |b۫wiHъeNΐsC@˩۫wC zѝъ DB2 Administration Client DB2 Application Development ClientC b۫wiHъoé۫wъ{M DB2 CLI seAѝN˩۫ wMѪisC UApGzъP@~thqA OP DB2 уA{ѻAzѝWsU˺@~tM DB2 уXъ{C Using Static SQL in CLI Applications For more information on using static SQL in CLI applications, see the Web page at: http://www.ibm.com/software/data/db2/udb/staticcli/ Limitations of JDBC/ODBC/CLI Static Profiling JDBC/ODBC/CLI static profiling currently targets straightforward applications. It is not meant for complex applications with many functional components and complex program logic during execution. An SQL statement must have successfully executed for it to be captured in a profiling session. In a statement matching session, unmatched dynamic statements will continue to execute as dynamic JDBC/ODBC/CLI calls. An SQL statement must be identical character-by-character to the one that was captured and bound to be a valid candidate for statement matching. Spaces are significant: for example, "COL = 1" is considered different than "COL=1". Use parameter markers in place of literals to improve match hits. When executing an application with pre-bound static SQL statements, dynamic registers that control the dynamic statement behavior will have no effect on the statements that are converted to static. If an application issues DDL statements for objects that are referenced in subsequent DML statements, you will find all of these statements in the capture file. The JDBC/ODBC/CLI Static Profiling Bind Tool will attempt to bind them. The bind attempt will be successful with DBMSs that support the VALIDATE(RUN) bind option, but it fail with ones that do not. In this case, the application should not use Static Profiling. The Database Administrator may edit the capture file to add, change, or remove SQL statements, based on application-specific requirements. ADT Transforms The following supercedes existing information in the book. * There is a new descriptor type (smallint) SQL_DESC_USER_DEFINED_TYPE_CODE, with values: SQL_TYPE_BASE 0 (this is not a USER_DEFINED_TYPE) SQL_TYPE_DISTINCT 1 SQL_TYPE_STRUCTURED 2 This value can be queried with either SQLColAttribute or SQLGetDescField (IRD only). The following attributes are added to obtain the actual type names: SQL_DESC_REFERENCE_TYPE SQL_DESC_STRUCTURED_TYPE SQL_DESC_USER_TYPE The above values can be queried using SQLColAttribute or SQLGetDescField (IRD only). * Add SQL_DESC_BASE_TYPE in case the application needs it. For example, the application may not recognize the structured type, but intends to fetch or insert it, and let other code deal with the details. * Add a new connection attribute called SQL_ATTR_TRANSFORM_GROUP to allow an application to set the transform group (rather than use the SQL "SET CURRENT DEFAULT TRANSFORM GROUP" statement). * Add a new statement/connection attribute called SQL_ATTR_RETURN_USER_DEFINED_TYPES that can be set or queried using SQLSetConnectAttr, which causes CLI to return the value SQL_DESC_USER_DEFINED_TYPE_CODE as a valid SQL type. This attribute is required before using any of the transforms. * By default, the attribute is off, and causes the base type information to be returned as the SQL type. * When enabled, SQL_DESC_USER_DEFINED_TYPE_CODE will be returned as the SQL_TYPE. The application is expected to check for SQL_DESC_USER_DEFINED_TYPE_CODE, and then to retrieve the appropriate type name. This will be available to SQLColAttribute, SQLDescribeCol, and SQLGetDescField. * The SQLBindParameter does not give an error when you bind SQL_C_DEFAULT, because there is no code to allow SQLBindParameter to specify the type SQL_USER_DEFINED_TYPE. The standard default C types will be used, based on the base SQL type flowed to the server. For example: sqlrc = SQLBindParameter (hstmt, 2, SQL_PARAM_INPUT, SQL_C_CHAR, SQL_VARCHAR, 30, 0, &c2, 30, NULL); Chapter 1. Introduction to CLI Differences Between DB2 CLI and Embedded SQL Disregard the third item from the end of the list in the "Advantages of Using DB2 CLI" section. The correct information is as follows: DB2 CLI provides the ability to retrieve multiple rows and result sets generated from a stored procedure residing on a DB2 Universal Database server, a DB2 for MVS/ESA server (Version 5 or later), or an OS/400 server (Version 5 or later). Support for multiple result sets retrieval on OS/400 requires that PTF (Program Temporary Fix) SI01761 be applied to the server. Contact your OS/400 system administrator to ensure that this PTF has been applied. Chapter 3. Using Advanced Features Writing Multi-Threaded Applications The following should be added to the end of the "Multi-Threaded Mixed Applications" section: : It is recommended that you do not use the default stack size, but instead increase the stack size to at least 256 000. DB2 requires a minimum stack size of 256 000 when calling a DB2 function. You must ensure therefore, that you allocate a total stack size that is large enough for both your application and the minimum requirements for a DB2 function call. Writing a DB2 CLI Unicode Application The following is a new section for this chapter. There are two main areas of support for DB2 CLI Unicode Applications: 1. The addition of a set of functions that can accept Unicode string arguments in place of ANSI string arguments. 2. The addition of new C and SQL data types to describe Unicode data. The following sections provide more information for both of these areas. To be considered a Unicode application, the application must set the SQL_ATTR_ANSI_APP connection attribute to SQL_AA_FALSE, before a connection is made. This will ensure that the CLI will use Unicode as the preferred method of communication between itself and the database. Unicode Functions ODBC API functions have suffixes to indicate the format of their string arguments: those that accept unicode end in W; those that accept ANSI have no suffix. : ODBC adds equivalent functions with names that end in A, but these are not used by DB2 CLI. The following is a list of those functions that are available in DB2 CLI, which have both ANSI and Unicode Versions. SQLBrowseConnect SQLForeignKeys SQLPrimaryKeys SQLColAttribute SQLGetConnectAttr SQLProcedureColumns SQLColAttributes SQLGetConnectOption SQLProcedures SQLColumnPrivileges SQLGetCursorName SQLSetConnectAttr SQLColumns SQLGetDescField SQLSetConnectOption SQLConnect SQLGetDescRec SQLSetCursorName SQLDataSources SQLGetDiagField SQLSetDescField SQLDescribeCol SQLGetDiagRec SQLSetStmtAttr SQLDriverConnect SQLGetInfo SQLSpecialColumns SQLGetStmtAttr SQLStatistics SQLError SQLNativeSQL SQLTablePrivileges SQLExecDirect SQLPrepare SQLTables Unicode functions whose arguments are always the length of strings interpret these arguments as count-of-characters. Functions that return length information for server data also describe the display size and precision in terms of characters. When the length (transfer size of the data) could refer to string or nonstring data, the length is interpreted as a count of bytes. For example, SQLGetInfoW will still take the length as count-of-bytes, but SQLExecDirectW will use count-of-characters. CLI will return data from result sets in either Unicode or ANSI, depending on the application's binding. If an application binds to SQL_C_CHAR, the driver will convert SQL_WCHAR data to SQL_CHAR. An ODBC driver manager, if used, maps SQL_C_WCHAR to SQL_C_CHAR for ANSI drivers but does no mapping for Unicode drivers. New datatypes and Valid Conversions Additional ODBC and CLI defined data types have been added to accommodate Unicode databases. These types supplement the set of C and SQL types that already exist. The new C type, SQL_C_WCHAR, indicates that the C buffer contains UCS-2 data in native endian format. The new SQL types, SQL_WCHAR, SQL_WVARCHAR, and SQL_WLONGVARCHAR, indicate that a particular column or parameter marker contains Unicode data. For DB2 Unicode databases, graphic columns will be described using the new types. 11. Supported Data Conversions +----------------+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+----+ | SQL Data Type | S | S | S | S | S | S | S | S | S | S | S | S | S | S | S | S | S | S | | | Q | Q | Q | Q | Q | Q | Q | Q | Q | Q | Q | Q | Q | Q | Q | Q | Q | Q | | | L | L | L | L | L | L | L | L | L | L | L | L | L | L | L | L | L | L | | | _ | _ | _ | _ | _ | _ | _ | _ | _ | _ | _ | _ | _ | _ | _ | _ | _ | _ | | | C | C | C | C | C | C | C | C | C | C | C | C | C | C | C | C | C | C | | | _ | _ | _ | _ | _ | _ | _ | _ | _ | _ | _ | _ | _ | _ | _ | _ | _ | _ | | | C | W | L | S | T | F | D | T | T | T | B | B | D | C | B | D | B | N | | | H | C | O | H | I | L | O | Y | Y | Y | I | I | B | L | L | B | I | U | | | A | H | N | O | N | O | U | P | P | P | N | T | C | O | O | C | G | M | | | R | A | G | R | Y | A | B | E | E | E | A | | H | B | B | L | I | E | | | | R | | T | I | T | L | _ | _ | _ | R | | A | _ | _ | O | N | R | | | | | | | N | | E | D | T | T | Y | | R | L | L | B | T | I | | | | | | | T | | | A | I | I | | | | O | O | _ | | C | | | | | | | | | | T | M | M | | | | C | C | L | | | | | | | | | | | | E | E | E | | | | A | A | O | | | | | | | | | | | | | | S | | | | T | T | C | | | | | | | | | | | | | | T | | | | O | O | A | | | | | | | | | | | | | | A | | | | R | R | T | | | | | | | | | | | | | | M | | | | | | O | | | | | | | | | | | | | | P | | | | | | R | | | +----------------+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+----+ | BLOB | X | X | | | | | | | | | D | | | | X | | | | +----------------+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+----+ | CHAR | D | X | X | X | X | X | X | X | X | X | X | X | | | | | X | X | +----------------+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+----+ | CLOB | D | X | | | | | | | | | X | | | X | | | | | +----------------+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+----+ | DATE | X | X | | | | | | D | | X | | | | | | | | | +----------------+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+----+ | DBCLOB | | X | | | | | | | | | X | | D | | | X | | | +----------------+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+----+ | DECIMAL | D | X | X | X | X | X | X | | | | X | X | | | | | X | X | +----------------+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+----+ | DOUBLE | X | X | X | X | X | X | D | | | | | X | | | | | X | X | +----------------+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+----+ | FLOAT | X | X | X | X | X | X | D | | | | | X | | | | | X | X | +----------------+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+----+ | GRAPHIC | X | X | | | | | | | | | | | D | | | | | | | (Non-Unicode) | | | | | | | | | | | | | | | | | | | +----------------+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+----+ | GRAPHIC | X | X | X | X | X | X | X | X | X | X | X | X | D | | | | X | | | (Unicode) | | | | | | | | | | | | | | | | | | | +----------------+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+----+ | INTEGER | X | X | D | X | X | X | X | | | | | X | | | | | X | X | +----------------+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+----+ | LONG | D | X | | | | | | | | | X | | | | | | | | | VARCHAR | | | | | | | | | | | | | | | | | | | +----------------+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+----+ | LONG | X | X | | | | | | | | | X | | D | | | | | | | VARGRAPHIC | | | | | | | | | | | | | | | | | | | | (Non-Unicode) | | | | | | | | | | | | | | | | | | | +----------------+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+----+ | LONG | X | X | | | | | | | | | X | | D | | | | | | | VARGRAPHIC | | | | | | | | | | | | | | | | | | | | (Unicode) | | | | | | | | | | | | | | | | | | | +----------------+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+----+ | NUMERIC | D | X | X | X | X | X | X | | | | | X | | | | | | X | +----------------+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+----+ | REAL | X | X | X | X | X | D | X | | | | | X | | | | | | X | +----------------+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+----+ | SMALLINT | X | X | X | D | X | X | X | | | | | X | | | | | X | X | +----------------+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+----+ | BIGINT | X | X | X | X | X | X | X | | | | X | X | | | | | D | X | +----------------+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+----+ | TIME | X | X | | | | | | | D | X | | | | | | | | | +----------------+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+----+ | TIMESTAMP | X | X | | | | | | X | X | D | | | | | | | | | +----------------+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+----+ | VARCHAR | D | X | X | X | X | X | X | X | X | X | X | X | | | | | X | X | +----------------+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+----+ | VARGRAPHIC | X | X | | | | | | | | | | | D | | | | | | | (Non-Unicode) | | | | | | | | | | | | | | | | | | | +----------------+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+----+ | VARGRAPHIC | X | X | X | X | X | X | X | X | X | X | X | X | D | | | | X | | | (Unicode) | | | | | | | | | | | | | | | | | | | +----------------+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+-----+----+ : D Conversion is supported. This is the default conversion for the SQL data type. X All IBM DBMSs support the conversion. blank No IBM DBMS supports the conversion. * Data is not converted to LOB Locator types, rather locators represent a data value, refer to Using Large Objects for more information. * SQL_C_NUMERIC is only available on 32-bit Windows operating systems. Obsolete Keyword/Patch Value Before Unicode applications were supported, applications that were written to work with single-byte character data could be made to work with double-byte graphic data by a series of cli ini file keywords, such as GRAPHIC=1,2 or 3, Patch2=7. These workarounds presented graphic data as character data, and also affected the reported length of the data. These keywords are no longer required for Unicode applications, and should not be used due to the risk of potential side effects. If it is not known if a particular application is a Unicode application, we suggest you try without any of the keywords that affect the handling of graphic data. Literals in Unicode Databases In non-unicode databases, data in LONG VARGRAPHIC and LONG VARCHAR columns cannot be compared. Data in GRAPHIC/VARGRAPHIC and CHAR/VARCHAR columns can only be compared, or assigned to each other, using explicit cast functions since no implicit code page conversion is supported. This includes GRAPHIC/VARGRAPHIC and CHAR/VARCHAR literals where a GRAPHIC/VARGRAPHIC literal is differentiated from a CHAR/VARCHAR literal by a G prefix. For Unicode databases, casting between GRAPHIC/VARGRAPHIC and CHAR/VARCHAR literals is not required. Also, a G prefix is not required in front of a GRAPHIC/VARGRAPHIC literal. Provided at least one of the arguments is a literal, implicit conversions occur. This allows literals with or without the G prefix to be used within statements that use either SQLPrepareW() or SQLExecDirect(). Literals for LONG VARGRAPHICs still must have a G prefix. For more information, see "Casting Between Data Types" in "Chapter 3. Language Elements" of the SQL Reference. New CLI Configuration Keywords The following three keywords have been added to avoid any extra overhead when Unicode applications connect to a database. 1. DisableUnicode Keyword Description: Disables the underlying support for Unicode. db2cli.ini Keyword Syntax: DisableUnicode = 0 | 1 Default Setting: 0 (false) DB2 CLI/ODBC Settings Tab: This keyword cannot be set using the CLI/ODBC Settings notebook. The db2cli.ini file must be modified directly to make use of this keyword. Usage Notes: With Unicode support enabled, and when called by a Unicode application, CLI will attempt to connect to the database using the best client code page possible to ensure there is no unnecessary data loss due to code page conversion. This may increase the connection time as code pages are exchanged, or may cause code page conversions on the client that did not occur before this support was added. Setting this keyword to True (1) will cause all Unicode data to be converted to the application's local code page first, before the data is sent to the server. This can cause data loss for any data that cannot be represented in the local code page. 2. ConnectCodepage Keyword Description: Specifies a specific code page to use when connecting to the data source to avoid extra connection overhead. db2cli.ini Keyword Syntax: ConnectCodepage = 0 | 1 | Default Setting: 0 DB2 CLI/ODBC Settings Tab: This keyword cannot be set using the CLI/ODBC Settings notebook. The db2cli.ini file must be modified directly to make use of this keyword. Usage Notes: Non-Unicode applications always connect to the database using the application's local code page, or the DB2Codepage environment setting. By default, CLI will ensure that Unicode applications will connect to Unicode databases using UTF-8 and UCS-2 code pages. The default for connecting to non-unicode databases is to use the databases's code page if the database server is running DB2 for Windows, DB2 for Unix or DB2 for OS/2. This ensures that there is no unnecessary data loss due to code page conversion. This keyword allows the user to specify the database's code page when connecting to a non-Unicode database in order to avoid any extra overhead on the connection. Specifying a value of 1 causes SQLDriverConnect() to return the correct value in the output connection string, so the value can be used on future SQLDriverConnect() calls. 3. UnicodeServer Keyword Description: Indicates that the data source is a unicode server. Equivalent to setting ConnectCodepage=1208. db2cli.ini Keyword Syntax: UnicodeServer = 0 | 1 Default Setting: 0 DB2 CLI/ODBC Settings Tab: This keyword cannot be set using the CLI/ODBC Settings notebook. The db2cli.ini file must be modified directly to make use of this keyword. Usage Notes: This keyword is equivalent to ConnectCodepage=1208, and is added only for convenience. Set this keyword to avoid extra connect overhead when connecting to DB2 for OS/390 Version 7 or higher. There is no need to set this keyword for DB2 for Windows, DB2 for Unix or DB2 for OS/2 databases, since there is no extra processing required. Microsoft Transaction Server (MTS) as Transaction Monitor The following corrects the default value for the DISABLEMULTITHREAD configuration keyword in the "Installation and Configuration" sub-section: * DISABLEMULTITHREAD keyword (default 0) Scrollable Cursors The following information should be added to the "Scrollable Cursors" section: Server-side Scrollable Cursor Support for OS/390 The UDB client for the Unix, Windows, and OS/2 platforms supports updatable server-side scrollable cursors when run against OS/390 Version 7 databases. To access an OS/390 scrollable cursor on a three-tier environment, the client and the gateway must be running DB2 UDB Version 7.1, FixPak 3 or later. There are two application enablement interfaces that can access scrollable cursors: ODBC and JDBC. The JDBC interface can only access static scrollable cursors, while the ODBC interface can access static and keyset-driven server-side scrollable cursors. Cursor Attributes The table below lists the default attributes for OS/390 Version 7 cursors in ODBC. 12. Default attributes for OS/390 cursors in ODBC +-------------+-------------+-------------+-------------+-------------+ | Cursor Type | Cursor | Cursor | Cursor | Cursor | | | Sensitivity | Updatable | Concurrency | Scrollable | +-------------+-------------+-------------+-------------+-------------+ | forward-onl | unspecified | non-updatab | read-only | non-scrolla | | ya | | le | concurrency | ble | +-------------+-------------+-------------+-------------+-------------+ | static | insensitive | non-updatab | read-only | scrollable | | | | le | concurrency | | +-------------+-------------+-------------+-------------+-------------+ | keyset-driv | sensitive | updatable | values | scrollable | | en | | | concurrency | | +---------------------------------------------------------------------+ | | | a Forward-only is the default behavior for a scrollable | | cursor without the FOR UPDATE clause. Specifying FOR UPDATE on | | a forward-only cursor creates an updatable, lock concurrency, | | non-scrollable cursor. | +---------------------------------------------------------------------+ Supported Fetch Orientations All ODBC fetch orientations are supported via the SQLFetchScroll or SQLExtendedFetch interfaces. Updating the Keyset-Driven Cursor A keyset-driven cursor is an updatable cursor. The CLI driver appends the FOR UPDATE clause to the query, except when the query is issued as a SELECT ... FOR READ ONLY query, or if the FOR UPDATE clause already exists. The keyset-driven cursor implemented in DB2 for OS/390 is a values concurrency cursor. A values concurrency cursor results in optimistic locking, where locks are not held until an update or delete is attempted. When an update or delete is attempted, the database server compares the previous values the application retrieved to the current values in the underlying table. If the values match, then the update or delete succeeds. If the values do not match, then the operation fails. If failure occurs, the application should query the values again and re-issue the update or delete if it is still applicable. An application can update a keyset-driven cursor in two ways: * Issue an UPDATE WHERE CURRENT OF "" or DELETE WHERE CURRENT OF "" using SQLPrepare() with SQLExecute() or SQLExecDirect(). * Use SQLSetPos() or SQLBulkOperations() to update, delete, or add a row to the result set. : Rows added to a result set via SQLSetPos() or SQLBulkOperations() are inserted into the table on the server, but are not added to the server's result set. Therefore, these rows are not updatable nor are they sensitive to changes made by other transactions. The inserted rows will appear, however, to be part of the result set, since they are cached on the client. Any triggers that apply to the inserted rows will appear to the application as if they have not been applied. To make the inserted rows updatable, sensitive, and to see the result of applicable triggers, the application must issue the query again to regenerate the result set. Troubleshooting for Applications Created Before Scrollable Cursor Support Since scrollable cursor support is new, some ODBC applications that were working with previous releases of UDB for OS/390 or UDB for Unix, Windows, and OS/2 may encounter behavioral or performance changes. This occurs because before scrollable cursors were supported, applications that requested a scrollable cursor would receive a forward-only cursor. To restore an application's previous behavior before scrollable cursor support, set the following configuration keywords in the db2cli.ini file: 13. Configuration keyword values restoring application behavior before scrollable cursor support +----------------------+----------------------------------------------+ | Configuration | Description | | Keyword Setting | | +----------------------+----------------------------------------------+ | PATCH2=6 | Returns a message that scrollable cursors | | | (both keyset-driven and static) are not | | | supported. CLI automatically downgrades any | | | request for a scrollable cursor to a | | | forward-only cursor. | +----------------------+----------------------------------------------+ | DisableKeysetCursor= | Disables both the server-side and | | 1 | client-side keyset-driven scrollable | | | cursors. This can be used to force the CLI | | | driver to give the application a static | | | cursor when a keyset-driven cursor is | | | requested. | +----------------------+----------------------------------------------+ | UseServerKeysetCurso | Disables the server-side keyset-driven | | r=0 | cursor for applications that are using the | | | client-side keyset-driven cursor library to | | | simulate a keyset-driven cursor. Only use | | | this option when problems are encountered | | | with the server-side keyset-driven cursor, | | | since the client-side cursor incurs a large | | | amount of overhead and will generally have | | | poorer performance than a server-side | | | cursor. | +----------------------+----------------------------------------------+ Using Compound SQL The following note is missing from the book: Any SQL statement that can be prepared dynamically, other than a query, can be executed as a statement inside a compound statement. Note: Inside Atomic Compound SQL, savepoint, release savepoint, and rollback to savepoint SQL statements are also disallowed. Conversely, Atomic Compound SQL is disallowed in savepoint. Using Stored Procedures Privileges for building and debugging SQL and Java stored procedures The following privileges must be granted to users who want to build, debug, and run SQL stored procedures: * db2 grant CONNECT on database to userid * db2 grant IMPLICIT_SCHEMA on database to userid * db2 grant BINDADD on database to userid * db2 grant SELECT on SYSIBM.SYSDUMMY1 to userid * db2 grant SELECT on SYSCAT.PROCEDURES to userid * db2 grant UPDATE on DB2DBG.ROUTINE_DEBUG to userid The following privileges must be granted to users who want to build, debug, and run Java stored procedures: * db2 grant CONNECT on database to userid * db2 grant IMPLICIT_SCHEMA on database to userid * db2 grant BINDADD on database to userid(required only if you build Java stored procedures with static SQL using SQLJ) * db2 grant SELECT on SYSIBM.SYSDUMMY1 to userid * db2 grant SELECT on SYSCAT.PROCEDURES to userid * db2 grant UPDATE on DB2DBG.ROUTINE_DEBUG to userid To create the DB2DBG.ROUTINE_DEBUG table, issue the following command: db2 -tf sqllib/misc/db2debug.ddl For more information about debugging Java stored procedures, see the Application Development Guide. Writing a Stored Procedure in CLI Following is an undocumented limitation on CLI stored procedures: If you are making calls to multiple CLI stored procedures, the application must close the open cursors from one stored procedure before calling the next stored procedure. More specifically, the first set of open cursors must be closed before the next stored procedure tries to open a cursor. CLI Stored Procedures and Autobinding The following supplements information in the book: The CLI/ODBC driver will normally autobind the CLI packages the first time a CLI/ODBC application executes SQL against the database, provided the user has the appropriate privilege or authorization. Autobinding of the CLI packages cannot be performed from within a stored procedure, and therefore will not take place if the very first thing an application does is call a CLI stored procedure. Before running a CLI application that calls a CLI stored procedure against a new DB2 database, you must bind the CLI packages once with this command: UNIX db2 bind /@db2cli.lst blocking all Windows and OS/2 db2bind "%DB2PATH%\bnd\@db2cli.lst" blocking The recommended approach is to always bind these packages at the time the database is created to avoid autobind at runtime. Autobind can fail if the user does not have privilege, or if another application tries to autobind at the same time. Chapter 4. Configuring CLI/ODBC and Running Sample Applications Configuration Keywords CURRENTFUNCTIONPATH Disregard the last paragraph in the CURRENTFUNCTIONPATH keyword. The correct information is as follows: This keyword is used as part of the process for resolving unqualified function and stored procedure references that may have been defined in a schema name other than the current user's schema. The order of the schema names determines the order in which the function and procedure names will be resolved. For more information on function and procedure resolution, refer to the SQL Reference. SKIPTRACE The following describes this new configuration keyword: Keyword Description: Allows CLI applications to be excluded from the trace function. db2cli.ini Keyword Syntax: SKIPTRACE = 0 | 1 Default Setting: Do not skip the trace function. DB2 CLI/ODBC Settings Tab: This keyword cannot be set using the CLI/ODBC Settings notebook. The db2cli.ini file must be modified directly to make use of this keyword. Usage Notes: This keyword can improve performance by allowing the trace function to bypass CLI applications. Therefore, if the DB2 trace facility db2trc is turned on and this keyword is set to 1, the trace will not contain information from the execution of the CLI application. Turning SKIPTRACE on is recommended for production environments on the UNIX platform where trace information is not required. Test environments may benefit, however, from having trace output, so this keyword can be turned off (or left at its default setting) when detailed execution information is desired. SKIPTRACE must be set in the [COMMON] section of the db2cli.ini configuration file. Chapter 5. DB2 CLI Functions SQLBindFileToParam - Bind LOB File Reference to LOB Parameter The last parameter - IndicatorValue - in the SQLBindFileToParam() CLI function is currently documented as "output (deferred)". It should be "input (deferred)". SQLColAttribute -- Return a Column Attribute The following updates are additions to the "Description" column for the SQL_DESC_AUTO_UNIQUE_VALUE and SQL_DESC_UPDATABLE arguments: SQL_DESC_AUTO_UNIQUE_VALUE SQL_FALSE is returned in NumericAttributePtr for all DB2 SQL data types. Currently DB2 CLI is not able to determine if a column is an identity column, therefore SQL_FALSE is always returned. This limitation does not fully conform to the ODBC specifications. Future versions of DB2 CLI for Unix and Windows servers will provide auto-unique support. SQL_DESC_UPDATABLE Indicates if the column data type is an updateable data type: * SQL_ATTR_READWRITE_UNKNOWN is returned in NumericAttributePtr for all DB2 SQL data types. It is returned because DB2 CLI is not currently able to determine if a column is updateable. Future versions of DB2 CLI for Unix and Windows servers will be able to determine if a column is updateable. SQLGetData - Get Data From a Column The following text replaces the current sentence that appears under the Explanation column for SQLSTATE 22007 of the SQLSTATEs table for SQLGetData: Conversion from a string to a datetime format was indicated, but an invalid string representation or value was specified, or the value was an invalid date. SQLGetInfo - Get General Information The following corrects the information in the "Usage" section under "Information Returned by SQLGetInfo": * The InfoType SQL_CURSOR_CLOSE_BEHAVIOR should be SQL_CLOSE_BEHAVIOR. * The note for SQL_DATABASE_NAME (string) should be as follows: : This string is the same as that returned by the SELECT CURRENT SERVER statement on non-host systems. For host databases, such as DB2 for OS/390 or DB2 for OS/400, the string returned is the DCS database name that was provided when the CATALOG DCS DATABASE DIRECTORY command was issued at the DB2 Connect gateway. SQLGetLength - Retrieve Length of A String Value The following corrects the footnote in "Table 113. SQLGetLength Arguments" : Note: a This is in characters for DBCLOB data. SQLNextResult - Associate Next Result Set with Another Statement Handle The following text should be added to Chapter 5, "DB2 CLI Functions": Purpose Specification: DB2 CLI 7.x Syntax SQLRETURN SQLNextResult (SQLHSTMT StatementHandle1 SQLHSTMT StatementHandle2); Function Arguments 14. SQLNextResult Arguments +-----------+---------------+--------+--------------------------------+ | Data Type | Argument | Use | Description | +-----------+---------------+--------+--------------------------------+ | SQLHSTMT | StatementHand | input | Statement handle. | | | le | | | +-----------+---------------+--------+--------------------------------+ | SQLHSTMT | StatementHand | input | Statement handle. | | | le | | | +-----------+---------------+--------+--------------------------------+ Usage A stored procedure returns multiple result sets by leaving one or more cursors open after exiting. The first result set is always accessed by using the statement handle that called the stored procedure. If multiple result sets are returned, either SQLMoreResults() or SQLNextResult() can be used to describe and fetch the result set. SQLMoreResults() is used to close the cursor for the first result set and allow the next result set to be processed, whereas SQLNextResult() moves the next result set to StatementHandle2, without closing the cursor on StatementHandle1. Both functions return SQL_NO_DATA_FOUND if there are no result sets to be fetched. Using SQLNextResult() allows result sets to be processed in any order once they have been transferred to other statement handles. Mixed calls to SQLMoreResults() and SQLNextResult() are allowed until there are no more cursors (open result sets) on StatementHandle1. When SQLNextResult() returns SQL_SUCCESS, the next result set is no longer associated with StatementHandle1. Instead, the next result set is associated with StatementHandle2, as if a call to SQLExecDirect() had just successfully executed a query on StatementHandle2. The cursor, therefore, can be described using SQLNumResultSets(), SQLDescribeCol(), or SQLColAttribute(). After SQLNextResult() has been called, the result set now associated with StatementHandle2 is removed from the chain of remaining result sets and cannot be used again in either SQLNextResult() or SQLMoreResults(). This means that for 'n' result sets, SQLNextResult() can be called successfully at most 'n-1' times. If SQLFreeStmt() is called with the SQL_CLOSE option, or SQLFreeHandle() is called with HandleType set to SQL_HANDLE_STMT, all pending result sets on this statement handle are discarded. SQLNextResult() returns SQL_ERROR if StatementHandle2 has an open cursor or StatementHandle1 and StatementHandle2 are not on the same connection. If any errors or warnings are returned, SQLError() must always be called on StatementHandle1. : SQLMoreResults() also works with a parameterized query with an array of input parameter values specified with SQLParamOptions() and SQLBindParameter(). SQLNextResult(), however, does not support this. Return Codes * SQL_SUCCESS * SQL_SUCCESS_WITH_INFO * SQL_STILL_EXECUTING * SQL_ERROR * SQL_INVALID_HANDLE * SQL_NO_DATA_FOUND Diagnostics 15. SQLNextResult SQLSTATEs +--------+-------------------+----------------------------------------+ | SQLSTA | Description | Explanation | | TE | | | +--------+-------------------+----------------------------------------+ | 40003 | Communication | The communication link between the | | 08S01 | Link failure. | application and data source failed | | | | before the function completed. | +--------+-------------------+----------------------------------------+ | 58004 | Unexpected system | Unrecoverable system error. | | | failure. | | +--------+-------------------+----------------------------------------+ | HY001 | Memory allocation | DB2 CLI is unable to allocate the | | | failure. | memory required to support execution | | | | or completion of the function. | +--------+-------------------+----------------------------------------+ | HY010 | Function sequence | The function was called while in a | | | error. | data-at-execute | | | | (SQLParamData(), SQLPutData()) | | | | operation. | | | | | | | | StatementHandle2 has an open cursor | | | | associated with it. | | | | | | | | The function was called while within a | | | | BEGIN COMPOUND and END COMPOUND SQL | | | | operation. | +--------+-------------------+----------------------------------------+ | HY013 | Unexpected memory | DB2 CLI was unable to access the | | | handling error. | memory required to support execution | | | | or completion of the function. | +--------+-------------------+----------------------------------------+ | HYT00 | Time-out expired. | The time-out period expired before the | | | | data source returned the result | | | | set. Time-outs are only supported on | | | | non-multitasking systems such as | | | | Windows 3.1 and Macintosh System | | | | 7. The time-out period can be set | | | | using the SQL_ATTR_QUERY_TIMEOUT | | | | attribute for SQLSetConnectAttr(). | +--------+-------------------+----------------------------------------+ Restrictions Only SQLMoreResults() can be used for parameterized queries. References * "SQLMoreResults - Determine If There Are More Result Sets" on page 535 * "Returning Result Sets from Stored Procedures" on page 120 SQLSetEnvAttr - Set Environment Attribute The following is an additional environment attribute that belongs in the "Environment Attributes" section under "Usage": SQL_ATTR_KEEPCTX A 32-bit integer value that specifies whether the context should be kept when the environment handle is freed. This attribute should be set at the environment level. It can be used by mutli-threaded applications to manage contexts associated with each thread's connections, database resources, and data transmission. The possible values are: * SQL_FALSE: The application will release the context when a thread's environment handle is freed. This is the default value. * SQL_TRUE: The context will remain valid when a thread's environment handle is freed, making the context available for other existing threads on the same connection. Setting SQL_ATTR_KEEPCTX to SQL_TRUE may resolve some problems associated with conflicting contexts in multi-threaded applications. : This is an IBM extension. SQLSetStmtAttr -- Set Options Related to a Statement The following replaces the existing information for the statement attribute SQL_ATTR_QUERY_TIMEOUT: SQL_ATTR_QUERY_TIMEOUT (DB2 CLI v2) A 32-bit integer value that is the number of seconds to wait for an SQL statement to execute between returning to the application. This option can be set and used to terminate long running queries. The value of 0 means there is no time out. DB2 CLI supports non-zero values for all platforms that support multithreading. Appendix C. DB2 CLI and ODBC The following is a new section added to this appendix. ODBC Unicode Applications A Unicode ODBC application sends and retrieves character data primarily in UCS-2. It does this by calling Unicode versions of the ODBC functions (those with a 'W' suffix) and by indicating Unicode data types. The application does not explicitly specify a local code page. The application can still call the ANSI functions and pass local code page strings. For example, the application may call SQLConnectW() and pass the DSN, User ID and Password as Unicode arguments. It may then call SQLExecDirectW() and pass in a Unicode SQL statement string, and then bind a combination of ANSI local code page buffers (SQL_C_CHAR) and Unicode buffers (SQL_C_WCHAR). The database data types may or may not be Unicode. If a CLI application calls SQLSetConnectAttr with SQL_ATTR_ANSI_APP set to SQL_AA_FALSE or calls SQLConnectW without setting the value of SQL_ATTR_ANSI_APP, then the application is considered a Unicode application. This means all CHAR data is sent and received from a Unicode database in UTF-8 format. The application can then fetch CHAR data into SQL_C_CHAR buffers in local code page (with possible data loss), or into SQL_C_WCHAR buffers in UCS-2 without any data loss. If the application does not do either of the two calls above, CHAR data is converted to the applications local code page at the server. This means CHAR data fetched into SQL_C_WCHAR may suffer data loss. If the DB2CODEPAGE instance variable is set (using db2set) to code page 1208 (UTF-8), the application will receive all CHAR data in UTF-8 since this is now the local code page. The application must also ensure that all CHAR input data is also in UTF-8. ODBC also assumes that all SQL_C_WCHAR data is in the native endian format. CLI will perform any required byte-reversal for SQL_C_WCHAR. ODBC Unicode Versus Non-Unicode Applications This release of DB2 Universal Database contains the SQLConnectW() API. A Unicode driver must export SQLConnectW in order to be recognized as a Unicode driver by the driver manager. It is important to note that many ODBC applications (such as Microsoft Access and Visual Basic) call SQLConnectW(). In previous releases of DB2 Universal Database, DB2 CLI has not supported this API, and thus was not recognized as a Unicode driver by the ODBC driver manager. This caused the ODBC driver manager to convert all Unicode data to the application's local code page. With the added support of the SQLConnectW() function, these applications will now connect as Unicode applications and DB2 CLI will take care of all required data conversion. DB2 CLI now accepts Unicode APIs (with a suffix of "W") and regular ANSI APIs. ODBC defines a set of functions with a suffix of "A", but the driver manager does not pass ANSI functions with the "A" suffix to the driver. Instead, it converts these functions to ANSI function calls without the suffix, and then passes them to the driver. An ODBC application that calls the SQLConnectW() API is considered a Unicode application. Since the ODBC driver manager will always call the SQLConnectW() API regardless of what version the application called, ODBC introduced the SQL_ATTR_ANSI_APP connect attribute to notify the driver if the application should be considered an ANSI or UNICODE application. If SQL_ATTR_ANSI_APP is set to SQL_AA_TRUE, the DB2 CLI converts all Unicode data to the local code page before sending it to the server. Appendix D. Extended Scalar Functions Date and Time Functions The following functions are missing from the Date and Time Functions section of Appendix D "Extended Scalar Functions": DAYOFWEEK_ISO( date_exp ) Returns the day of the week in date_exp as an integer value in the range 1-7, where 1 represents Monday. Note the difference between this function and the DAYOFWEEK() function, where 1 represents Sunday. WEEK_ISO( date_exp ) Returns the week of the year in date_exp as an integer value in the range of 1-53. Week 1 is defined as the first week of the year to contain a Thursday. Therefore, Week1 is equivalent to the first week that contains Jan 4, since Monday is considered to be the first day of the week. Note that WEEK_ISO() differs from the current definition of WEEK(), which returns a value up to 54. For the WEEK() function, Week 1 is the week containing the first Saturday. This is equivalent to the week containing Jan. 1, even if the week contains only one day. DAYOFWEEK_ISO() and WEEK_ISO() are automatically available in a database created in Version 7. If a database was created prior to Version 7, these functions may not be available. To make DAYOFWEEK_ISO() and WEEK_ISO() functions available in such a database, use the db2updb system command. For more information about db2updb, see the "Command Reference" section in these Release Notes. Appendix K. Using the DB2 CLI/ODBC/JDBC Trace Facility The sections within this appendix have been updated. See the "Traces" chapter in the Troubleshooting Guide for the most up-to-date information on this trace facility. TЪU iъs TЪUwgs FixPak 4 @CziHq http://www.ibm.com/software/data/db2/udb/winos2unix/support uWU s PDFCz]iHb CD 񿷜oʪwsѾCzL DB2 Aъ PTF X U478862AYiq CDCziHq http://www.ibm.com/cgi-bin/db2www/data/db2/udb/winos2unix/support/help.d2w/report opuDB2 AvۛTC Ts UݬьeX TЪU ߚTCboì`NAtu WTժrьC 16. sW񊚌T +----------------------------------+----------------------------------+ | TX | | +----------------------------------+----------------------------------+ | SQL2554N | s]X | +----------------------------------+----------------------------------+ | SQL0490N | sT | +----------------------------------+----------------------------------+ | SQL20214N | sT | +----------------------------------+----------------------------------+ | SQL20211N | sT | +----------------------------------+----------------------------------+ UݬьeX TЪU ߚ SQL ACboì`NAt uWTժrьC 17. s SQLSTATE T +----------------------------------+----------------------------------+ | SQLSTATE | Nq | +----------------------------------+----------------------------------+ | 428B7 | zb SQL z񽳮wrAW | | | XdC | +----------------------------------+----------------------------------+ | 428FI | zwF ORDER OFAOݫw | | | 񿖿S ORDER BY lyC | +----------------------------------+----------------------------------+ | 428FJ | ORDER BY AъKnݫ | | | ݬ~юC | +----------------------------------+----------------------------------+ uWTժr ]zxwF DB2 @~t\C ziHq@~tROsUC DB2 TG r ASN uDB2 gvсT CCA uq[cU{vсT CLI uIsh¡vсT DBA uvu۫w̝zъ{vсT DBI wP[cсT DB2 ROBz сT DWC ۫㡌x сT FLG uۛT̝z{vсTP]X GSE DB2 Spatial Extender сT SAT uDB2 PvсT SPM PBI̝z{сT SQJ Java O SQL (SQLJ) сT SQL ۫w̝z{bi~pсTC PAiHbuWъP SQLSTATE TժrC T ID OT˪rTr (Х\WM) Aߜ| 㬀TXCrє~TYAoOъC YnsoÓ~TAb@~tROьJUCG db2 "? XXXnnnnn" XXX NݛTr B nnnnn NݛTXC : ݪ db2 OЅT ID jpgABnrєC ]AUCO|сPGG * db2 "? SQL0000N" * db2 "? sql0000" * db2 "? SQL0000n" pGTժrˬALkьAъUCO (b unix tW Ѫ 'more' tW)G db2 "? XXXnnnnn" | more z]iHbѵJʪIsCYniJѵJʪAb@~t ROьWJUCG db2 @чiJѵJʪAzNiHbUCROьJOG db2 => Ynbʪ񿷜o DB2 TAbOьJUCG ? XXXnnnnn : pGTժrWXAъDu@ъiHNX̥ 'more' (b unix tW)ANXsVAMߜzi Hs˔C ziHoXUCOAH^Pw SQLSTATE TժrG db2 "? nnnnn" db2 "? nn" nnnnn O㬀 SQLSTATE (^) B nn OԪ SQLSTATE OX (SQLSTATE eԪ)C SQL Reference (Lլ) SQL Reference Update Available The SQL Reference has been updated and the latest .pdf is available for download online at http://www.ibm.com/software/data/db2/udb/winos2unix/support. The information in these notes is in addition to the updated reference. All updated documentation is also available on CD. This CD can be ordered through DB2 service using the PTF number U478862. Information on contacting DB2 Service is available at http://www.ibm.com/cgi-bin/db2www/data/db2/udb/winos2unix/support/help.d2w/report . Enabling the New Functions and Procedures Version 7 FixPaks deliver new SQL built-in scalar functions. Refer to the SQL Reference updates for a description of these new functions. The new functions are not automatically enabled on each database when the database server code is upgraded to the new service level. To enable these new functions, the system administrator must issue the command db2updv7, specifying each database at the server. This command makes an entry in the database that ensures that database objects created prior to executing this command use existing function signatures that may match the new function signatures. For information on enabling the MQSeries functions (those defined in the DB2MQ schema), see "MQSeries". SET SERVER OPTION - Documentation Error The Notes section for the SET SERVER OPTION statement contains misleading information. The current note reads: * SET SERVER OPTION currently only supports the password, fold_id, and fold_pw server options. This statement is not true. SET SERVER OPTION supports all server options, including server options for wrappers not provided by IBM. The note should be ignored. Correction to CREATE TABLESPACE Container-clause, and Container-string Information Remote resources (such as LAN-redirected drives or NFS-mounted file systems) are currently supported only when using NEC iStorage S4100 and S2100, Network Appliance Filers, IBM iSCSI, or IBM Network Attached Storage. This is a correction to the current documentation, which indicates that remote resources are unsupported. Correction to CREATE TABLESPACE EXTENTSIZE information The CREATE TABLESPACE statement cannot accept an EXTENTSIZE value specified in gigabytes. GRANT (Table, View, or Nickname Privileges) - Documentation Error The Notes section for the GRANT (Table, View, or Nickname Privileges) statement contains a misleading bullet. The current note reads: * DELETE, INSERT, SELECT and UPDATE privileges are not defined for nicknames since operations on nicknames depend on the privileges of the authorization ID used at the data source when the statement referencing the nickname is processed. This text should be ignored. As the remaining text in the section is accurate without it. MQSeries Information Scalar Functions MQPUBLISH >>-MQPUBLISH--(-------------------------------------------------> >--+---------------------------------------------+--msg-data----> '-publisher-service--,--+-------------------+-' '-service-policy--,-' >--+---------------------------------+--)---------------------->< '-,--topic--+-------------------+-' | (1) | '-,--correl-id------' : 1. The correl-id cannot be specified unless a service and a policy are previously defined. The schema is DB2MQ. The MQPUBLISH function publishes data to MQSeries. This function requires the installation of either MQSeries Publish/Subscribe or MQSeries Integrator. Please consult www.ibm.com/software/MQSeries for further details. The MQPUBLISH function publishes the data contained in msg-data to the MQSeries publisher specified in publisher-service, and using the quality of service policy defined by service-policy. An optional topic for the message can be specified, and an optional user-defined message correlation identifier may also be specified. The function returns a value of '1' if successful or a '0' if unsuccessful. publisher-service A string containing the logical MQSeries destination where the message is to be sent. If specified, the publisher-service must refer to a publisher Service Point defined in the AMT.XML repository file. A service point is a logical end-point from which a message is sent or received. Service point definitions include the name of the MQSeries Queue Manager and Queue. See the MQSeries Application Messaging Interface for further details. If publisher-service is not specified, then the DB2.DEFAULT.PUBLISHER will be used. The maximum size of publisher-service is 48 bytes. service-policy A string containing the MQSeries AMI Service Policy to be used in handling of this message. If specified, the service-policy must refer to a Policy defined in the AMT.XML repository file. A Service Policy defines a set of quality of service options that should be applied to this messaging operation. These options include message priority and message persistence. See the MQSeries Application Messaging Interface manual for further details. If service-policy is not specified, then the default DB2.DEFAULT.POLICY will be used. The maximum size of service-policy is 48 bytes. msg-data A string expression containing the data to be sent via MQSeries. The maximum size if the string of type VARCHAR is 4000 bytes. If the string is a CLOB, it can be up to 1MB in size. topic A string expression containing the topic for the message publication. If no topic is specified, none will be associated with the message. The maximum size of topic is 40 bytes. Multiple topics can be specified in one string (up to 40 characters long). Each topic must be separated by a colon. For example, "t1:t2:the third topic" indicates that the message is associated with all three topics: t1, t2, and "the third topic". correl-id An optional string expression containing a correlation identifier to be associated with this message. The correl-id is often specified in request and reply scenarios to associate requests with replies. If not specified, no correlation id will be added to the message. The maximum size of correl-id is 24 bytes. Examples Example 1: This example publishes the string "Testing 123" to the default publisher service (DB2.DEFAULT.PUBLISHER) using the default policy (DB2.DEFAULT.POLICY). No correlation identifier or topic is specified for the message. VALUES MQPUBLISH('Testing 123') Example 2: This example publishes the string "Testing 345" to the publisher service "MYPUBLISHER" under the topic "TESTS". The default policy is used and no correlation identifier is specified. VALUES MQPUBLISH('MYPUBLISHER','Testing 345', 'TESTS') Example 3: This example publishes the string "Testing 678" to the publisher service "MYPUBLISHER" using the policy "MYPOLICY" with a correlation identifier of "TEST1". The message is published with topic "TESTS". VALUES MQPUBLISH('MYPUBLISHER','MYPOLICY','Testing 678','TESTS','TEST1') Example 4: This example publishes the string "Testing 901" to the publisher service "MYPUBLISHER" under the topic "TESTS" using the default policy (DB2.DEFAULT.POLICY) and no correlation identifier. VALUES MQPUBLISH('Testing 901','TESTS') All examples return the value '1' if successful. MQREADCLOB >>-MQREADCLOB--(--+----------------------------------------+----> '-receive-service--+-------------------+-' '-,--service-policy-' >--)----------------------------------------------------------->< The schema is DB2MQ. The MQREADCLOB function returns a message from the MQSeries location specified by receive-service, using the quality of service policy defined in service-policy. Executing this operation does not remove the message from the queue associated with receive-service, but instead returns the message at the head of the queue. The return value is a CLOB of 1MB maximum length, containing the message. If no messages are available to be returned, a NULL is returned. receive-service A string containing the logical MQSeries destination from where the message is to be received. If specified, the receive-service must refer to a Service Point defined in the AMT.XML repository file. A service point is a logical end-point from where a message is sent or received. Service points definitions include the name of the MQSeries Queue Manager and Queue. See the MQSeries Application Messaging Interface for further details. If receive-service is not specified, then the DB2.DEFAULT.SERVICE will be used. The maximum size of receive-service is 48 bytes. service-policy A string containing the MQSeries AMI Service Policy used in handling this message. If specified, the service-policy must refer to a Policy defined in the AMT.XML repository file. A Service Policy defines a set of quality of service options that should be applied to this messaging operation. These options include message priority and message persistence. See the MQSeries Application Messaging Interface manual for further details. If service-policy is not specified, then the default DB2.DEFAULT.POLICY will be used. The maximum size of service-policy is 48 bytes. Examples: Example 1: This example reads the message at the head of the queue specified by the default service (DB2.DEFAULT.SERVICE), using the default policy (DB2.DEFAULT.POLICY). VALUES MQREADCLOB() Example 2: This example reads the message at the head of the queue specified by the service "MYSERVICE" using the default policy (DB2.DEFAULT.POLICY). VALUES MQREADCLOB('MYSERVICE') Example 3: This example reads the message at the head of the queue specified by the service "MYSERVICE", and using the policy "MYPOLICY". VALUES MQREADCLOB('MYSERVICE','MYPOLICY') All of these examples return the contents of the message as a CLOB with a maximum size of 1MB, if successful. If no messages are available, then a NULL is returned. MQRECEIVECLOB >>-MQRECEIVECLOB------------------------------------------------> >--(--+----------------------------------------------------------+--)->< '-receive-service--+-------------------------------------+-' '-,--service-policy--+--------------+-' '-,--correl-id-' The schema is DB2MQ. The MQRECEIVECLOB function returns a message from the MQSeries location specified by receive-service, using the quality of service policy service-policy. Performing this operation removes the message from the queue associated with receive-service. If the correl-id is specified, then the first message with a matching correlation identifier will be returned. If correl-id is not specified, then the message at the head of the queue will be returned. The return value is a CLOB with a maximum length of 1MB containing the message. If no messages are available to be returned, a NULL is returned. receive-service A string containing the logical MQSeries destination from which the message is received. If specified, the receive-service must refer to a Service Point defined in the AMT.XML repository file. A service point is a logical end-point from which a message is sent or received. Service points definitions include the name of the MQSeries Queue Manager and Queue. See the MQSeries Application Messaging Interface for further details. If receive-service is not specified, then the DB2.DEFAULT.SERVICE is used. The maximum size of receive-service is 48 bytes. service-policy A string containing the MQSeries AMI Service Policy to be used in the handling of this message. If specified, the service-policy must refer to a Policy defined in the AMT.XML repository file(1). If service-policy is not specified, then the default DB2.DEFAULT.POLICY is used. The maximum size of service-policy is 48 bytes. correl-id A string containing an optional correlation identifier to be associated with this message. The correl-id is often specified in request and reply scenarios to associate requests with replies. If not specified, no correlation id will be used. The maximum size of correl-id is 24 bytes. Examples: Example 1: This example receives the message at the head of the queue specified by the default service (DB2.DEFAULT.SERVICE), using the default policy (DB2.DEFAULT.POLICY). VALUES MQRECEIVECLOB() Example 2: This example receives the message at the head of the queue specified by the service "MYSERVICE" using the default policy (DB2.DEFAULT.POLICY). VALUES MQRECEIVECLOB('MYSERVICE') Example 3: This example receives the message at the head of the queue specified by the service "MYSERVICE" using the policy "MYPOLICY". VALUES MQRECEIVECLOB('MYSERVICE','MYPOLICY') Example 4: This example receives the first message with a correlation id that matches '1234' from the head of the queue specified by the service "MYSERVICE" using the policy "MYPOLICY". VALUES MQRECEIVECLOB('MYSERVICE',MYPOLICY','1234') All these examples return the contents of the message as a CLOB with a maximum size of 1MB, if successful. If no messages are available, a NULL will be returned. MQSEND >>-MQSEND--(--+----------------------------------------+--------> '-send-service--,--+-------------------+-' '-service-policy--,-' >--msg-data--+-------------------+--)-------------------------->< | (1) | '-,--correl-id------' : 1. The correl-id cannot be specified unless a service and a policy are previously defined. The schema is DB2MQ. The MQSEND function sends the data contained in msg-data to the MQSeries location specified by send-service, using the quality of service policy defined by service-policy. An optional user defined message correlation identifier may be specified by correl-id. The function returns a value of '1' if successful or a '0' if unsuccessful. msg-data A string expression containing the data to be sent via MQSeries. The maximum size is 4000 bytes if the data is of type VARCHAR, and 1MB if the data is of type CLOB. send-service A string containing the logical MQSeries destination where the message is to be sent. If specified, the send-service refers to a service point defined in the AMT.XML repository file. A service point is a logical end-point from which a message may be sent or received. Service point definitions include the name of the MQSeries Queue Manager and Queue. See the MQSeries Application Messaging Interface manual for further details. If send-service is not specified, then the value of DB2.DEFAULT.SERVICE is used. The maximum size of send-service is 48 bytes. service-policy A string containing the MQSeries AMI Service Policy used in handling of this message. If specified, the service-policy must refer to a service policy defined in the AMT XML repository file. A Service Policy defines a set of quality of service options that should be applied to this messaging operation. These options include message priority and message persistence. See the MQSeries Application Messaging Interface manual for further details. If service-policy is not specified, then a default value of DB2.DEFAULT.POLICY will be used. The maximum size of service-policy is 48 bytes. correl-id An optional string containing a correlation identifier associated with this message. The correl-id is often specified in request and reply scenarios to associate requests with replies. If not specified, no correlation id will be sent. The maximum size of correl-id is 24 bytes. Examples: Example 1: This example sends the string "Testing 123" to the default service (DB2.DEFAULT.SERVICE), using the default policy (DB2.DEFAULT.POLICY), with no correlation identifier. VALUES MQSEND('Testing 123') Example 2: This example sends the string "Testing 345" to the service "MYSERVICE", using the policy "MYPOLICY", with no correlation identifier. VALUES MQSEND('MYSERVICE','MYPOLICY','Testing 345') Example 3: This example sends the string "Testing 678" to the service "MYSERVICE", using the policy "MYPOLICY", with correlation identifier "TEST3". VALUES MQSEND('MYSERVICE','MYPOLICY','Testing 678','TEST3') Example 4: This example sends the string "Testing 901" to the service "MYSERVICE", using the default policy (DB2.DEFAULT.POLICY), and no correlation identifier. VALUES MQSEND('MYSERVICE','Testing 901') All examples return a scalar value of '1' if successful. Table Functions MQREADALLCLOB >>-MQREADALLCLOB--(---------------------------------------------> >--+----------------------------------------+--+----------+-----> '-receive-service--+-------------------+-' '-num-rows-' '-,--service-policy-' >--)----------------------------------------------------------->< The schema is DB2MQ. The MQREADALLCLOB function returns a table containing the messages and message metadata from the MQSeries location specified by receive-service, using the quality of service policy service-policy. Performing this operation does not remove the messages from the queue associated with receive-service. If num-rows is specified, then a maximum of num-rows messages will be returned. If num-rows is not specified, then all available messages will be returned. The table returned contains the following columns: * MSG - a CLOB column containing the contents of the MQSeries message. * CORRELID - a VARCHAR(24) column holding a correlation ID used to relate messages. * TOPIC - a VARCHAR(40) column holding the topic that the message was published with, if available. * QNAME - a VARCHAR(48) column holding the queue name where the message was received. * MSGID - a CHAR(24) column holding the assigned MQSeries unique identifier for this message. * MSGFORMAT - a VARCHAR(8) column holding the format of the message, as defined by MQSeries. Typical strings have an MQSTR format. receive-service A string containing the logical MQSeries destination from which the message is read. If specified, the receive-service must refer to a service point defined in the AMT.XML repository file. A service point is a logical end-point from which a message is sent or received. Service point definitions include the name of the MQSeries Queue Manager and Queue. See the MQSeries Application Messaging Interface for further details. If receive-service is not specified, then the DB2.DEFAULT.SERVICE will be used. The maximum size of receive-service is 48 bytes. service-policy A string containing the MQSeries AMI Service Policy used in the handling of this message. If specified, the service-policy refers to a Policy defined in the AMT XML repository file. A service policy defines a set of quality of service options that should be applied to this messaging operation. These options include message priority and message persistence. See the MQSeries Application Messaging Interface manual for further details. If service-policy is not specified, then the default DB2.DEFAULT.POLICY will be used. The maximum size of service-policy is 48 bytes. num-rows A positive integer containing the maximum number of messages to be returned by the function. Examples: Example 1: This example receives all the messages from the queue specified by the default service (DB2.DEFAULT.SERVICE), using the default policy (DB2.DEFAULT.POLICY). The messages and all the metadata are returned as a table. SELECT * FROM table (MQREADALLCLOB()) T Example 2: This example receives all the messages from the head of the queue specified by the service MYSERVICE, using the default policy (DB2.DEFAULT.POLICY). Only the MSG and CORRELID columns are returned. SELECT T.MSG, T.CORRELID FROM table (MQREADALLCLOB('MYSERVICE')) T Example 3: This example reads the head of the queue specified by the default service (DB2.DEFAULT.SERVICE), using the default policy (DB2.DEFAULT.POLICY). Only messages with a CORRELID of '1234' are returned. All columns are returned. SELECT * FROM table (MQREADALLCLOB()) T WHERE T.CORRELID = '1234' Example 4: This example receives the first 10 messages from the head of the queue specified by the default service (DB2.DEFAULT.SERVICE), using the default policy (DB2.DEFAULT.POLICY). All columns are returned. SELECT * FROM table (MQREADALLCLOB(10)) T MQRECEIVEALLCLOB >>-MQRECEIVEALLCLOB--(------------------------------------------> >--+----------------------------------------------------------+--> '-receive-service--+-------------------------------------+-' '-,--service-policy--+--------------+-' '-,--correl-id-' >--+-----------------+--)-------------------------------------->< '-+---+--num-rows-' '-,-' The schema is DB2MQ. The MQRECEIVEALLCLOB function returns a table containing the messages and message metadata from the MQSeries location specified by receive-service, using the quality of service policy service-policy. Performing this operation removes the messages from the queue associated with receive-service. If a correl-id is specified, then only those messages with a matching correlation identifier will be returned. If correl-id is not specified, then the message at the head of the queue will be returned. If num-rows is specified, then a maximum of num-rows messages will be returned. If num-rows is not specified, then all available messages are returned. The table returned contains the following columns: * MSG - a CLOB column containing the contents of the MQSeries message. * CORRELID - a VARCHAR(24) column holding a correlation ID used to relate messages. * TOPIC - a VARCHAR(40) column holding the topic that the message was published with, if available. * QNAME - a VARCHAR(48) column holding the queue name where the message was received. * MSGID - a CHAR(24) column holding the assigned MQSeries unique identifier for this message. * MSGFORMAT - a VARCHAR(8) column holding the format of the message, as defined by MQSeries. Typical strings have an MQSTR format. receive-service A string containing the logical MQSeries destination from which the message is received. If specified, the receive-service must refer to a service point defined in the AMT.XML repository file. A service point is a logical end-point from which a message is sent or received. Service point definitions include the name of the MQSeries Queue Manager and Queue. See the MQSeries Application Messaging Interface manual for further details. If receive-service is not specified, then the DB2.DEFAULT.SERVICE will be used. The maximum size of receive-service is 48 bytes. service-policy A string containing the MQSeries AMI Service Policy used in the handling of this message. If specified, the service-policy refers to a Policy defined in the AMT XML repository file. A service policy defines a set of quality of service options that should be applied to this messaging operation. These options include message priority and message persistence. See the MQSeries Application Messaging Interface manual for further details. If service-policy is not specified, then the default DB2.DEFAULT.POLICY will be used. The maximum size of service-policy is 48 bytes. correl-id An optional string containing a correlation identifier associated with this message. The correl-id is often specified in request and reply scenarios to associate requests with replies. If not specified, no correlation id is specified. The maximum size of correl-id is 24 bytes. num-rows A positive integer containing the maximum number of messages to be returned by the function. Examples: Example 1: This example receives all the messages from the queue specified by the default service (DB2.DEFAULT.SERVICE), using the default policy (DB2.DEFAULT.POLICY). The messages and all the metadata are returned as a table. SELECT * FROM table (MQRECEIVEALLCLOB()) T Example 2: This example receives all the messages from the head of the queue specified by the service MYSERVICE, using the default policy (DB2.DEFAULT.POLICY). Only the MSG and CORRELID columns are returned. SELECT T.MSG, T.CORRELID FROM table (MQRECEIVEALLCLOB('MYSERVICE')) T Example 3: This example receives all of the message from the head of the queue specified by the service "MYSERVICE", using the policy "MYPOLICY". Only messages with a CORRELID of '1234' are returned. Only the MSG and CORRELID columns are returned. SELECT T.MSG, T.CORRELID FROM table (MQRECEIVEALLCLOB('MYSERVICE','MYPOLICY','1234')) T Example 4: This example receives the first 10 messages from the head of the queue specified by the default service (DB2.DEFAULT.SERVICE), using the default policy (DB2.DEFAULT.POLICY). All columns are returned. SELECT * FROM table (MQRECEIVEALLCLOB(10)) T CLOB data now supported in MQSeries functions The MQSeries functions (those defined in the DB2MQ schema) now include functionality that allow them to be used with CLOB data in addition to VARCHAR data. In some cases, a new function now exists to handle the CLOB data type, in others, the already existing function now handles both CLOB and VARCHAR data. In either case, the syntax of the CLOB function is identical to that of its VARCHAR equivalent. The functions that support the use of CLOB data, and their equivalent VARCHAR functions, are listed in the following table: 18. MQSeries Functions that support the CLOB data type +----------------------------------+----------------------------------+ | Function to use for VARCHAR data | Function to use for CLOB data | +----------------------------------+----------------------------------+ | MQPUBLISH | MQPUBLISH | +----------------------------------+----------------------------------+ | MQREAD | MQREADCLOB | +----------------------------------+----------------------------------+ | MQRECEIVE | MQRECEIVECLOB | +----------------------------------+----------------------------------+ | MQSEND | MQSEND | +----------------------------------+----------------------------------+ | MQREADALL | MQREADALLCLOB | +----------------------------------+----------------------------------+ | MQRECEIVEALL | MQRECEIVEALLCLOB | +----------------------------------+----------------------------------+ For information on enabling the MQSeries functions (those defined in the DB2MQ schema), see "MQSeries". Data Type Information Promotion of Data Types In this section table 5 shows the precedence list for each data type. Please note: 1. For a Unicode database, the following are considered to be equivalent data types: * CHAR and GRAPHIC * VARCHAR and VARGRAPHIC * LONG VARCHAR and LONG VARGRAPHIC * CLOB and DBCLOB 2. In a Unicode database, it is possible to create functions where the only difference in the function signature is between equivalent CHAR and GRAPHIC data types, for example, foo(CHAR(8)) and foo(GRAPHIC(8)). We strongly recommend that you do not define such duplicate functions since migration to a future release will require one of them to be dropped before the migration will proceed. If such duplicate functions do exist, the choice of which one to invoke is determined by a two-pass algorithm. The first pass attempts to find a match using the same algorithm as is used for resolving functions in a non-Unicode database. If no match is found, then a second pass will be done taking into account the following promotion precedence for CHAR and GRAPHIC strings: GRAPHIC-->CHAR-->VARGRAPHIC-->VARCHAR-->LONG VARGRAPHIC-->LONG VARCHAR--> -->DBCLOB-->CLOB Casting between Data Types The following entry has been added to the list introduced as: "The following casts involving distinct types are supported": * For a Unicode database, cast from a VARCHAR or VARGRAPHIC to distinct type DT with a source data type CHAR or GRAPHIC. The following are updates to "Table 6. Supported Casts between Built-in Data Types". Only the affected rows of the table are included. 19. Supported Casts between Built-in Data Types +----------------------+-----+-----+-----+-----+-----+-----+-----+----+ | Target Data Type -> | C | V | L | C | G | V | L | D | | | H | A | O | L | R | A | O | B | | | A | R | N | O | A | R | N | C | | | R | C | G | B | P | G | G | L | | | | H | V | | H | R | V | O | | | | A | A | | I | A | A | B | | | | R | R | | C | P | R | | | Source Data Type V | | | C | | | H | G | | | | | | H | | | I | R | | | | | | A | | | C | A | | | | | | R | | | | P | | | | | | | | | | H | | | | | | | | | | I | | | | | | | | | | C | | +----------------------+-----+-----+-----+-----+-----+-----+-----+----+ | CHAR | Y | Y | Y | Y | Y1 | Y1 | - | - | +----------------------+-----+-----+-----+-----+-----+-----+-----+----+ | VARCHAR | Y | Y | Y | Y | Y1 | Y1 | - | - | +----------------------+-----+-----+-----+-----+-----+-----+-----+----+ | LONGVARCHAR | Y | Y | Y | Y | - | - | Y1 | Y1 | +----------------------+-----+-----+-----+-----+-----+-----+-----+----+ | CLOB | Y | Y | Y | Y | - | - | - | Y1 | +----------------------+-----+-----+-----+-----+-----+-----+-----+----+ | GRAPHIC | Y1 | Y1 | - | - | Y | Y | Y | Y | +----------------------+-----+-----+-----+-----+-----+-----+-----+----+ | VARGRAPHIC | Y1 | Y1 | - | - | Y | Y | Y | Y | +----------------------+-----+-----+-----+-----+-----+-----+-----+----+ | LONGVARGRAPHIC | - | - | Y1 | Y1 | Y | Y | Y | Y | +----------------------+-----+-----+-----+-----+-----+-----+-----+----+ | DBCLOB | - | - | Y2 | Y1 | Y | Y | Y | Y | +----------------------+-----+-----+-----+-----+-----+-----+-----+----+ 1 Cast is only supported for Unicode databases. 2 Cast is only supported for Unicode databases. Only explicit casting is supported. Assignments and Comparisons Assignments and comparisons involving both character and graphic data are only supported when one of the strings is a literal. For function resolution, graphic literals and character literals will both match character and graphic function parameters. The following are updates to "Table 7. Data Type Compatibility for Assignments and Comparisons". Only the affected rows of the table, and the new footnote 6, are included: +-------+-----+-------+-------+-------+-----+-----+----+----+----+----+ | Opera | Bin | Decim | Float | Chara | Gra | Dat | Ti | Ti | Bi | UD | | nds | ary | al | ing | cter | phi | e | me | me | na | T | | | Int | Numbe | Point | Strin | c | | | - | ry | | | | ege | r | | g | Str | | | st | St | | | | r | | | | ing | | | am | ri | | | | | | | | | | | p | ng | | +-------+-----+-------+-------+-------+-----+-----+----+----+----+----+ | Chara | No | No | No | Yes | Yes | 1 | 1 | 1 | No | 2 | | cter | | | | | 6 | | | | 3 | | | Strin | | | | | | | | | | | | g | | | | | | | | | | | +-------+-----+-------+-------+-------+-----+-----+----+----+----+----+ | Graph | No | No | No | Yes 6 | Yes | No | No | No | No | 2 | | ic | | | | | | | | | | | | Strin | | | | | | | | | | | | g | | | | | | | | | | | +-------+-----+-------+-------+-------+-----+-----+----+----+----+----+ 6 Only supported for Unicode databases. String Assignments Storage Assignment The last paragraph of this subsection is modified as follows: When a string is assigned to a fixed-length column and the length of the string is less than the length attribute of the target, the string is padded to the right with the necessary number of single-byte, double-byte, or UCS-22 blanks. The pad character is always a blank even for columns defined with the FOR BIT DATA attribute. Retrieval Assignment The third paragraph of this subsection is modified as follows: When a character string is assigned to a fixed-length variable and the length of the string is less than the length attribute of the target, the string is padded to the right with the necessary number of single-byte, double-byte, or UCS-22 blanks. The pad character is always a blank even for strings defined with the FOR BIT DATA attribute. 2 UCS-2 defines several SPACE characters with different properties. For a Unicode database, the database manager always uses the ASCII SPACE at position x'0020' as UCS-2 blank. For an EUC database, the IDEOGRAPHIC SPACE at position x'3000' is used for padding GRAPHIC strings. Conversion Rules for String Assignments The following paragraph has been added to the end of this subsection: For Unicode databases, character strings can be assigned to a graphic column, and graphic strings can be assigned to a character column. DBCS Considerations for Graphic String Assignments The first paragraph of this subsection has been modified as follows: Graphic string assignments are processed in a manner analogous to that for character strings. For non-Unicode databases, graphic string data types are compatible only with other graphic string data types, and never with numeric, character string, or datetime data types. For Unicode databases, graphic string data types are compatible with character string data types. String Comparisons Conversion Rules for Comparison This subsection has been modified as follows: When two strings are compared, one of the strings is first converted, if necessary, to the encoding scheme and code page of the other string. For details, see the "Rules for String Conversions" section of "Chapter 3. Language Elements" in the SQL Reference. Rules for Result Data Types Character and Graphic Strings in a Unicode Database This is a new subsection inserted after the subsection "Graphic Strings". In a Unicode database, character strings and graphic strings are compatible. +-------------------+-------------------+-----------------------------+ | If one operand | And the other | The data type of the result | | is... | operand is... | is... | +-------------------+-------------------+-----------------------------+ | GRAPHIC(x) | CHAR(y) or | GRAPHIC(z) where z = | | | GRAPHIC(y) | max(x,y) | +-------------------+-------------------+-----------------------------+ | VARGRAPHIC(x) | CHAR(y) or | VARGRAPHIC(z) where z = | | | VARCHAR(y) | max(x,y) | +-------------------+-------------------+-----------------------------+ | VARCHAR(x) | GRAPHIC(y) or | VARGRAPHIC(z) where z = | | | VARGRAPHIC | max(x,y) | +-------------------+-------------------+-----------------------------+ | LONG VARGRAPHIC | CHAR(y) or | LONG VARGRAPHIC | | | VARCHAR(y) or | | | | LONG VARCHAR | | +-------------------+-------------------+-----------------------------+ | LONG VARCHAR | GRAPHIC(y) or | LONG VARGRAPHIC | | | VARGRAPHIC(y) | | +-------------------+-------------------+-----------------------------+ | DBCLOB(x) | CHAR(y) or | DBCLOB(z) where z = | | | VARCHAR(y) or | max(x,y) | | | CLOB(y) | | +-------------------+-------------------+-----------------------------+ | DBCLOB(x) | LONG VARCHAR | DBCLOB(z) where z = | | | | max(x,16350) | +-------------------+-------------------+-----------------------------+ | CLOB(x) | GRAPHIC(y) or | DBCLOB(z) where z = | | | VARGRAPHIC(y) | max(x,y) | +-------------------+-------------------+-----------------------------+ | CLOB(x) | LONG VARGRAPHIC | DBCLOB(z) where z = | | | | max(x,16350) | +-------------------+-------------------+-----------------------------+ Rules for String Conversions The third point has been added to the following list in this section: For each pair of code pages, the result is determined by the sequential application of the following rules: * If the code pages are equal, the result is that code page. * If either code page is BIT DATA (code page 0), the result code page is BIT DATA. * In a Unicode database, if one code page denotes data in an encoding scheme different from the other code page, the result is UCS-2 over UTF-8 (that is, the graphic data type over the character data type).1 * Otherwise, the result code page is determined by Table 8 of the " Rules for String Conversions" section of "Chapter 3. Language Elements" in the SQL Reference. An entry of "first" in the table means the code page from the first operand is selected and an entry of "second" means the code page from the second operand is selected. 1 In a non-Unicode database, conversion between different encoding schemes is not supported. Expressions The following has been added: In a Unicode database, an expression that accepts a character or graphic string will accept any string types for which conversion is supported. With the Concatenation Operator The following has been added to the end of this subsection: In a Unicode database, concatenation involving both character string operands and graphic string operands will first convert the character operands to graphic operands. Note that in a non-Unicode database, concatenation cannot involve both character and graphic operands. Predicates The following entry has been added to the list introduced by the sentence: "The following rules apply to all types of predicates": * In a Unicode database, all predicates that accept a character or graphic string will accept any string types for which conversion is supported. Unicode Information Scalar Functions and Unicode In a Unicode database, all scalar functions that accept a character or graphic string will accept any string types for which conversion is supported. GRAPHIC type and DATE/TIME/TIMESTAMP compatibility In the following sections, references to datetime values having "character string" representations have been changed to "string" representations. DB2 now supports, for Unicode databases only, "graphic string" representations of datetime values. String representations of datetime values Values whose data types are DATE, TIME, or TIMESTAMP are represented in an internal form that is transparent to the user. Date, time, and timestamp values can, however, also be represented by strings. This is useful because there are no constants or variables whose data types are DATE, TIME, or TIMESTAMP. Before it can be retrieved, a datetime value must be assigned to a string variable. The CHAR function or the GRAPHIC function (for Unicode databases only) can be used to change a datetime value to a string representation. The string representation is normally the default format of datetime values associated with the country/region code of the database, unless overridden by specification of the DATETIME option when the program is precompiled or bound to the database. No matter what its length, a large object string, a LONG VARCHAR value, or a LONG VARGRAPHIC value cannot be used to represent a datetime value (SQLSTATE 42884). When a valid string representation of a datetime value is used in an operation with an internal datetime value, the string representation is converted to the internal form of the date, time, or timestamp value before the operation is performed. Date, time and timestamp strings must contain only characters and digits. Date strings, time strings, and datetime strings The definitions of these terms have been changed slightly. References to "character string" representations have been changed to "string" representations. Casting between data types DATE, TIME, and TIMESTAMP can now be cast to GRAPHIC and VARGRAPHIC. GRAPHIC and VARGRAPHIC can now be cast to DATE, TIME, and TIMESTAMP. Graphic string support is only available for Unicode databases. Assignments and comparisons There is now data type compatibility for assignments and comparisons between graphic strings and DATE, TIME, and TIMESTAMP values. Graphic string support is only available for Unicode databases. Datetime assignments The basic rule for datetime assignments is that a DATE, TIME, or TIMESTAMP value can only be assigned to a column with a matching data type (whether DATE, TIME, or TIMESTAMP) or to a fixed- or varying-length string variable or string column. The assignment must not be to a LONG VARCHAR, CLOB, LONG VARGRAPHIC, DBCLOB, or BLOB variable or column. When a datetime value is assigned to a string variable or string column, conversion to a string representation is automatic. Leading zeros are not omitted from any part of the date, time, or timestamp. The required length of the target will vary, depending on the format of the string representation. If the length of the target is greater than required, and the target is a fixed-length string, it is padded on the right with blanks. If the length of the target is less than required, the result depends on the type of datetime value involved, and on the type of target. When the target is a host variable, the following rules apply: * DATE: If the variable length is less than 10 characters, an error occurs. * TIME: If the USA format is used, the length of the variable must not be less than 8 characters; in other formats the length must not be less than 5 characters. If ISO or JIS formats are used, and if the length of the host variable is less than 8 characters, the seconds part of the time is omitted from the result and assigned to the indicator variable, if provided. The SQLWARN1 field of the SQLCA is set to indicate the omission. * TIMESTAMP: If the host variable is less than 19 characters, an error occurs. If the length is less than 26 characters, but greater than or equal to 19 characters, trailing digits of the microseconds part of the value are omitted. The SQLWARN1 field of the SQLCA is set to indicate the omission. DATE >>-DATE--(--expression--)-------------------------------------->< The schema is SYSIBM. The DATE function returns a date from a value. The argument must be a date, timestamp, a positive number less than or equal to 3 652 059, a valid string representation of a date or timestamp, or a string of length 7 that is not a LONG VARCHAR, CLOB, LONG VARGRAPHIC, DBCLOB, or BLOB. Only Unicode databases support an argument that is a graphic string representation of a date or a timestamp. If the argument is a string of length 7, it must represent a valid date in the form yyyynnn, where yyyy are digits denoting a year, and nnn are digits between 001 and 366, denoting a day of that year. The result of the function is a date. If the argument can be null, the result can be null; if the argument is null, the result is the null value. The other rules depend on the data type of the argument: * If the argument is a date, timestamp, or valid string representation of a date or timestamp: * The result is the date part of the value. * If the argument is a number: * The result is the date that is n-1 days after January 1, 0001, where n is the integral part of the number. * If the argument is a string with a length of 7: * The result is the date represented by the string. Examples: Assume that the column RECEIVED (timestamp) has an internal value equivalent to '1988-12-25-17.12.30.000000'. * This example results in an internal representation of '1988-12-25'. DATE(RECEIVED) * This example results in an internal representation of '1988-12-25'. DATE('1988-12-25') * This example results in an internal representation of '1988-12-25'. DATE('25.12.1988') * This example results in an internal representation of '0001-02-04'. DATE(35) GRAPHIC >>-GRAPHIC--(--graphic-expression--+------------+--)----------->< '-,--integer-' The schema is SYSIBM. The GRAPHIC function returns a GRAPHIC representation of a graphic string type or a GRAPHIC representation of a datetime type. graphic-expression An expression that returns a value that is a graphic string. integer An integer value specifying the length attribute of the resulting GRAPHIC data type. The value must be between 1 and 127. If integer is not specified, the length of the result is the same as the length of the first argument. The result of the function is a GRAPHIC. If the argument can be null, the result can be null; if the argument is null, the result is the null value. Datetime to Graphic: >>-GRAPHIC--(--datetime-expression--+--------------+--)-------->< '-,--+-ISO---+-' +-USA---+ +-EUR---+ +-JIS---+ '-LOCAL-' Datetime to Graphic datetime-expression An expression that is one of the following three data types date The result is the graphic string representation of the date in the format specified by the second argument. The length of the result is 10. An error occurs if the second argument is specified and is not a valid value (SQLSTATE 42703). time The result is the graphic string representation of the time in the format specified by the second argument. The length of the result is 8. An error occurs if the second argument is specified and is not a valid value (SQLSTATE 42703). timestamp The second argument is not applicable and must not be specified (SQLSTATE 42815). The result is the graphic string representation of the timestamp. The length of the result is 26. The code page of the string is the code page of the database at the application server. TIME >>-TIME--(--expression--)-------------------------------------->< The schema is SYSIBM. The TIME function returns a time from a value. The argument must be a time, timestamp, or a valid string representation of a time or timestamp that is not a LONG VARCHAR, CLOB, LONG VARGRAPHIC, DBCLOB, or BLOB. Only Unicode databases support an argument that is a graphic string representation of a time or a timestamp. The result of the function is a time. If the argument can be null, the result can be null; if the argument is null, the result is the null value. The other rules depend on the data type of the argument: * If the argument is a time: * The result is that time. * If the argument is a timestamp: * The result is the time part of the timestamp. * If the argument is a string: * The result is the time represented by the string. Example: * Select all notes from the IN_TRAY sample table that were received at least one hour later in the day (any day) than the current time. SELECT * FROM IN_TRAY WHERE TIME(RECEIVED) >= CURRENT TIME + 1 HOUR TIMESTAMP >>-TIMESTAMP--(--expression--+-------------+--)---------------->< '-,expression-' The schema is SYSIBM. The TIMESTAMP function returns a timestamp from a value or a pair of values. Only Unicode databases support an argument that is a graphic string representation of a date, a time, or a timestamp. The rules for the arguments depend on whether the second argument is specified. * If only one argument is specified: * It must be a timestamp, a valid string representation of a timestamp, or a string of length 14 that is not a LONG VARCHAR, CLOB, LONG VARGRAPHIC, DBCLOB, or BLOB. A string of length 14 must be a string of digits that represents a valid date and time in the form yyyyxxddhhmmss, where yyyy is the year, xx is the month, dd is the day, hh is the hour, mm is the minute, and ss is the seconds. * If both arguments are specified: * The first argument must be a date or a valid string representation of a date and the second argument must be a time or a valid string representation of a time. The result of the function is a timestamp. If either argument can be null, the result can be null; if either argument is null, the result is the null value. The other rules depend on whether the second argument is specified: * If both arguments are specified: * The result is a timestamp with the date specified by the first argument and the time specified by the second argument. The microsecond part of the timestamp is zero. * If only one argument is specified and it is a timestamp: * The result is that timestamp. * If only one argument is specified and it is a string: * The result is the timestamp represented by that string. If the argument is a string of length 14, the timestamp has a microsecond part of zero. Example: * Assume the column START_DATE (date) has a value equivalent to 1988-12-25, and the column START_TIME (time) has a value equivalent to 17.12.30. TIMESTAMP(START_DATE, START_TIME) Returns the value '1988-12-25-17.12.30.000000'. VARGRAPHIC Character to Vargraphic: >>-VARGRAPHIC--(--character-string-expression--)--------------->< Datetime to Vargraphic: >>-VARGRAPHIC--(--datetime-expression--)----------------------->< Graphic to Vargraphic: >>-VARGRAPHIC--(--graphic-string-expression--+------------+-----> '-,--integer-' >--)----------------------------------------------------------->< The schema is SYSIBM. The VARGRAPHIC function returns a graphic string representation of a: * character string value, converting single byte characters to double byte characters, * datetime value (only supported on Unicode databases) * graphic string value, if the first argument is any type of graphic string. The result of the function is a varying length graphic string (VARGRAPHIC data type). If the first argument can be null, the result can be null; if the first argument is null, the result is the null value. Character to Vargraphic character-string-expression An expression whose value must be of a character string data type other than LONG VARCHAR or CLOB, and whose maximum length must not be greater than 16 336 bytes. The length attribute of the result is equal to the length attribute of the argument. Let S denote the value of the character-string-expression. Each single-byte character in S is converted to its equivalent double-byte representation or to the double-byte substitution character in the result; each double-byte character in S is mapped 'as-is'. If the first byte of a double-byte character appears as the last byte of S, it is converted into the double-byte substitution character. The sequential order of the characters in S is preserved. The following are additional considerations for the conversion. * For a Unicode database, this function converts the character string from the code page of the operand into UCS-2. Every character of the operand, including DBCS characters, is converted. If the second argument is given, it specifies the desired length (number of UCS-2 characters) of the resulting UCS-2 string. * The conversion to double-byte code points by the VARGRAPHIC function is based on the code page of the operand. * Double-byte characters of the operand are not converted. All other characters are converted to their corresponding double-byte depiction. If there is no corresponding double-byte depiction, the double-byte substitution character for the code page is used. * No warning or error code is generated if one or more double-byte substitution characters are returned in the result. Datetime to Vargraphic datetime-expression An expression whose value must be of the DATE, TIME, or TIMESTAMP data type. Graphic to Vargraphic graphic-string-expression An expression that returns a value that is a graphic string. integer The length attribute for the resulting varying length graphic string. The value must be between 0 and 16 336. If this argument is not specified, the length of the result is the same as the length of the argument. If the length of the graphic-string-expression is greater than the length attribute of the result, truncation is performed and a warning is returned (SQLSTATE 01004), unless the truncated characters were all blanks and the graphic-string-expression was not a long string (LONG VARGRAPHIC or DBCLOB). Larger Index Keys for Unicode Databases ALTER TABLE The length of variable length columns that are part of any index, including primary and unique keys, defined when the registry variable DB2_INDEX_2BYTEVARLEN was on, can be altered to a length greater than 255 bytes. The fact that a variable length column is involved in a foreign key will no longer prevent the length of that column from being altered to larger than 255 bytes, regardless of the registry variable setting. However, data with length greater than 255 cannot be inserted into the table unless the column in the corresponding primary key has length greater than 255 bytes, which is only possible if the primary key was created with the registry variable ON. CREATE INDEX Indexes can be defined on variable length columns whose length is greater than 255 bytes if the registry variable DB2_INDEX_2BYTEVARLEN is ON. CREATE TABLE Primary and unique keys with variable keyparts can have a size greater than 255 if the registry variable DB2_INDEX_2BYTEVARLEN is ON. Foreign keys can be defined on variable length columns whose length is greater than 255 bytes. ALLOCATE CURSOR Statement Notes Section Incorrect The two bulleted items in the Notes section of the ALLOCATE CURSOR Statement were printed in error. Disregard the information contained in these items. Additional Options in the GET DIAGNOSTICS Statement GET DIAGNOSTICS Statement The GET DIAGNOSTICS statement is used to obtain information about the previously executed SQL statement. The syntax of this statement has been updated as follows. Oyk >>-GET DIAGNOSTICS----------------------------------------------> >--+-SQL-variable-name--=--+-ROW_COUNT-----+-+----------------->< | '-RETURN_STATUS-' | '-| condition-information |---------------' condition-information: |--EXCEPTION--1-------------------------------------------------> .-,------------------------------------------. V | >----SQL-variable-name--=--+-MESSAGE_TEXT-----+-+---------------| '-DB2_TOKEN_STRING-' OЅ SQL-variable-name Identifies the variable that is the assignment target. If ROW_COUNT or RETURN_STATUS is specified, the variable must be an integer variable. Otherwise, the variable must be CHAR or VARCHAR. SQL variables can be defined in a compound statement. ROW_COUNT Identifies the number of rows associated with the previous SQL statement. If the previous SQL statement is a DELETE, INSERT, or UPDATE statement, ROW_COUNT identifies the number of rows deleted, inserted, or updated by that statement, excluding rows affected by triggers or referential integrity constraints. If the previous statement is a PREPARE statement, ROW_COUNT identifies the estimated number of result rows in the prepared statement. RETURN_STATUS Identifies the status value returned from the stored procedure associated with the previously executed SQL statement, provided that the statement was a CALL statement invoking a procedure that returns a status. If the previous statement is not such a statement, then the value returned has no meaning and could be any integer. condition-information Specifies that the error or warning information for the previously executed SQL statement is to be returned. If information about an error is needed, the GET DIAGNOSTICS statement must be the first statement specified in the handler that will handle the error. If information about a warning is needed, and if the handler will get control of the warning condition, the GET DIAGNOSTICS statement must be the first statement specified in that handler. If the handler will not get control of the warning condition, the GET DIAGNOSTICS statement must be the next statement executed. MESSAGE_TEXT Identifies any error or warning message text returned from the previously executed SQL statement. The message text is returned in the language of the database server where the statement is processed. If the statement completes with an SQLCODE of zero, an empty string or blanks are returned. DB2_TOKEN_STRING Identifies any error or warning message tokens returned from the previously executed SQL statement. If the statement completes with an SQLCODE of zero, or if the SQLCODE has no tokens, then an empty string or blanks is returned. ORDER BY in Subselects DB2 now supports ORDER BY in subselects and fullselects. fullselect Following is a partial syntax diagram of the modified fullselect showing the location of the order-by-clause. >>-+-subselect---------+----------------------------------------> +-(fullselect)------+ '-| values-clause |-' .----------------------------------------------. V | >----+------------------------------------------+-+-------------> '-+-UNION---------+--+-subselect---------+-' +-UNION ALL-----+ +-(fullselect)------+ +-EXCEPT--------+ '-| values-clause |-' +-EXCEPT ALL----+ +-INTERSECT-----+ '-INTERSECT ALL-' >--+-----------------+----------------------------------------->< '-order-by-clause-' A fullselect that contains an ORDER BY clause cannot be specified in: * A summary table * The outermost fullselect of a view (SQLSTATE 428FJ SQLCODE -20211) An ORDER BY clause in a fullselect does not affect the order of the rows returned by a query. An ORDER BY clause only affects the order of the rows returned if it is specified in the outermost fullselect. subselect Following is the complete syntax diagram of the modified subselect showing the location of the order-by-clause. >>-select-clause--from-clause--+--------------+-----------------> '-where-clause-' >--+-----------------+--+---------------+-----------------------> '-group-by-clause-' '-having-clause-' >--+-----------------+----------------------------------------->< '-order-by-clause-' The clauses of the subselect are processed in the following sequence: 1. FROM clause 2. WHERE clause 3. GROUP BY clause 4. HAVING clause 5. SELECT clause 6. ORDER BY clause A subselect that contains an ORDER BY cannot be specified: * In the outermost fullselect of a view * In a summary table * Unless the subselect is enclosed in parentheses For example, the following is not valid (SQLSTATE 428FJ SQLCODE -20211): SELECT * FROM T1 ORDER BY C1 UNION SELECT * FROM T2 ORDER BY C1 The following example is valid: (SELECT * FROM T1 ORDER BY C1) UNION (SELECT * FROM T2 ORDER BY C1) An ORDER BY clause in a subselect does not affect the order of the rows returned by a query. An ORDER BY clause only affects the order of the rows returned if it is specified in the outermost fullselect. order-by-clause Following is the complete syntax diagram of the modified order-by-clause. .-,------------------------------. V .-ASC--. | >>-ORDER BY----+-sort-key--+------+---------+-+---------------->< | '-DESC-' | '-ORDER OF--table-designator-' sort-key: |--+-simple-column-name--+--------------------------------------| +-simple-integer------+ '-sort-key-expression-' ORDER OF table-designator Specifies that the same ordering used in table-designator should be applied to the result table of the subselect. There must be a table reference matching table-designator in the FROM clause of the subselect that specifies this clause (SQLSTATE 42703). The subselect (or fullselect) corresponding to the specified table-designator must include an ORDER BY clause that is dependant on the data (SQLSTATE 428FI SQLCODE -20210). The ordering that is applied is the same as if the columns of the ORDER BY clause in the nested subselect (or fullselect) were included in the outer subselect (or fullselect), and these columns were specified in place of the ORDER OF clause. For more information on table designators, see "Column Name Qualifiers to Avoid Ambiguity" in the SQL Reference. Note that this form is not allowed in a fullselect (other than the degenerative form of a fullselect). For example, the following is not valid: (SELECT C1 FROM T1 ORDER BY C1) UNION SELECT C1 FROM T2 ORDER BY ORDER OF T1 The following example is valid: SELECT C1 FROM (SELECT C1 FROM T1 UNION SELECT C1 FROM T2 ORDER BY C1 ) AS UTABLE ORDER BY ORDER OF UTABLE select-statement Following is the complete syntax diagram of the modified select-statement: >>-+-----------------------------------+--fullselect------------> | .-,-----------------------. | | V | | '-WITH----common-table-expression-+-' >--fetch-first-clause--*--+--------------------+----------------> +-read-only-clause---+ | (1) | '-update-clause------' >--*--+---------------------+--*--+--------------+------------->< '-optimize-for-clause-' '-WITH--+-RR-+-' +-RS-+ +-CS-+ '-UR-' : 1. The update-clause cannot be specified if the fullselect contains an order-by-clause. SELECT INTO statement yk .-,-------------. V | >>-select-clause--INTO----host-variable-+--from-clause----------> >--+--------------+--+-----------------+--+---------------+-----> '-where-clause-' '-group-by-clause-' '-having-clause-' >--+-----------------+--+--------------+----------------------->< '-order-by-clause-' '-WITH--+-RR-+-' +-RS-+ +-CS-+ '-UR-' OLAP Functions (window-order-clause) Following is a partial syntax diagram for the OLAP functions showing the modified window-order-clause. window-order-clause: .-,--------------------------------------------. V .-| asc option |--. | |--ORDER BY----+-sort-key-expression--+-----------------+-+-+---| | '-| desc option |-' | '-ORDER OF--table-designator---------------' asc option: .-NULLS LAST--. |--ASC--+-------------+-----------------------------------------| '-NULLS FIRST-' desc option: .-NULLS FIRST-. |--DESC--+-------------+----------------------------------------| '-NULLS LAST--' ORDER BY (sort-key-expression,...) Defines the ordering of rows within a partition that determines the value of the OLAP function or the meaning of the ROW values in the window-aggregation-group-clause (it does not define the ordering of the query result set). sort-key-expression An expression used in defining the ordering of the rows within a window partition. Each column name referenced in a sort-key-expression must unambiguously reference a column of the result set of the subselect, including the OLAP function (SQLSTATE 42702 or 42703). The length of each sort-key-expression must not be more than 255 bytes (SQLSTATE 42907). A sort-key-expression cannot include a scalar fullselect (SQLSTATE 42822) or any function that is not deterministic or that has an external action (SQLSTATE 42845). This clause is required for the RANK and DENSE_RANK functions (SQLSTATE 42601). ASC Uses the values of the sort-key-expression in ascending order. DESC Uses the values of the sort-key-expression in descending order. NULLS FIRST The window ordering considers null values before all non-null values in the sort order. NULLS LAST The window ordering considers null values after all non-null values in the sort order. ORDER OF table-designator Specifies that the same ordering used in table-designator should be applied to the result table of the subselect. There must be a table reference matching table-designator in the FROM clause of the subselect that specifies this clause (SQLSTATE 42703). The subselect (or fullselect) corresponding to the specified table-designator must include an ORDER BY clause that is dependent on the data (SQLSTATE 428FI SQLCODE -20210). The ordering that is applied is the same as if the columns of the ORDER BY clause in the nested subselect (or fullselect) were included in the outer subselect (or fullselect), and these columns were specified in place of the ORDER OF clause. For more information on table designators, see "Column Name Qualifiers to Avoid Ambiguity" in the SQL Reference. New Input Argument for the GET_ROUTINE_SAR Procedure This procedure now supports hide_body_flag, an input argument of type INTEGER that specifies (using one of the following values) whether or not the routine body should be hidden when the routine text is extracted from the catalogs: 0 Leave the routine text intact. This is the default value. 1 Replace the routine body with an empty body when the routine text is extracted from the catalogs. >>-GET_ROUTINE_SAR----------------------------------------------> >--(--sarblob--,--type--,--routine_name_string--+-------------------+--)->< '-,--hide_body_flag-' Required Authorization for the SET INTEGRITY Statement When this statement is used to turn off integrity checking, the privileges of the authorization ID of the statement must include at least one of the following: * CONTROL privilege on: * The specified tables, and * The descendent foreign key tables that will have integrity checking turned off by the statement, and * The descendent immediate summary tables that will have integrity checking turned off by the statement * SYSADM or DBADM authority * LOAD authority Appendix N. Exception Tables In the table "Exception Table Message Column Structure", in rows 2 and 6, which describe the characters that indicate the type of the first and the next constraint violations found, respectively, there is a missing reference to: 'D' - Delete Cascade violation Unicode s Unicode üOЅgrժrޡюyqъrsXެkCѪD`٢Taw qFr›AHͅ㬀 Unicode sXCѪwqF@@Pު˜Nhۃy rsXAoժr۫ibۃѵAы@nڬC Unicode FԀϢsXެkGUTF-16 UTF-8C w]sXެkO UTF-16 (16 񩬀sX)CUCS-2 O UTF-16 l›AѪ ъԡ˪񩝞ˬь@˪rCUCS-2 q`Q{iюyrXAѪӛ ьϽeʪ񩝞rX񊘨񩝞rX¬юѝrCUCS-2 b IBM UrX 1200C t@ Unicode sXO UTF-8AѪO񩝞VABOQ]p޽K{ ASCII tъCUTF-8 ъwϬ񩝞 (q` 1-3AO 4) xsC˪rCL㬀 ASCII rNxs񩝞CʪѪrNъh ˪񩝞˔xsCq` UTF-8 ۫iD]ph񩝞rX¬rX XR ASCII ۫C UTF-8 b IBM UrX 1208C ъ{nʅ{۫brXBUCS-2 M UTF-8 ӗDAo OnCʪpA20 ˪rb UCS-2 񃦡nҬ 40 ˪񩝞A UTF-8 h ® 20 60 ˪񩝞 (ѲъrXժrˮw)C DB2 Unicode ۫w񊔐ъ{ w UTF-8 rX›ʽы DB2 Universal Database for UnixBWindows OS/2Aiъ˔xs UCS-2 UTF-8 Ԁϫ۫Co۫wiQ Unicode ۫wC SQL r۫Oъ UTF-8 isXA SQL ۫O ъ UCS-2 isXCoь MBCS r]]A@񩝞񊘨񩝞r^xs br񩬢A DBCS rhxsbC ъ{rXiӮM DB2 ъ˔xs۫㬀rX@C bD Unicode wAbrX@A۫w̝z{|ӗq񊪰AÛe r񊇤 (pure DBCS) ۫C b Unicode ۫wAqrXƒP UTF-8 r۫ӗ|Щ۫w̝z{˛AOʪ (UCS-2) ۫gLӗNbq񊪰AÛeC ۫w̝z{ʛrX˜ӗ 1. ۫w̝z{ʛrX˜ӗ : 1. ݐs Unicode ۫wApGъ{]w DB2CODEPAGE=1208Ahr X¼O UTF-8AHnrX˜ӗC 2. ws Unicode ۫wACLI ъ{]iNr۫ݺ@۫ AHN۫ݺ@r۫C ъ{OiHw UTF-8 rXAHXѪNъ UCS-2 Ûe Aъ UTF-8 Ûer۫C ъ{rXu Unicode ۫wC ъ Unicode nʅ{ѪϼG 1. ۫wrX¼Obы۫wȿMwABѪw]|q@~ty (rX) ˿MwC CODESET TERRITORY riъˮTaы Unicode DB2 ۫wC ʪpG CREATE DATABASE unidb USING CODESET UTF-8 TERRITORY US 2. ъ{rX]w]rXAOoiъUCެk UTF-8 ˩mG * ъONъ{rX]w UTF-8 (1208)G db2set DB2CODEPAGE=1208 * CLI/ODBC ъ{AiIs SQLSetConnectAttr() ]w SQL_ATTR_ANSI_APP SQL_AA_FALSEC w]]wO SQL_AA_TRUEC 3. GRAPHIC 񬀩۫ㇴC Unicode r|ъҬԡ˪񩝞A CHAR 񬀩۫ㇴC Unicode r|ъ 1 3 ˪񩝞C b GRAPHIC rޡ SQL q`O CHAR r񩬀@bAb ޡO@CʪpACHAR jr񩬰μO 254AB GRAPHIC jr񩬰μO 127Cȝ˩ۛTAХ\ SQL Reference @ "Functions" ` MAXC 4. ժrъ G r˃PrժrOCʪpG SELECT * FROM mytable WHERE mychar = 'utf-8 data' AND mygraphic = G'ucs-2 data' : Unicode ۫w˿AG rOъC Х\"Literals in Unicode Databases"AolۛT񊺾sC 5. CLI/ODBC M JDBC ъ{Ptъ{C Y CLI/ODBC ۛTAХ\"CLI Guide and Reference (Lլ)"C 6. UCS-2 ۫㬀񩝞iӪ]ѡx˝C DB2 bOъ big-endian C Ѿs oìу`NtUCb DB2 у 7.1 ъ Unicode ۛT sG * SQL Reference: Chapter 3. Language Elements Chapter 4. Functions Chapter 6. SQL Statements * CLI Guide and Reference: Chapter 3. Using Advanced Features Appendix C. DB2 CLI and ODBC * Data Movement Utilities Guide and Reference, Appendix C. Export/Import/Load Utility File Formats pb DB2 ъ Unicode ۛTA Administration Guide (L լ) National Language Support (NLS) appendix: "Unicode Support in DB2 UDB"C VII g sDqt DB2 Connect User's Guide (Lլ) Increasing DB2 Connect data transfer rate While the blocking of rows for a query result set is nothing new, DB2 for z/OS (formerly called DB2 for OS/390) since its Version 6.1 release has had the capability of returning multiple query blocks in response to an OPEN or FETCH request to a remote client, such as DB2 Connect. Rather than repeatedly sending requests to the DB2 for z/OS server requesting one block of row data at a time, the client can now optionally request that the server send back an additional number of query blocks. Such additional query blocks are called extra query blocks. This new feature allows the client to minimize the number of network line turnarounds, which has a major impact on network performance. The decrease in the number of requests sent by the client to the server for query blocks translates into a significant performance boost because switching between a send and receive is an expensive operation in terms of performance. DB2 Connect can now exploit this performance enhancement by requesting extra query blocks by default from a DB2 for z/OS server. To take full advantage of the return of extra query blocks (each can be up to 32K bytes long) for the preferred network protocol of TCP/IP, Window Scaling extensions are also enabled as architected under RFC-1323 in DB2 Connect. This feature allows TCP/IP to dynamically and efficiently adjust the send and receive window sizes to accommodate the potentially large amounts of data returned by way of the extra query blocks. Extra Query Blocks Extra query block support in DB2 for z/OS servers on Versions 6.1 or later is configured via the EXTRA BLOCKS SRV parameter on the DB2 DDF installation panel. This parameter controls the maximum number of extra query blocks that DB2 can send back to a client for a request and can be set to a value between 0 and 100. Setting the parameter value to 0 disables the return of extra query blocks. The default value of 100 should be used to get the most benefit out of this feature, barring any idiosyncrasies in the network that would render this setting less than ideal. On the client side where the application accesses DB2 for z/OS either directly through a co-located DB2 Connect installation, or through a separate DB2 Connect server installation, there are various means for activating the corresponding DB2 Connect support on a per cursor or statement basis through the use of: * A query rowset size for a cursor * The 'OPTIMIZE for N ROWS' clause on the select statement associated with a cursor * The 'FETCH FIRST N ROWS ONLY' clause on the select statement associated with a cursor. Option 1 is not covered under in this section because it was already implemented as part of DB2 for z/OS Scrollable Support in DB2 Connect Version 7.1 FixPak 2. Our focus is on the use of options 2 and 3 instead to enabling extra query block support using different SQL APIs as follows: 1. Embedded SQL * Invoke extra query block support for a query by specifying the 'OPTIMIZE for N ROWS' clause and/or the 'FETCH FIRST N ROWS ONLY' clause on the select statement itself. * With the 'OPTIMIZE for N ROWS' clause, DB2 for z/OS will attempt to block the desired number of rows to return to DB2 Connect, subject to the EXTRA BLOCKS SRV DDF installation parameter setting. The application can choose to fetch beyond N rows as DB2 for z/OS does not limit the total number of rows that could ultimately be returned for the query result set to N. * The 'FETCH FIRST N ROWS ONLY' clause works similarly, except that the query result set is limited to N rows by DB2 for z/OS. Fetching beyond N rows would result in SQL code +100 (end of data). 2. CLI/ODBC * Invoke extra query block support for a query through its SQL_MAX_ROWS statement attribute. * DB2 Connect will tag on the 'OPTIMIZE for N ROWS' clause for a DB2 for z/OS 6.x server. Even though the number of rows that could ultimately be returned for the query result set is not limited to N by DB2 for z/OS, CLI/ODBC would return SQL_NO_DATA_FOUND to the application if an attempt is made to fetch beyond N rows. * The 'FETCH FIRST N ROWS ONLY' clause is used instead for a DB2 for z/OS 7.1 or above server. Similar to the embedded SQL case, the query result set is limited to N rows by DB2 for z/OS. Fetching beyond N rows would result in SQL_NO_DATA_FOUND. 3. JDBC * Invoke extra query block support for a query through the setMaxRows method. Similar to the CLI/ODBC enablement, DB2 Connect will tag on the 'OPTIMIZE for N ROWS' clause for a DB2 for z/OS server Version 6.x , and the 'FETCH FIRST N ROWS ONLY' clause for a DB2 for z/OS server Version 7.1 or later. RFC-1323 Window Scaling Window Scaling is supported as of FixPak 4 on all Windows and UNIX platforms that support the RFC-1323 extensions for TCP/IP. This feature can be enabled on DB2 for Windows and UNIX via the DB2 registry variable DB2SORCVBUF. To enable Window Scaling, set the DB2 registry variable DB2SORCVBUF to any value above 64K (for example, on DB2 for Windows or UNIX, you can issue db2set DB2SORCVBUF =65537). The maximum send and receive buffer sizes are dependent on the specific operating system. To ensure that buffer sizes configured have been accepted, the user can set the database manager configuration parameter DIAGLEVEL to 4 (informational) and check the db2diag.log file for messages. For Window Scaling to take effect, it must be enabled on both ends of a connection. For example, to enable Window Scaling between the DB2 Connect workstation and the host, this feature must be active on both the workstation and the host, either directly through the operating system TCP/IP stack, or indirectly through the DB2 product. For instance, for DB2 for z/OS, Window Scaling can currently only be activated through the operating system by setting TCPRCVBUFRSIZE to any value above 64K. If a remote DB2 client is used for accessing host DB2 through a DB2 Connect server workstation, Window Scaling can be enabled on the client also. By the same token, Window Scaling can also be enabled between a remote DB2 client and a workstation DB2 server when no host DB2 is involved. While Window Scaling is designed to enhance network performance, the expected network performance improvement does not always materialize. Interaction among factors such as the frame size used for the Ethernet or token ring LAN adapter, the IP MTU size, and other settings at routers throughout the communication link could even result in performance degradation once Window Scaling has been enabled. By default, Window Scaling is disabled with both the send and receive buffers set to 64K. The user should be prepared to assess the impact of turning on Window Scaling and perform any necessary adjustments to the network. For an introduction to tuning the network for improved network performance, refer to the white paper at http://www.networking.ibm.com/per/per10.html. DB2 Connect Support for Loosely Coupled Transactions The support within DB2 Connect for loosely coupled transactions is intended to be used by user who implement XA distributed applications that access DB2 for OS/390 Version 6 or later. This support allows different branches of the same global transaction to share lock space on DB2 for OS/390. This feature reduces the window where one branch of a distributed transaction encounters lock timeout or deadlock as a result of another branch within the same global transaction. DB2 for OS/390 Version 6 shares the lock space in this situation provided DB2 Connect sends the XID on each connection serving different branches of the same global transaction. Kerberos support DB2 Universal Database currently supports the Kerberos security protocol as a means to authenticate users in the non-DRDA environment. Since DB2/390 V7.1 will start to support Kerberos security, DB2 Connect will add DRDA AR functionality to allow the use of Kerberos authentication to connect to DB2/390. The Kerberos authentication layer which handles the ticketing system is integrated into the Win2K Active Directory mechanism. The client and server sides of an application communicate with the Kerberos SSP (Security Support Provider) client and server modules respectively. The Security Support Provider Interface (SSPI) provides a high level interface to the Kerberos SSP and other security protocols Communication protocol support For SNA connection, you must use SECURITY=NONE when cataloging the APPC node Typical setup The procedure to configure DB2 to use Kerberos authentication involves setting up the following: * An authorization policy for DB2 (as a service) in the Active Directory that is shared on a network, and * Trust relationship between Kerberos Key Distribution Centers (KDCs) In the simplest scenario, there is at least one KDC trust relationship to configure, that is, the one between the KDC controlling the client workstation, and the OS/390 system. OS/390 R10 provides Kerberos ticket processing through its RACF facility which allows the host to act as an UNIX KDC. DB2 Connect provides as usual the router functionality in the 3-tier setting. It does not assume any role in authentication when Kerberos security is used. Instead, it merely passes the client's security token to DB2/390. Thus there is no need for the DB2 Connect gateway to be a member of the client or the host's Kerberos realm. To use Kerberos, both the DB2 Connect gateway must catalog its connection with authentication type KERBEROS. The client can either catalog with authentication NOT_SPEC or Kerberos. Any other combinations of authentication types on the client and the gateway results in sqlcode -1401 (Authentication type mismatch). Downlevel compatibility DB2 requirements for Kerberos support: DB2 UDB Client: Version 7.1 (OS: Win2K) DB2 Connect: Version 7.1 + Fix Pack 1 (OS: Any) DB2/390: Version 7.1 DB2/390 also have a requirement to be run on OS/390 Version 2 Release 10 or later. There are additional implied requirements on downlevel DB2/390 systems when connecting from DB2 Connect Version 7.1 clients. Although these DB2/390 systems do not support Kerberos, they do not respond properly to unsupported DRDA SECMECs. To solve this problem, apply the proper PTF: * UQ41941 (for DB2/390 V5.1) * UQ41942 (for DB2/390 V6.1) sʩR۫ b VM Uwъ{A sWUCyluЛqۛTv`Auwqъ{Av`@ ylG RDB_NAME SQLSTART EXEC Ai@ DBNAME ЅC CLI/ODBC/JDBC [c PATCH1 M PATCH2 ]w CLI/ODBC/JDBC X{[ciHМq[cU{BODBC X{̝z {]Ytw{^Bs db2cli.ini ˺C ȝ˩۫AХ\ wP[cR۫㮊 CLI Guide and ReferenceC ziHzL db2cli.ini AzL SQLDriverConnect() SQLBrowseConnect() CLI APIAw PATCH1 PATCH2 rAˡκ DB2 CLI/ODBC X{w]C ziHNъQn]wʪr[b@_A˽w PATCH1 rC pApGwΩ{ 1B2 8Ah PATCH1 NO 11C UCOX{ WC@rGG 1 ooX{NjM "count(exp)"AH "count(distinct exp)" NѪCoOѝnA]Ѹ DB2 у "count(exp)" ykA B˃ykOмY ODBC ъ{сCݪA "count(exp)" ykAMicrosoft ъ{N|nѪC 2 SQLGetTypeInfo() ê^ LITERAL_PREFIX LITERAL_SUFFIX SQL_NULL_DATA AѸ ODBC ъ{Y|Q]Co|j X{ê^rۿNCImpromptu 2.0 nC 4 pGWOPpѸO 0Aho|jX{NJ WO۫ڗ۫C Microsoft Access nC 8 pGWOڗѸO 1899-12-30Aho|jX{NJ WO۫۫CMicrosoft Access nC 16 ъC 32 o|jX{ê^ SQL_LONGVARCHARBSQL_LONGVARBINARY SQL_LONGVARGRAPHIC ۛTC]AH|V ъ{ьۛTCLotus 123 nC 64 o|jX{H NULL 񯇤XrCMicrosoft Access b 񩝞񃦡nC 128 o|jX{퇴Ad "SELECT Config, nValue FROM MSysConf"CϽeAX{|ê^P S0002 SQLSTATE ~ (ݫ)CpGъwb۫wы[cABQn ъ{sѪAhnC 256 o|jX{b SQLStatistics() IsѲê^DnC eAX{|˻̪Wê^wìAOì ODBC C 512 o|jX{b SQLGetFunctions() ê^ SQL_API_SQLTABLEPRIVILEGES P SQL_API_SQLCOLUMNPRIVILEGES FALSEC 1024 pGw UPDATE DELETE zхvTѶCAho|j X{b SQLExecute() SQLExecDirect() ê^ SQL_SUCCESS ˽D SQL_NO_DATA_FOUNDC Visual Basic ъ{탦nC 2048 ъC 4096 o|jX{bTwʪՅAoX COMMITC 8192 o|jX{bIsxs{ýAê^B~G›CG›O @˥CG›AOДxs{ìXC Powerbuild ъ{ iHsC 32768 o|jX{횲 Microsoft Query ъ{ӿъ DB2 MVS Pq rC 65536 o|jX{brժreJ@ "G"A˪rժrۃW OժrCb񩝞B@AݔЪΩ{C 131072 ݫWOO@̬@ѸAo|jX{NѪ CHAR(26) CMicrosoft ъ{탦nC 262144 o|jX{ъ pseudo ݫ db2cli.proceduresA˽D SYSCAT.PROCEDURES P SYSCAT.PROCPARMS ݫC 524288 o|jX{퇴 DB2/400 V3.x ttݫdAъ SYSTEM_TABLE_SCHEMA ˽D TABLE_SCHEMACo|ynC 1048576 o|jX{zL SQLPutData()ANsΪr SQL_NULL_ DATAC PATCH2 rP PATCH1 rCboϜpANъrIjr˽ whˡΩ{C ʪpApGwFΩ{ 1B4 5Ah PATCH2 NҪ "1,4,5"C UCOX{WC@rGG 1 - o|jX{N CALL z񬀔xs{êWӗjgrC 2 - ъC 3 - o|jX{NϮIsʪ̅ӗjgrC 4 - o|jX{퇴ϮIs (]NO SQLColumns()BSQLProcedureColumns() ) ê^у 2.1.2 G›A˽Dу 5 G›C 5 - o|jX{nJ VARCHAR BzAV۫㬀MV άbOOsC 6 - o|jX{ê^iՅ𬀛TCVisual Basic {|nъA pG DB2 qOу 5ABAO DB2 UDB у 5C 7 - o|jX{Nʪ GRAPHIC ۫㖎M CHAR ۫㖎Cb񩝞񃦡noϫGC 8 - o|jX{ϮIsϓjM̅C 9 - Յn COMMIT 10 - ъ 11 - iϓW, (VB xs{) 12 - qϮIs̅h̩, (Visual Interdev) 13 - N db2cli.ini rK[Xsr 14 - SQLProcedures() SQLProcedureColumns() WϪW 15 - ъyINݪrXpI 16 - jê^C@}ʬۛT 17 - bWê^W 18 - HЅONժr 19 - ϽeADB2 MVS V4.1 ODBC ykA]Ѫe\b~Xly ON lyiAC }ʐo PATCH2 |P IBM DB2 ODBC X{b~Xlyb ODBC ESC êC񫂜NsrhCo PATCH2 ubQ DB2 MVS 4.1 ~ъC 20 - ϽeAMVS W DB2 ЅOԡˇB (expression ? BETWEEN ?) BETWEEN zC}ʐoˡΩ{|P IBM ODBC X{Nzg (expression >= ? and expression <= ?)C 21 - Nxs{ìʪ„ OUTPUT Ѕ]w SQL_NULL_DATA 22 - PATCH2 |P IBM ODBC X{퐰i~X (OUTER join)C oO]bъ coll WL 254 ˪r񩬀~XzA ъ{|с SELECT DISTINCT col1 ORDER BY col1A y DB2 UDB ê^~ (] DB2 UDB bъpj 254 񩝞 23 - 񚐆zL cbColDef=0 XЅJ 24 - sMۿʼr 25 - sp㬢ۿ - hr񩐻zs 26 - N SQL { 464 ê^ъ{ - ьwê^G› 27 - SQLTables ъ TABLETYPE rAYъ{wF@˪ 28 - ۃ 29 - p㬢 ADO ۿ - h x esA x 1 > x > -1 ]Y MDAC уnG^ 30 - Ϳ㫂A񯿤ъxs{ 31 - ^ SQLStatistics IsOWp 32 - m SQL { -727 ]X 4 Bz{ 33 - bӗr񩫂Aê^WO ISO у ( ODBC у) 34 - H CHAR W˪^ CHAR FOR BIT DATA 35 - SQL_DESC_BASE_TABLE_NAMER QnDU^@LݫW - ADO 36 - Od 37 - Od VIII g [ۛT [ۛT DB2 Everywhere w DB2 Everyplace DB2 Everywhere W{bw DB2 EveryplaceC DB2 UDB у 7 sS DB2 UDB tC~]AF@ÚKHheъSCoûSOG * JM̬LS * WjeьS * Mьь * ̐Ne * @~tesS * isѾ񺫵 LJM LJ unъLKiH̺@ DB2 C \ӬϮMЪsA ъiHqLʛY@\ӬC bO\Ӭ X{seuAH޽KٖC LJI b UNIX @~tALJImHGΚьAь˛B@ъ Aъ|сvTC ޽KьS DB2 񋪐@ûSAiHWjъ¡AH񊺴zъq ъOC oÅWj\҇ˬ]wAH񊼛qwr eC ҇˅ʪ ¡к@~tʗЬ҇˅ʪ퓴C ъiH]wI CԮMeCAѪjPC r]w ¡\ъ\ӬݮM񀓴ժrCBjpMrC LC ъnhٖCHъ~U\C iь ъiHnььC ̐Ne DB2 ¡Mъ{eAʪpzLnsC bъ{ ʪA¡@ûSAiHUъoѷWۛTC isѾ DB2 tC~Ѿ HTML CoiъHs񬀐n]w˔ ѾC Ѫ]e\MѪU̐NъC ㇽD F~Aʪѡxnㇽ˿ъuC q DB2 Run-time Client sPusv~ ] DB2 Run-time Client SҝsAHLk GUI uҬs AuiHq DB2 Administration Client GUI uҬsC Search (Search Discovery) Search usCCʪpASearch NLkzL ATM td˺@ ъCOAAъ Known C HP-UX 11 O OOj HP 64 񩥸ъъA]LQnQъ 32 񩔐 ъ{WL 1.75GB @ъOCpGzO 64 񩬮у DB2AN nOCOiC@{î{ésU@ 1 GB @ъO iъC oNe\οʿҪv 1GB @ъOAA[W 0.75GB s@ ъOC pGъQnъo˔uIALiHh˫οAC@οʺ bv񛧪C UCOъOѲMѾG * DB2 EE * Ω{GExtension Software 12/98 PHKL_17795C * ѝοʐ]w $DB2INSTANCE C * zbOUC@ DB2 οAb /etc/services.window nCʪpG db2instance1 50 db2instance2 60 GW ID „Ӫ@ˬC * zѝъ TCP/IP jެkAѶznbAWBnh @z DB2 OC oO]ݛO@ːz{ ëAshell N񯛧CuDB2 A{vDp@~C * ѶnbOUʛο񀛧 DB2 OAѝH db2win (b sqllib/bin ) @rCʪpG db2win db2start db2win db2stop * O~Ѷ DB2 O (Oѓb) ê^ 1042C ʪpG db2win db2start <== OK db2 connect to db <==SQL1042 db2stop <==SQL1042 db2win db2stop <== OK * DB2 EEE * Ω{GExtension Software 12/98 PHKL_17795C * ѝοʐ]w $DB2INSTANCE C * DB2_ENABLE_MEM_WINDOWS nѝ]w TRUEC * zbOUʛC@˫οʬC@˚̓ީ`IAb /etc/services.window nCC@n@NP sοʪWCʪpG === $HOME/sqllib/db2nodes.cfg for db2instance1 === 5 host1 0 7 host1 1 9 host2 0 === $HOME/sqllib/db2nodes.cfg for db2instance2 === 1 host1 0 2 host2 0 3 host2 1 === /etc/services.window on host1 === db2instance10 50 db2instance11 55 db2instance20 60 === /etc/services.window on host2 === db2instance10 30 db2instance20 32 db2instance21 34 * zъ db2win @ DB2 O}YAѪuAъb EE UC Лw DB2 DFS qʛ{ Лw DB2 DFS qʛ{eAroot ˢTw DFS bъA BSъb DFS ά} ShellCH root oXUCOG stop.dfs dfs_cl d /... AQG mount | grep -i dfs pGSoADB2 DFS qʛ{ЛwA˥nsʛC Windows NT q Windows NT UAs DB2 n DB2DOMAINLIST P{sq ʥXCWindows NT A DB2 iъwq@ˮh Windows NT CuwqCь񬀀ъsusnD~|Q C ub Windows NT U DB2 AMqу 7 p UA~iъnC n㬀]wAЪ Administration Guide: Performance (L ) 񀬀uDB2 Registry and Environment VariablesvѸC pXt UCOAъpXtG * ]tWd Oracle ۫㖎 NCHARBNVARCHAR2BNCLOB BFILEC * uvuыAvBuAvuA vOCYnoXHWѶ@OAѝъROBz (CLP)C * w]tWdADB2 UDB Oі DFT_SQLMATHWARN ۫w[ cCADB2 UDB q۫ê^BԬь퓨~iA DFT_SQLMATHWARN ]wC * wҪjpgºì۫A CREATE SERVER ze\ COLSEQ A]w 'I'C * wLANê^ ALTER NICKNAME zC * w OracleBMicrosoft SQL Server Sybase ۫A㡄۫㖎L kM DB2 BIGINT ۫㖎Cw]AOracle r (p,s) ۫ (10 <= p <= 18 s = 0) |M DB2 DECIMAL ۫㖎C MPP 񔐊ݫpX ݜzъ@ SQL zq۫񓴿۫Ab DB2 pXAW MPP 񔐊ݫ񬢜JBsR۫㫂Az| SQL0901N ~Cp X\Ӯ|zqW񓴿J MPP 񔐊ݫC @чzъ FixPak 4]sу^AYiъoÿBJ˓۫AN۫ J MPP 񔐊ݫG 1. bߔъ{픶AX DB2NODE ʚHwъ{@wns `IC EXPORT DB2NODE=x x O`IXC 2. ы@`IsAu]tw`IC CREATE NODEGROUP nodegroup_name ON NODE(x) x O`IXC 3. b`IsыݫC CREATE TABLESPACE tablespace_name IN NODEGROUP nodegroup_name 4. bݫыݫC CREATE TABLE temp_table_name IN tablespace_name 5. Nъ{ INSERT @~񔪿ԡ˿BJG * INSERT INTO temp_table_name SELECT * FROM nickname * INSERT INTO MPP_partitioned_table SELECT * from temp_table_name N INSERT z񔪿ԡːz|zhTw (commit) P Rollback yNCʪpAun Rollback @ːzA{bzѝn Rollback ԡːz C~ApGzP DB2NODE ʚ㼍`IXANѝъ{ ۫]AMߡssC oÿBJiHzq۫񓴿۫AN۫J MPP 񔐊ݫCݜz ъ@ːzq۫񓴿۫AsR MPP 񔐊ݫ ۫㫂A| SQL0901N ~Cb DB2 Universal Database у 8 N|RC DataJoiner pXoX񔗝nD|@~C Windows NT BթۛT̝z{ uۛT̝z{vѾiAъBABb DB2 Warehouse Manager for Windows NT CD WC Bլ—Ю IL_ICM.ZIP o˔YA DB2 Warehouse Manager for Windows NT CD DB2\IL ϓC YnwB՘¬uۛT̝z{vAѲw^լ DB2 Warehouse Manager for Windows NTAH Windows NT BլʪѲM ѾC w DB2 Warehouse Manager for Windows NT Aq DB2\IL ϓN IL_ICM.ZIPΩДYw DB2 Warehouse Manager for Windows NT ϓ WC TwДY{wѓTAHbYΩыϓcC ΩДYAюʚ LC_ALL ѝq En_US Iw_ILC Yn ]wG 1. } Windows NT xAbtьWUC 2. bteA@UʅAMߗMt㛤q LC_ALL C 3. @UAHь㡄sޫϩCNq En_US Iw_ILC 4. @U]wsC 5. te񊜜xC {bwwBլuۛT̝z{vC ʛ Windows Lkʛ DB2 SNA SPM Yzъ Microsoft SNA Server у 4 SP3 HWуA DB2 SNA SPM ibsʛѓ`ʛCd \sqllib\<οʪW>\db2diag.log A HoUCьG 2000-04-20-13.18.19.958000 Instance:DB2 Node:000 PID:291(db2syscs.exe) TID:316 Appid:none common_communication sqlccspmconnmgr_APPC_init Probe:19 SPM0453C ] Microsoft SNA Server хʛAHPBI̝z{хʛC 2000-04-20-13.18.23.033000 Instance:DB2 Node:000 PID:291(db2syscs.exe) TID:302 Appid:none common_communication sqlccsna_start_listen Probe:14 DIA3001E х\ʛ "SNA SPM"C 2000-04-20-13.18.23.603000 Instance:DB2 Node:000 PID:291(db2syscs.exe) TID:316 Appid:none common_communication sqlccspmconnmgr_listener Probe:6 DIA3103E APPC qHwoс~CAPPC verb "APPC(DISPLAY 1 BYTE)". Dnê^X "F004"Cnê^X "00000000"C Y db2diag.log oABWOMzsʛAz ѝG 1. Is db2stopC 2. ʛ SnaServer A{ (Y|хʛ)C 3. Is db2startC Ad db2diag.log AHTwSAK[LC Windows NT Windows 2000 W DB2 Ab߃D b DB2 for Windows NT Windows 2000 wAw{|ы Windows AAwC@ˬAAbCYnAݪa DB2Aw{ |PUCъvQP DB2 ApAbG * @@~t@Ѹ * ы token Ѿ * W[tB * HAުnJ * {Åh tokenC pGznъPAb߿ DB2 AъAzѝNoÿъvQPA bC FoÿъvQAAb߇w DB2 ~ϓ]ѝgJvQC DB2 Administration Server A (DB2DAS00 A) Ab]ѝͪʛ 񊛜Ѫ DB2 A (]NOAAbѝ Power Users s) vAH񊇴ѶѪʀ̝z DB2 οʥͪ DB2 SYSADM vC nTwʪ|b۫㡌x(DWC)ъъwq{ pGznNuDB2 xs{ýϩmvʽыxs{ݺ@u۫㡌x (DWC)v񬀿ъwq{˿ъAzѝJUCzxs{ con.close();zeG con.commit(); pGSJoːzAxs{îʛ|bxs{Üq DWC Q RollbackC DWC ʪъwq{AѝnTa COMMIT Ѷt DB2 AHӪb۫wсF]NOAzѝN COMMIT z[ъ wq{C Windows NT WqͿ pGъhs@x Windows NT Server W READ PERM DB A ˪bWOъtO@ъ𥸿˽ы DB2 DataLinkA|pw }CMAbAъPOߑ}ʡnD|eAA˼O МqWͿˬACYbOAъiHά eA]MbͿCOApGμOb Windows NT u@WAh |oсDC пMޫμOb Windows NT AWNn \\HKEY_LOCAL_MACHINE\SYSTEM \CurrentControlSet\Services\Lanmanserver\Parameters\EnableOpLocks ]w 0CЪn]wACݐzL@ъ𥸜qqu@sAWΫA nD@w|eAA|МqͿˬAC]AʪnD|s ʝOC пMޫάtvTOo|vTʪzL@ъ𥸜qAsά ګCY]wApGμOzLMAу@ъ𥸿˪s (LkqPq)AGO|qͿˬAnDC]AOL SсC : bʪpUApGΪsOуsA˽DzL@ъAO ߑOL|pwoсC Life Sciences Data Connect s~h ԡs~hwsW FixPak 4 Life Sciences Data ConnectC@˼Oъ AIX W DocumentumA@˼Oъ Windows NT W ExcelC~Aݫc ~hwq AIX Ӫ Windows NTB SolarisBLinux HP-UX tC FixPak 5 b AIX W BLAST ~hAwsW DB2 Life Sciences Data ConnectCDocumentum ~hwq AIX ӿ Windows NTB Windows 2000 Solaris @~C Y FixPak 6ABLAST ~hwq AIX ӿ Windows NTBWindows 2000BHP-UX Solaris @~C `N- Life Sciences Data Connect ]A Apache Software M ICU {XC{ XOu{pvAaѶьqь߽OA]A~AԮBSwъ ~AъMIv߽OC~AIBM tvdC Apache Software License, у 1.1 Copyright (c) 1999-2001 The Apache Software Foundation. All rights reserved. ICU 1.8.1 Msу Copyright (c) 1995-2001 International Business Machines Corporation M ѪAvʪC SQL U{[j\ SQL U{uҝ{b\ъݫXwP "=" XBlC[ j\ӬuXv (b SQL U{uҬuXvW@Uu XvsNӜʛˇ)A]tXBlUȪCьC iъBl "="B"<>"B"<"B">"B"<=" ">="C SQL U{OU ъы SQL zuCѪiъuROv(uѵv)B uv(uыvuыov)Bxs{ýϩm (uJ SQL xs{vF) u۫㡌xv(SQL BzBJ)C ѸP_mO ݜzJ db2 ? backup |X{ѓTۛTCѓTXG BACKUP DATABASE database-alias [USER username [USING password]] [TABLESPACE (tblspace-name [ {,tblspace-name} ... ])] [ONLINE] [INCREMENTAL [DELTA]] [USE TSM [OPEN num-sess SESSIONS]] | TO dir/dev [ {,dir/dev} ... ] | LOAD lib-name [OPEN num-sess SESSIONS]] [WITH num-buff BUFFERS] [BUFFER buffer-size] [PARALLELISM n] [WITHOUT PROMPTING] ݜzJ db2 ? restore |X{ѓTۛTCѓTXG RESTORE DATABASE source-database-alias { restore-options | CONTINUE | ABORT }"; restore-options:"; [USER username [USING password]] [{TABLESPACE [ONLINE] |"; TABLESPACE (tblspace-name [ {,tblspace-name} ... ]) [ONLINE] |"; HISTORY FILE [ONLINE]}] [INCREMENTAL [ABORT]]"; [{USE TSM [OPEN num-sess SESSIONS] |"; FROM dir/dev [ {,dir/dev} ... ] | LOAD shared-lib"; [OPEN num-sess SESSIONS]}] [TAKEN AT date-time] [TO target-directory]"; [INTO target-database-alias] [NEWLOGPATH directory]"; [WITH num-buff BUFFERS] [BUFFER buffer-size]"; [DLREPORT file-name] [REPLACE EXISTING] [REDIRECT] [PARALLELISM n]"; [WITHOUT ROLLING FORWARD] [WITHOUT DATALINK] [WITHOUT PROMPTING]"; "Warehouse Manager" "DB2 Warehouse Manager" ʪX{b~M~Ѿ "Warehouse Manager" "DB2 Warehouse Manager"C IX g . `N ˪bѪ۫aAIBM oуʗU~BA\Cn Dbzʪb񺛤O_iъoÝ~PAAVݪa IBM ANݼdC уЪb IBM ~B{AAьtьuӿъ IBM ~B{ ACunхI IBM z]vAѶ\Ӽݬ~B{A iHN IBM ~B{ACLAѪD IBM ~B{BAb B@WPAdѶъC boуЮѾi]t IBM ʥͪMQMQˢCупъ ezMQѶvC ziHъСު˼dvA˿HG IBM Director of Licensing IBM Corporation North Castle Drive Armonk, NY 10504-1785 U.S.A. YndG񩝞 (DBCS) ۛTS\vyApz۫a IBM z ]AъСުHG IBM World Trade Asia Corporation Licensing 2-31 Roppongi 3-chome, Minato-ku Tokyo 106, Japan UCqYP˛kޑAYAъG IBM „H{уA ѶьqьO (]AiԮXSwъO)CY êabYѵW\WzOAh˜LC уi|̐NW㬮LW_~C]AIBM |wΡqFNΡq ߬eJsCPAIBM oHi () уʗ񊬀~ () {C уЇD IBM uOF޽K˗AoÀ@Ѷ{iC ˿ÀWeDу IBM ~e@ѸAъ߿ъˀ˥ IC ݜzЩۛT IBM AzYv IBM H{Aݬު˿ъe TAѝzt_ѶdѶC у{񺔏vY㜵o۫AHKъUCۛTi IBMCU CۛTOG (1) Wыы{PѪ{ (]A{) ۛT ު (2) 񼿤ъwѵۛTެkCYѶDpG IBM Canada Limited Office of the Lab Director 1150 Eglinton Ave. East North York, Ontario M3C 1H7 CANADA Wz۫㬀oSݡnѾAbYÜpUѝIOޜoъC уЮʗyzѶ{ʪiъv@O IBM ʗAuIBM ߪXvBuۃ{휘vXvѶPѪXWdC ʺtѶө۫AʼOoUF]P@~U oGAi|jtCѸqiӼOb}o񬀿tWA] OiHq@٬tPPGC㪌ѸqAOQъk opAۃGi|PCуЬъSA XAъ۫C уЮʗD IBM ~ۛTAY@Н~ДAXnѪ }̇DoCIBM хLoÝ~A]LkT{oýD IBM ~ BeBѶ~ѪDiO_юL~CpGzD IBM ~ ӪѶAwV˝~Д˼dC IBM х˛VѶzA„N IBM υwAiӮхѲn pUʚM^C уtڜ`~훉ъ۫񊐰idCFкҬAoâd ]AHBqBtPM~WCoêWюۀcAYPѶqW Mݺ}pPAѮXC @vvG у]tlyѬdʔъ{AъHUϺ@~ѡxW{]p̐NC ziHoBъBPԮGX@~ѡx (ъʅ…gd{) 񺔐ъ{]p¡ъ{ϬAHѶsBκ񊗝Goâd {ALIO IBMCoâdʼхgLҬC]AIBM |O ʮtьo{wBAO\C oâd{OѶlс@C@ѸѶѸAѝҪUC @vnG (C) (your company name) (year). Portions of this code are derived from IBM Corp. Sample Programs. (C) Copyright IBM Corp. _enter the year or years_. All rights reserved. ˅ UCNy (HP (*) ь) O IBM qbBѪ۫aԬ˅C ACF/VTAM IBM AISPO IMS AIX IMS/ESA AIX/6000 LAN DistanceMVS AIXwindows MVS/ESA AnyNet MVS/XA APPN Net.Data AS/400 OS/2OS/390 BookManager OS/400 CICS PowerPC C Set++ QBIC C/370 QMF DATABASE 2 RACF DataHub RISC System/6000 DataJoiner RS/6000 DataPropagator S/370 DataRefresher SP DB2 SQL/DS DB2 Connect SQL/400 DB2 Extenders System/370 DB2 OLAP Server System/390 DB2 Universal Database SystemView Distributed Relational VisualAge Database Architecture VM/ESA DRDA VSE/ESA eNetwork VTAM Extended Services WebExplorer FFST WIN-OS/2 First Failure Support Technology UCNyOѪq˅U˅G MicrosoftBWindowsBWindows NT OLnq˅U˅C Java HʪP Java ˅PAH Solaris O Sun Microsystems, Inc. bBѪ۫aԬ˅C Tivoli P NetView O Tivoli Systems Inc. bBѪ۫aԬ˅C UNIX O X/Open Company Limited bBѪ۫aԬU˅Ag qvliъC ѪqB~AW (HԙP (*) ь) iӼOѪq˅𮊬A xC ---------------------------------------------------------------------- (1) A Service Policy defines a set of quality of service options that should be applied to this messaging operation. These options include message priority and message persistence. See the MQSeries Application Messaging Interface manual for further details.