Greenplum - Architecture and SQL
eBook - ePub

Greenplum - Architecture and SQL

  1. 940 pages
  2. English
  3. ePUB (mobile friendly)
  4. Available on iOS & Android
eBook - ePub

Greenplum - Architecture and SQL

About this book

Greenplum is the first open source data warehouse. Purchased and improved by EMC, sold to Dell, makes Greenplum one of the most powerful and widely-used systems in the world. This incredible MPP data warehouse is designed for on-premises systems and the cloud. This book details the architecture of the Greenplum Data Warehouse and the SQL commands available. This book is perfect for anyone who designs, administers or queries Greenplum. The book educates readers on how to create tables and indexes, how the data is distributed, and how the system processes the data. Plus, it is followed up with over 700 pages of SQL examples and explanations. The Authors Tera-Tom Coffing, who has written over 75 successful books on Data Warehousing and Leona Coffing, Chief Financial Officer (CFO) of Coffing Data Warehousing bring a combined 40 years of experience of data warehouse knowledge to create this must have book.

Frequently asked questions

Yes, you can cancel anytime from the Subscription tab in your account settings on the Perlego website. Your subscription will stay active until the end of your current billing period. Learn how to cancel your subscription.
No, books cannot be downloaded as external files, such as PDFs, for use outside of Perlego. However, you can download books within the Perlego app for offline reading on mobile or tablet. Learn more here.
Perlego offers two plans: Essential and Complete
  • Essential is ideal for learners and professionals who enjoy exploring a wide range of subjects. Access the Essential Library with 800,000+ trusted titles and best-sellers across business, personal growth, and the humanities. Includes unlimited reading time and Standard Read Aloud voice.
  • Complete: Perfect for advanced learners and researchers needing full, unrestricted access. Unlock 1.4M+ books across hundreds of subjects, including academic and specialized titles. The Complete Plan also includes advanced features like Premium Read Aloud and Research Assistant.
Both plans are available with monthly, semester, or annual billing cycles.
We are an online textbook subscription service, where you can get access to an entire online library for less than the price of a single book per month. With over 1 million books across 1000+ topics, we’ve got you covered! Learn more here.
Look out for the read-aloud symbol on your next book to see if you can listen to it. The read-aloud tool reads text aloud for you, highlighting the text as it is being read. You can pause it, speed it up and slow it down. Learn more here.
Yes! You can use the Perlego app on both iOS or Android devices to read anytime, anywhere β€” even offline. Perfect for commutes or when you’re on the go.
Please note we cannot support devices running on iOS 13 and Android 7 or earlier. Learn more about using the app.
Yes, you can access Greenplum - Architecture and SQL by Tom Coffing,Leona Coffing in PDF and/or ePUB format, as well as other popular books in Computer Science & Data Warehousing. We have over one million books available in our catalogue for you to explore.

Chapter 1 – Introduction to the Greenplum Architecture

β€œThe man who has no imagination has no wings.”
– Muhammad Ali

What is Parallel Processing?

β€œAfter enlightenment, the laundry”
- Zen Proverb
image
β€œAfter parallel processing the laundry, enlightenment!”
- Greenplum Zen Proverb
Two guys were having fun on a Saturday night when one said, β€œI’ve got to go and do my laundry.” The other said, β€œWhat?!” The man explained that if he went to the laundry mat the next morning, he would be lucky to get one machine and be there all day. But, if he went on Saturday night he could get all the machines. Then, he could do all his wash and dry in two hours. Now that’s parallel processing mixed in with a little dry humor!

The Basics of a Single Computer

image
β€œWhen you are courting a nice girl, an hour seems like a second. When you sit on a red-hot cinder, a second seems like an hour. That’s relativity.”
– Albert Einstein
Data on disk does absolutely nothing. When data is requested, the computer moves the data one block at a time from disk into memory. Once the data is in memory, it is processed by the CPU at lightning speed. All computers work this way. The "Achilles Heel" of every computer is the slow process of moving data from disk to memory. The real theory of relativity is to find out how to get blocks of data from the disk into memory faster!

Data in Memory is fast as Lightning

image
β€œYou can observe a lot by watching.”
– Yogi Berra
Once the data block is moved off of the disk and into memory, the processing of that block happens as fast as lightning. It is the movement of the block from disk into memory that slows down every computer. Data being processed in memory is so fast that even Yogi Berra couldn't catch it!

