Introduction to teradata warehouse

3,269 views

Published on

Published in: Technology
2 Comments
1 Like
Statistics
Notes
  • http://www.dbmanagement.info/Tutorials/TeraData.htm
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here
  • http://www.dbmanagement.info/Tutorials/TeraData.htm
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here
No Downloads
Views
Total views
3,269
On SlideShare
0
From Embeds
0
Number of Embeds
2
Actions
Shares
0
Downloads
256
Comments
2
Likes
1
Embeds 0
No embeds

No notes for slide

Introduction to teradata warehouse

  1. 1. Teradata DatabaseIntroduction to Teradata Warehouse Release V2R6.2 (Teradata Database)/ Release 8.2 (Teradata Warehouse) B035-1091-096A September 2006
  2. 2. The product described in this book is a licensed product of Teradata, a division of NCR Corporation.NCR, Teradata and BYNET are registered trademarks of NCR Corporation.Adaptec and SCSISelect are registered trademarks of Adaptec, Inc.EMC, PowerPath, SRDF, and Symmetrix are registered trademarks of EMC Corporation.Engenio is a trademark of Engenio Information Technologies, Inc.Ethernet is a trademark of Xerox Corporation.GoldenGate is a trademark of GoldenGate Software, Inc.Hewlett-Packard and HP are registered trademarks of Hewlett-Packard Company.IBM, CICS, DB2, MVS, RACF, OS/390, Tivoli, and VM are registered trademarks of International Business Machines Corporation.Intel, Pentium, and XEON are registered trademarks of Intel Corporation.KBMS is a registered trademark of Trinzic Corporation.Linux is a registered trademark of Linus Torvalds.LSI, SYM, and SYMplicity are registered trademarks of LSI Logic Corporation.Active Directory, Microsoft, Windows, Windows Server, and Windows NT are either registered trademarks or trademarks of MicrosoftCorporation in the United States and/or other countries.Novell is a registered trademark of Novell, Inc., in the United States and other countries. SUSE is a trademark of SUSE LINUX Products GmbH,a Novell business.QLogic and SANbox are registered trademarks of QLogic Corporation.SAS and SAS/C are registered trademark of SAS Institute Inc.Sun Microsystems, Sun Java, Solaris, SPARC, and Sun are trademarks or registered trademarks of Sun Microsystems, Inc. in the U.S. or othercountries.Unicode is a registered trademark of Unicode, Inc.UNIX is a registered trademark of The Open Group in the US and other countries.NetVault is a trademark and BakBone is a registered trademark of BakBone Software, Inc.NetBackup and VERITAS are trademarks of VERITAS Software Corporation.Other product and company names mentioned herein may be the trademarks of their respective owners.THE INFORMATION CONTAINED IN THIS DOCUMENT IS PROVIDED ON AN “AS-IS” BASIS, WITHOUT WARRANTY OF ANY KIND, EITHEREXPRESS OR IMPLIED, INCLUDING THE IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR NON-INFRINGEMENT. SOME JURISDICTIONS DO NOT ALLOW THE EXCLUSION OF IMPLIED WARRANTIES, SO THE ABOVE EXCLUSION MAYNOT APPLY TO YOU. IN NO EVENT WILL NCR CORPORATION (NCR) BE LIABLE FOR ANY INDIRECT, DIRECT, SPECIAL, INCIDENTAL ORCONSEQUENTIAL DAMAGES, INCLUDING LOST PROFITS OR LOST SAVINGS, EVEN IF EXPRESSLY ADVISED OF THE POSSIBILITY OF SUCHDAMAGES.The information contained in this document may contain references or cross references to features, functions, products, or services that arenot announced or available in your country. Such references do not imply that NCR intends to announce such features, functions, products,or services in your country. Please consult your local NCR representative for those features, functions, products, or services available in yourcountry.Information contained in this document may contain technical inaccuracies or typographical errors. Information may be changed or updatedwithout notice. NCR may also make improvements or changes in the products or services described in this information at any time without notice.To maintain the quality of our products and services, we would like your comments on the accuracy, clarity, organization, and value of thisdocument. Please e-mail: teradata-books@lists.ncr.comAny comments or materials (collectively referred to as “Feedback”) sent to NCR will be deemed non-confidential. NCR will have no obligationof any kind with respect to Feedback and will be free to use, reproduce, disclose, exhibit, display, transform, create derivative works of anddistribute the Feedback and derivative works thereof without limitation on a royalty-free basis. Further, NCR will be free to use any ideas,concepts, know-how or techniques contained in such Feedback for any purpose whatsoever, including developing, manufacturing, or marketingproducts or services incorporating Feedback.Copyright © 2002–2006 by NCR Corporation. All Rights Reserved.
  3. 3. PrefacePurpose This book provides an introduction to the Teradata Warehouse covering the following broad topics: • The relational model and Teradata Database architecture • Teradata Database hardware and software architecture • Teradata RASUI (reliability, availability, serviceability, usability, and installability) • Communication between the client and the Teradata Database • Data definitions and data manipulation using Structured Query Language (SQL) • Data distribution and data access methods • Concurrent control and transaction recovery • International character support • Query and database analysis tools • Database security and system administration • Managing and monitoring the Teradata DatabaseAudience This book is intended for users who interface with the Teradata Warehouse. Such individuals may include database users or administrators.Supported Software Release This book supports Teradata® Database Release V2R6.2 and Teradata® Warehouse Release 8.2.Prerequisites To gain an understanding of Teradata Warehouse, you should be familiar with the following: • Basic computer technology • System hardware • Teradata Tools and UtilitiesIntroduction to Teradata Warehouse iii
  4. 4. PrefaceChanges to This BookChanges to This Book This book includes the following changes to support the current release. Date Description September 2006 • Reorganized parts of the book. • Revised / amplified the chapter on: • The data warehouse • The Teradata Warehouse • Database objects, database and users • International language support • Query and database analysis tools • Teradata database security • Updated the book for V2R6.2-specific features, including Write-Ahead Logging (WAL). November 2005 • Reorganized the book. • Revised the chapter on database security. • Added information on the following features to appropriate chapters: • User-defined types (UDTs) • User-defined methods (UDMs) • Teradata Active System Management (TASM) • Partitioned Primary Index (PPI) for global temporary and volatile tables • Enhancements to Teradata System Emulation Tool (SET)Additional Information Additional information that supports this product and the Teradata Database is available at the following Web sites.iv Introduction to Teradata Warehouse
  5. 5. Preface References to Microsoft Windows Type of Information Description Source Overview of the The Release Definition provides the http://www.info.ncr.com/ release following information: Click General Search. In the Publication Product ID Information too late • Overview of all the products in the field, enter 1725 and click Search to bring up the for the manuals release following Release Definition: • Information received too late to be • Base System Release Definition included in the manuals B035-1725-096K • Operating systems and Teradata Database versions that are certified to work with each product • Version numbers of each product and the documentation for each product • Information about available training and support center Additional Use the NCR Information Products http://www.info.ncr.com/ information related Publishing Library site to view or download Click General Search, and select Software - Teradata to this product the most recent versions of all manuals. Database for a list of all of the publications for this Specific manuals that supply related or release. additional information to this manual are listed. CD-ROM images This site contains a link to a downloadable http://www.info.ncr.com/ CD-ROM image of all customer Click General Search. In the Title or Keyword field, documentation for this release. Customers enter CD-ROM, and Click Search. are authorized to create CD-ROMs for their use from this image. Ordering Use the NCR Information Products http://www.info.ncr.com/ information for Publishing Library site to order printed Click How to Order under Print & CD Publications. manuals versions of manuals. General information The Teradata home page provides links to Teradata.com about Teradata numerous sources of information about Teradata. Links include: • Executive reports, case studies of customer experiences with Teradata, and thought leadership • Technical information, solutions, and expert advice • Press releases, mentions and media resourcesReferences to Microsoft Windows This book refers to “Microsoft Windows.” For Teradata Database V2R6.2, such references mean Microsoft Windows Server 2003 32-bit and Microsoft Windows Server 2003 64-bit.Introduction to Teradata Warehouse v
  6. 6. PrefaceReferences to Microsoft Windowsvi Introduction to Teradata Warehouse
  7. 7. Table of Contents Preface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . iii Purpose . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . iii Audience . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . iii Supported Software Release . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . iii Prerequisites . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . iii Changes to This Book . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . iv Additional Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . iv References to Microsoft Windows. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .v Chapter 1: The Data Warehouse . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1 What is a Data Warehouse? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1 What is an Active Data Warehouse? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1 Strategic Queries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2 Tactical Queries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2 The Active Teradata Warehouse . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2 Active Load . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2 Active Access. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3 Active Events . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3 Active Workload Management . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3 Active Enterprise Integration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3 Active Availability . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4SECTION 1 Teradata Warehouse Overview Chapter 2: The Teradata Warehouse . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .7 The Teradata Database . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .7 Attachment Methods . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .7 Teradata Structured Query Language . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .7Introduction to Teradata Warehouse vii
  8. 8. Table of Contents Character Support . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .8 Teradata Database Capabilities . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .8 Teradata Database as a “Single Data Store” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .9 Teradata Database Server Software . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .10 Software Installation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .10 Teradata Tools and Utilities. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .11 Mainframe Utilities . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .11 Teradata Utility Pack for Network-Attached Clients . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .12 Database Management and Query Analysis Tools . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .13 Load and Unload Utilities . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .14 Teradata Meta Data Services. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .15 Preprocessors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .15 Teradata Query Director . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .16 Storage Management Utilities. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .16 For More Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .16 Chapter 3: The Teradata Database Model . . . . . . . . . . . . . . . . . . . . . . . .19 What is a Relational Model?. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .19 What is a Relational Database? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .19 Set Theory and Relational Database Terminology . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .19 Tables, Rows, and Columns . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .20 Table Constraints . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .20 Permanent and Temporary Tables. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .20 Global Temporary Tables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .20 Volatile Tables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .21 Derived Tables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .21 Rows and Columns . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .21 For More Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .21SECTION 2 Teradata Architecture Chapter 4: Teradata Database Hardware and Software Architecture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .25 SMP and MPP Platforms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .25 The BYNET. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .26viii Introduction to Teradata Warehouse
  9. 9. Table of Contents Boardless BYNET . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 Disk Arrays . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 Logical Units. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 Pdisks and Vdisks. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 Cliques . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 Hot Standby Nodes. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 Virtual Processors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29 Parsing Engine . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29 Access Module Processor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30 AMP Clusters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31 Request Processing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31 The Dispatcher . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32 The AMPs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33 Example: SQL Statement. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34 Parallel Database Extensions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34 Trusted Parallel Applications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35 PDE and MPP Systems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35 Start and Stop PDE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35 The Teradata File System . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35 Workstation Types and Available Platforms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36 System Console . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36 Administration Workstation. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36 Teradata Graphical User Interface. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36 How the Teradata GUI Communicates with the Teradata Database . . . . . . . . . . . . . . . . 37 Running the Teradata GUI . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37 Teradata General Security Service . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37 For More Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37 Chapter 5: Teradata RASUI . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39 Software Fault Tolerance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39 Vproc Migration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39 Fallback Tables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40 AMP Clusters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 One-Cluster Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 Smaller Cluster Configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 Journaling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42 Teradata Archive/Recovery . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43 Table Rebuild Utility . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44Introduction to Teradata Warehouse ix
  10. 10. Table of Contents Hardware Fault Tolerance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .44 Teradata Replication Solutions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .46 For More Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .47 Chapter 6: Communication Between the Client and the Teradata Database . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .49 Attachment Methods . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .49 CLIv2 for Channel-Attached Systems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .50 What CLIv2 for Channel-Attached Clients Does . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .50 Teradata Director Program. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .50 Server. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .50 CLIv2 for Network-Attached Systems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .51 What CLIv2 for Network-Attached Clients Does . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .51 Micro Teradata Director Program . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .52 Micro Operating System Interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .52 Other Types of Data Communications. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .53 WinCLI . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .53 ODBC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .54 JDBC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .54 For More Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .54SECTION 3 Using the Teradata Database Chapter 7: Database Objects, Databases and Users . . . . . . . . . . .59 Tables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .59 Queue Tables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .59 Queue Tables and Base Tables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .59 Event Processing. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .60 Views . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .60 What is in a View? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .60 Why Use Views? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .60 Restrictions on Using Views . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .61 Teradata Stored Procedures . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .61 Why Use Teradata Stored Procedures? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .61 Elements of a Teradata Stored Procedure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .62x Introduction to Teradata Warehouse
  11. 11. Table of Contents External Stored Procedures . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 62 Creating External Stored Procedures . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 62 Macros . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63 SQL Statements Related to Macros . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63 Single-User and Multi-User Macros . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63 Macro Processing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63 Triggers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64 Types of Triggers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64 When Do Triggers Fire?. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64 ANSI-Specified Order . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65 Why Use a Trigger? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65 User-Defined Functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65 Creating User-Defined Functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65 Table Function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66 User-Defined Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66 Functions That Operate on UDTs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67 User-Defined Methods . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67 Instance Methods . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67 Constructor Methods . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67 Databases and Users . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67 Databases and Users. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67 Creating a Finance and Administration Database . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68 For More Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69 Chapter 8: Structured Query Language . . . . . . . . . . . . . . . . . . . . . . . . . . 71 Why SQL? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 71 Types of SQL Statements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 71 Data Definition Language Statements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 72 Data Control Language Statements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 73 Data Manipulation Language Statements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 73 SQL Statement Syntax . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 74 Statement Execution . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75 Statement Punctuation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75 The SELECT Statement . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 76 SELECT Statement and Set Operators . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 76 SELECT Statement and Joins . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 76 SQL Data Types. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77 Data Type Phrase . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77 Teradata and ANSI-Compliant Data Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77Introduction to Teradata Warehouse xi
  12. 12. Table of Contents Data Type Attributes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .78 Teradata Recursive Query . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .79 SQL Functions. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .79 Scalar Functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .79 Aggregate Functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .79 Ordered Analytical Functions. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .80 Cursors. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .80 For More Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .81 Chapter 9: SQL Application Development . . . . . . . . . . . . . . . . . . . . . . . .83 Embedded SQL Applications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .83 How Does an Application Program Use Embedded SQL?. . . . . . . . . . . . . . . . . . . . . . . . . .83 Supported Languages and Platforms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .84 Macros as SQL Applications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .84 SQL Used to Create a Macro. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .84 Macro Usage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .85 SQL Used to Modify a Macro . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .85 SQL Used to Delete a Macro . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .85 Teradata Stored Procedures as SQL Applications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .86 SQL Used to Create Stored Procedures . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .86 Stored Procedure Example. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .86 SQL Used to Execute a Stored Procedure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .87 DDL Statements with Stored Procedures . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .87 The EXPLAIN Statement . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .88 How Is EXPLAIN Useful? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .88 EXPLAIN With Simple Join Index Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .88 Third-Party Development . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .90 TS/API Products. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .90 Compatible Third-Party Software Products . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .90 Performance Monitor/Application Programming Interface . . . . . . . . . . . . . . . . . . . . . . . .90 For More Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .90 Chapter 10: Data Distribution and Data Access Methods . . . . .93 Teradata Database Indexes. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .93 Primary Indexes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .94 Primary Indexes and Data Distribution. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .94 Primary Key . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .94xii Introduction to Teradata Warehouse
  13. 13. Table of Contents Foreign Key. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 94 How Are Primary Indexes and Primary Keys Related?. . . . . . . . . . . . . . . . . . . . . . . . . . . . 95 Partitioned Primary Indexes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 95 How Do Partitioned and Non-Partitioned Primary Indexes Compare? . . . . . . . . . . . . . 96 Secondary Indexes. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 96 Secondary Index Subtables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 96 How Do Primary and Secondary Indexes Compare? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 97 Join Indexes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 97 Single-Table Join Indexes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 97 Multi-Table Join Indexes. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98 Aggregate Join Indexes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98 Sparse Join Indexes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98 Hash Indexes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99 Index Specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99 Creating Indexes. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99 Strengths and Weaknesses of Various Types of Indexes . . . . . . . . . . . . . . . . . . . . . . . . . . 99 Hashing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101 Identity Column . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 102 Normalization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 102 Normal Forms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 102 First, Second, and Third Normal Forms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 102 Referential Integrity . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 103 Referential Integrity Terminology . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 104 Referencing (Child) Table . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 104 Referenced (Parent) Table. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 104 Why Is Referential Integrity Important? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 105 For More Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 105 Chapter 11: Concurrency Control and Transaction Recovery . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 107 What is Concurrency Control? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 107 Transactions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 107 Definition of a Transaction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 107 Definition of Serializability . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 108 Transaction Semantics. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 108 ANSI Mode Transactions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 108 Teradata Mode Transactions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 109 Locks. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 109 Overview of Teradata Database Locking . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 109Introduction to Teradata Warehouse xiii
  14. 14. Table of Contents Why Do Database Management Systems Require Locking? . . . . . . . . . . . . . . . . . . . . . . .110 Lock Levels . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .110 Levels of Lock Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .111 Automatic Database Lock Levels . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .111 Deadlocks and Deadlock Resolution . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .112 Host Utility Locks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .112 HUT Lock Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .113 HUT Lock Characteristics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .113 Recovery for Transactions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .113 System and Media Recovery . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .114 System Restarts. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .114 Transaction Recovery . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .114 Down AMP Recovery . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .115 Two-Phase Commit Protocol . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .115 Definition of Participant . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .115 Definition of Coordinator. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .115 For More Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .116 Chapter 12: The Data Dictionary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .117 What is the Data Dictionary? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .117 Data Dictionary Content. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .117 What is in a Data Dictionary Table?. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .118 Data Dictionary Views . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .121 Who Uses Data Dictionary Views? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .121 SQL Access to the Data Dictionary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .122 For More Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .123 Chapter 13: International Language Support . . . . . . . . . . . . . . . . . .125 Character Set Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .125 What Is a Repertoire?. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .125 Character Representation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .126 External and Internal Character Sets. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .126 Character Data Translation. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .126 What Teradata Database Supports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .127 Teradata Database Character Data Storage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .127 Internal Server Character Sets. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .127 User Data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .127xiv Introduction to Teradata Warehouse
  15. 15. Table of Contents System Dictionary Data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 127 Language Support Modes. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 128 Default Character Set for User Data. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 128 Character Set for System Dictionary Data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 128 Character Set for Dictionary Data Other Than Object Names . . . . . . . . . . . . . . . . . . . . 129 Standard Language Support Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 129 LATIN Character Set . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 129 Compatible Languages. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 130 Japanese Language Support Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 130 Advantages (over Latin) of Storing System Dictionary Data Using KANJI1 . . . . . . . . . 130 Advantages (over Latin or Kanji1) of Storing User Data Using UNICODE . . . . . . . . . 130 Extended Support . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 131 For More Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 131 Chapter 14: Query and Database Analysis Tools . . . . . . . . . . . . . 133 Teradata Visual EXPLAIN . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 133 Teradata System Emulation Tool . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 134 Teradata Index Wizard . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 134 Demographics. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 134 Teradata Statistics Wizard . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 135 Query Capture Facility . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 135 QCD Schema Improvement . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 136 Teradata Index Wizard Support . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 136 Database Query Log . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 136 Target Level Emulation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 137 Database Object Use Count . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 138 For More Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 138SECTION 4 Managing and Monitoring Teradata Chapter 15: Teradata Database Security . . . . . . . . . . . . . . . . . . . . . . 143 Security Library . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 143 Security Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 143 Security Mechanisms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 144Introduction to Teradata Warehouse xv
  16. 16. Table of Contents User Authentication . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .145 Logon Formats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .146 Logon Controls . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .146 Password Format . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .146 Password Controls . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .147 External Authentication . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .147 User Authorization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .148 Roles . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .149 Profiles . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .149 Encryption . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .150 Logon Encryption . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .150 Message Encryption . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .150 Data Integrity Checking . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .150 Directory Management of Users . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .151 Supported Directories . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .151 Directory User Logons. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .151 Integrating Directory Users. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .151 Directory Managed Roles . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .151 Profiles for Directory Users. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .152 Directory Tools . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .152 Monitoring Access to the Database . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .152 Defining a Security Policy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .153 Publishing a Security Policy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .153 For More Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .154 Chapter 16: System Administration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .155 Roles and Profiles . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .155 Session Management . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .156 Session Requests. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .156 Establishing a Session . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .156 Logon Operands. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .156 Maintenance Utilities . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .157 For More Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .160 Chapter 17: Database Management Tools and Utilities . . . . . .161 Data Archiving Utilities . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .161 Teradata Archive/Recovery Utility . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .161xvi Introduction to Teradata Warehouse
  17. 17. Table of Contents Open Teradata Backup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 162 Data Load and Export Utilities . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 162 Teradata MultiLoad . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 162 Teradata FastLoad . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 163 Teradata Parallel Data Pump . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 163 Teradata FastExport Utility. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 163 Session and Configuration Management Tools . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 164 System Resource and Workload Management Tools and Protocols . . . . . . . . . . . . . . . . . . . 165 Write Ahead Logging (WAL) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 165 Ferret Utility . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 166 Priority Scheduler . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 166 Teradata MultiTool . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 167 Teradata Active System Management (TASM). . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 167 Teradata SQL Assistant. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 169 For More Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 170 Chapter 18: Aspects of System Monitoring. . . . . . . . . . . . . . . . . . . . . 171 Teradata Manager . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 171 Teradata Graphical User Interface (GUI). . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 174 Resource Usage (ResUsage) Monitoring . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 175 Resource Usage Tables and Views . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 176 Resource Usage Data Categories. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 176 Resource Usage Data Handling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 176 Resource Usage Macros . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 176 How to Control Collection and Logging of Resource Usage Data . . . . . . . . . . . . . . . . . 176 Summary Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 177 Performance Monitoring . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 177 Account String Expansion (ASE) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 177 The TDPTMON . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 177 System Management Facility. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 178 The Performance Monitor/Application Programming Interface . . . . . . . . . . . . . . . . . . 178 For More Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 178 Chapter 19: Teradata Meta Data Services . . . . . . . . . . . . . . . . . . . . . 181 What is Metadata?. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 181 Types of Metadata. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 181 Teradata Meta Data Services . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 182Introduction to Teradata Warehouse xvii
  18. 18. Table of Contents Creating the Teradata Meta Data Repository . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .183 Connecting to the Teradata Meta Data Repository . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .183 For More Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .184 Glossary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .185 Index . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .189xviii Introduction to Teradata Warehouse
  19. 19. CHAPTER 1 The Data Warehouse This chapter presents an overview of the Teradata Warehouse. Topics include: • What is a data warehouse? • What is an active data warehouse? • The active Teradata WarehouseWhat is a Data Warehouse? Initially, the data warehouse was a historical database, enterprise-wide and centralized, containing data derived from an operational database. The data in the data warehouse was: • Subject-oriented • Integrated • Usually identified by a timestamp • Nonvolatile, that is, nothing was added or removed Rows in the tables supporting the operational database were loaded into the data warehouse (the historical database) after they exceeded some well-defined date. Data could be queried, but the responses returned only reflected historical information. In this sense, a data warehouse was initially static, and even if a historical data warehouse contained data that was being updated, it would still not be an active data warehouse.What is an Active Data Warehouse? An active data warehouse: • Provides a single up-to-date view of the enterprise on one platform. • Represents a logically consistent store of detailed data available for strategic, tactical and event driven business decision making. • Relies on timely updates to the critical data - as close to real time as needed. • Supports short, tactical queries that return in seconds, alongside of traditional decision support.Introduction to Teradata Warehouse 1
  20. 20. Chapter 1: The Data WarehouseThe Active Teradata WarehouseStrategic Queries Strategic queries represent business questions that are intended to draw strategic advantage from large stores of data. Strategic queries are often complex queries, involving aggregations and joins across multiple tables in the database. They are sometimes long-running and tend not to have a strict service level expectation. Strategic queries are sometimes ad hoc. They may require significant database resources to execute and they are often submitted from 3rd party tools.Tactical Queries Tactical queries are short, highly tuned that facilitate action-taking or decision-making in a time-sensitive environment. They usually come with a clear service level expectation and consume a very small percentage of the overall system resources. Tactical queries are usually repetitively executed and take advantage of techniques such as request (query plan) caching and session-pooling.The Active Teradata Warehouse As an active data warehouse, the Teradata Warehouse provides both Strategic Intelligence and Operational Intelligence. • Strategic Intelligence entails delivering intelligence through tools and utilities and query mechanisms that support strategic decision-making. This includes, for example, providing users with simple as well as complex reports throughout the day which indicate the business trends that have occurred and that are occurring, which show why such trends occurred, and which predict if they will continue to occur. • Operational Intelligence entails delivering intelligence through tools and utilities and query mechanisms that support front-line or operational decision-making. This includes, for example, ensuring aggressive Service Levels Goals (SLGs) with respect to high performance, data freshness, and system availability.Active Load The Teradata Warehouse is able to load data actively and in a non-disruptive manner and, at the same time, process other workloads. The Teradata Warehouse delivers Active Load through methods that support continuous data loading. These include streaming from a queue, more frequent batch updates, referred to as mini-batches, and moving changed data from another database platform to the Teradata Warehouse. These methods exercise such Teradata Database features as queue tables and triggers, and use FastLoad, MultiLoad and TPump utilities.2 Introduction to Teradata Warehouse
  21. 21. Chapter 1: The Data Warehouse The Active Teradata Warehouse The Teradata Warehouse can effectively manage a complex workload environment on a “single version of the truth.”Active Access The Teradata Warehouse is able to access analytical intelligence quickly and consistently in support of operational business processes. But the benefit of Active Access entails more than just speeding up user and customer requests. Active Access provides intelligence for operational and customer interactions consistently. Active Access queries, also referred to a tactical queries, support of tactical decision-making at the front-line. Such queries can be informational, such as simply retrieving a customer record or transaction, or they may include complex analytics.Active Events The Teradata Warehouse is able to detect a business event automatically, apply business rules against current and historical data, and initiate operational actions when appropriate. This enables enterprises to reduce the latency between the identification of an event and taking action with respect to it. Active Events entails more than event detection. When notified of "something important,” the Teradata Warehouse presents users with recommendations for appropriate action. The analysis done for users may prescribe the best course of action or give them alternatives from which to choose.Active Workload Management The Teradata Warehouse is able to manage mixed workloads dynamically and to optimize system resource utilization to meet business goals. Teradata Active System Management (TASM) is a portfolio of products that enables the real- time system management required for delivering Active Enterprise Intelligence. TASM assists the database administrator in analyzing and establishing workloads and resource allocation to meet business needs. TASM facilitates monitoring workload requests to ensure that resources are used efficiently and that dynamic workloads are prioritized automatically. TASM also provides state-of-the-art techniques to visualize the current operational environment and to analyze long-term trends. TASM enables database administrators to set SLGs, to monitor adherence to them, and to take any necessary steps to reallocate resources to meet business objectives.Active Enterprise Integration The Teradata Warehouse is able to integrate itself into enterprise business and technical architectures, especially those that support business users, partners, and customers. This simplifies the task of coordinating enterprise applications and business processes. For example, a Teradata event, generated from a database trigger, calls an external stored procedure. It publishes a message via a WebSphere MQ-Series message bus. The message isIntroduction to Teradata Warehouse 3
  22. 22. Chapter 1: The Data WarehouseThe Active Teradata Warehouse delivered to a JMS queue on a Web Logic application server. The Teradata Application Platform (TAP) receives the JMS message, notifies the user via their UI and activates a TAP service or schedules a job for later execution.Active Availability The Teradata Warehouse is able to meet business objectives for its own “uptime.” Moreover, it assists customers in identifying application-specific availability, recoverability, and performance requirements based on the impact of enterprise downtime. The Teradata Warehouse recommends strategies for evolving business continuity. Such strategies range, for example, from Teradatas own “single system” availability through its support for large cliques, hot standby nodes, and fallback4 Introduction to Teradata Warehouse
  23. 23. SECTION 1 Teradata Warehouse OverviewIntroduction to Teradata Warehouse 5
  24. 24. Section 1: Teradata Warehouse Overview6 Introduction to Teradata Warehouse
  25. 25. CHAPTER 2 The Teradata Warehouse This chapter presents an overview of the Teradata Warehouse and its components. Topics include: • The Teradata Database • Teradata database capabilities • Teradata Database as “single data store” • Teradata Database server software • Software Installation • Teradata Tools and UtilitiesThe Teradata Database The Teradata Database is an information repository supported by tools and utilities that make it, as part of the Teradata Warehouse, a complete and active relational database management system.Attachment Methods To support its role in the active warehouse environment, the Teradata Database can use either of two attachment methods to connect to other operational computer systems as illustrated in the following table. This attachment method… Allows the system to be attached… channel directly to an I/O channel of a mainframe computer. network to intelligent workstations and other computers and devices through a Local Area Network (LAN).Teradata Structured Query Language Structured Query Language (SQL) is the language of relational database communication. Teradata SQL, which is broadly compatible with ANSI SQL, extends the capabilities of SQL by adding Teradata-specific extensions to the generic SQL statements. To manipulate data in the Teradata Database, you issue appropriate Teradata SQL statements. You can access, store, and operate on data using Teradata SQL.Introduction to Teradata Warehouse 7
  26. 26. Chapter 2: The Teradata WarehouseTeradata Database Capabilities When you develop applications for the Teradata Database, you should use the most current Teradata SQL syntax because it is the most ANSI-compliant. Teradata SQL still supports older applications written in previous non-ANSI-compliant versions of Teradata SQL. You can run transactions in either Teradata or ANSI mode and these modes can be set or changed. For more information about SQL and Teradata SQL, see Chapter 8: “Structured Query Language.”Character Support Teradata has an international customer base. To accommodate communications in different languages, Teradata supports non-Latin character sets, including, among others, Japanese and Chinese. For detailed information about international character set support, see Chapter 13: “International Language Support.”Teradata Database Capabilities Teradata has designed a system that allows users to view and manage large amounts of data as a collection of related tables. Some of the capabilities of the Teradata Database are listed in the following table. Teradata Database provides… That… capacity includes: • Scaling from Gigabytes to Terabytes of detailed data stored in billions of rows. • Scaling to thousands of millions of instructions per second (MIPS) to process data. parallel processing makes Teradata Database faster than other relational systems. single data store • can be accessed by network-attached and channel-attached systems. • supports the requirements of many diverse clients. fault tolerance automatically detects and recovers from hardware failures. data integrity ensures that transactions either complete or rollback to a stable state if a fault occurs. scalable growth allows expansion without sacrificing performance. SQL serves as a standard access language that permits users to control data.8 Introduction to Teradata Warehouse
  27. 27. Chapter 2: The Teradata Warehouse Teradata Database as a “Single Data Store” Teradata developers designed the Teradata Database from mostly off-the-shelf hardware components. The result was an inexpensive, high-quality system that exceeded the performance of conventional relational database management systems. The hardware components of the Teradata Database evolved from those of a simple database machine into those of a general-purpose, massively parallel computer running the database software as a Trusted Parallel Application (TPA). The architecture includes both single-node, Symmetric Multi-Processing (SMP) systems and multi-node, Massively Parallel Processing (MPP) systems in which the distributed functions communicate by means of a fast interconnect structure. The interconnect structure in the current architecture is the BYNET for MPP systems and the boardless BYNET for SMP systems.Teradata Database as a “Single Data Store” A design goal of the Teradata Database was to provide a single data store for a variety of client architectures. This approach greatly reduces data duplication and inaccuracies that can creep into data that is maintained in multiple stores. This approach to data storage is known as the single version of the truth, and Teradata implements this through heterogeneous client access. Clients can access a single copy of enterprise data and Teradata takes care of such things as data type translation, connections, concurrency, workload management, and so on. The following figure illustrates the idea of heterogeneous client access, where mainframe clients, network-attached workstations, and personal computers can access and manipulate the same database simultaneously. In this figure, the mainframes are attached via channel connections and other systems are attached via network connections. Teradata Database (Single Data Store) Local Area Network Channel IBM Windows UNIX Linux Mainframe Workstation Workstation Workstation 1091G001Introduction to Teradata Warehouse 9
  28. 28. Chapter 2: The Teradata WarehouseTeradata Database Server SoftwareTeradata Database Server Software Teradata Database software resides on the server and implements the relational database environment. The server software includes the following functional modules. This module… Provides… Database Window a tool that you can use to control the operation of the Teradata Database. Teradata Gateway communications support. The server-resident program provides a pathway for applications running on network-attached clients to access the Teradata Database. The Teradata Gateway runs as a separate operating system task. The Gateway software validates messages from clients that generate sessions over the network and it controls encryption. Parallel Data Extensions (PDE) a software interface layer on top of the operating system that enables the database to operate in a parallel environment. For more information about PDE, see “Parallel Database Extensions” on page 34. Teradata Database management software the following modules: • Parsing Engine (PE), which includes: • Session controller • Parser • Optimizer • Step Generator • Dispatcher • Access module processor (AMP) • Teradata file system For more information about the Teradata file system, see “The Teradata File System” on page 35.Software Installation The Parallel Upgrade Tool (PUT) automates much of the installation process for Teradata Database software. There are two major operational modes for PUT.10 Introduction to Teradata Warehouse
  29. 29. Chapter 2: The Teradata Warehouse Teradata Tools and Utilities The operational mode… Does the following… Major upgrade upgrades one or more software products to the next version. Patch upgrade applies patch packages to one or more software products.Teradata Tools and Utilities Teradata Tools and Utilities is a comprehensive suite of tools and utilities designed to operate in the client environment. Using them, users of client systems can access the Teradata Database. Note: Teradata Database runs with or without a channel- or network-attached client. Moreover, the computer on which the utilities are installed can be running Teradata Database software as well.Mainframe Utilities The following table describes Teradata Tools and Utilities on channel-attached clients and what each tool or utilities provides.Introduction to Teradata Warehouse 11

×