Parallel Processing Of Data

image
"If the facts don't fit the theory, change the facts."
-Albert Einstein
Big Data is all about parallel processing. Parallel processing is all about taking the rows of a table and spreading them among many parallel processing units. In Greenplum, these parallel processing units are referred to as Segments. Above, we can see a table called Orders. There are 16 rows in the table. Each segment holds four rows. Now they can process the data in parallel and be four times as fast. What Albert Einstein meant to say was, "If the theory doesn't fit the dimension table, change it to a fact." Each Segment shares nothing and holds a portion of every table.

Symmetric Multi-Processing (SMP) Server

image
A Symmetric Multi-Processing system has multiple processors for extra power, but these processors share a single operating system, memory pool and they share access to the disks. This is a great architecture for speed, similar to a restaurant that is quick and organized, but it lacks the ability for unlimited expansion. When there are too many cooks in the kitchen you need an MPP system that scales many SMP systems together as one parallel processing data warehouse.
A Symmetric Multi-Processing (SMP) system is a single server that is sometimes referred to as a node. Watch next how Greenplum uses these servers (called Segment Servers) to create a Massively Parallel Processing (MPP) system using commodity hardware.

Commodity Hardware Servers are configured for Greenplum

image
Greenplum allows you to utilize commodity hardware servers called a Segment Host. Greenplum also allows you to configure your parallel processes called segments. The number of segments per Segment Host is usually defined by the number of CPU's the Segment Host contains. The Segment Hosts are connected together to create a Massively Parallel Processing (MPP) system from each SMP.
Greenplum allows commodity hardware to be utilized to create one giant Greenplum cluster.

Commodity Hardware Allows For One Segment per CPU

image
Greenplum provides incredible speeds with inexpensive costs by allowing customers to purchase commodity hardware. The rule of thumb is to create one segment per CPU. If you have two dual-core CPU processors in a server you should build four segments. By connecting multiple SMP servers together you can scale your Greenplum cluster in a linear fashion. Double the segments and double your speeds forever!

The Master Host

image
β€’When a user logs into Greenplum, the host will log them in and be responsible for their session.
β€’The host checks the SQL syntax, creates the EXPLAIN plan, checks the security, and builds a plan for the segments to follow.
β€’The host uses system statistics and statistics from the ANALYZE command to build the best plan.
β€’The host doesn't hold user data, but instead holds the Global System Catalog.
β€’The host always delivers the final answer set to the user.
The host is the boss and the segments are the workers. Who doesn't lover their boss? Users login to the host and never communi...

Table of contents

  1. Cover
  2. The Tera-Tom Video Series
  3. Current Books in the Tera-Tom Genius Series
  4. Current Books in the Tera-Tom Genius Series
  5. Our Recommended Book In The Tera-Tom Genius Series
  6. Tera-Tom- Author of over 75 Books
  7. The Best Query Tool Works on all Systems
  8. Trademarks and Copyrights
  9. About Tom Coffing
  10. About Leona Coffing
  11. Contents
  12. Chapter 1 – Introduction to the Greenplum Architecture
  13. Chapter 2 – Greenplum Table Structures
  14. Chapter 3 – Hashing and Data Distribution
  15. Chapter 4 – The Technical Details
  16. Chapter 5 – Physical Database Design
  17. Chapter 6 – Denormalization
  18. Chapter 7 - Nexus
  19. Chapter 8 – The Basics of SQL
  20. Chapter 9 – The WHERE Clause
  21. Chapter 10 – Distinct vs. Group By
  22. Chapter 11 – Aggregation
  23. Chapter 12 – Join Functions
  24. Chapter 13 – Date Functions
  25. Chapter 14 – Conversions and Formatting
  26. Chapter 15 – Sub-query Functions
  27. Chapter 16 – OLAP Functions
  28. Chapter 17 – Temporary Tables
  29. Chapter 18 – Character Strings
  30. Chapter 19 – Interrogating the Data
  31. Chapter 20 – Set Operators Functions
  32. Chapter 21 – View Functions
  33. Chapter 22 – Table Create and Data Types
  34. Chapter 23 – Data Manipulation Language (DML)
  35. Chapter 24 – ANALYZE and VACUUM
  36. Chapter 25 – Greenplum Explain
  37. Chapter 26 – Statistical Aggregate Functions