0%

Book Description

This book contains nearly 700 pages of brilliant Netezza examples ranging from simple commands to advanced procedures. Netezza SQL, like all others in the Genius Series, guides readers in a clear and logical manner using pictures and real-life examples. This book is a must-have for any Netezza environment.

Table of Contents

  1. Cover
  2. The Tera-Tom Genius Series
  3. Tera-Tom- Author of over 50 Books
  4. The Best Query Tool Works on all Systems
  5. Copyright
  6. About Tom Coffing
  7. About Michael Larkins
  8. Contents
  9. Chapter 1 – Basic SQL Functions
    1. Introduction
    2. SELECT * (All Columns) in a Table
    3. Fully Qualifying a Database, Schema and Table
    4. SELECT Specific Columns in a Table
    5. Commas in the Front or Back?
    6. Using Good Form
    7. Using the Best Form for Writing SQL
    8. Place your Commas in front for better Debugging Capabilities
    9. Sort the Data with the ORDER BY Keyword
    10. ORDER BY Defaults to Ascending
    11. Use the Name or the Number in your ORDER BY Statement
    12. Two Examples of ORDER BY using Different Techniques
    13. Changing the ORDER BY to Descending Order
    14. NULL Values sort First in Ascending Mode (Default)
    15. NULL Values sort Last in Descending Mode (DESC)
    16. Major Sort vs. Minor Sorts
    17. Multiple Sort Keys using Names vs. Numbers
    18. Sorts are Alphabetical, NOT Logical
    19. Using A CASE Statement to Sort Logically
    20. How to ALIAS a Column Name
    21. A Missing Comma can by Mistake become an Alias
    22. Using Limit to bring back a Sample
    23. Comments using Double Dashes are Single Line Comments
    24. Comments for Multi-Lines
    25. Comments for Multi-Lines As Double Dashes Per Line
    26. A Great Technique for Comments to Look for SQL Errors
  10. Chapter 2 – The WHERE Clause
    1. The WHERE Clause limits Returning Rows
    2. Using a Column ALIAS throughout the SQL
    3. Double Quoted Aliases are for Reserved Words and Spaces
    4. Character Data needs Single Quotes in the WHERE Clause
    5. Character Data needs Single Quotes, but Numbers Don't
    6. NULL means UNKNOWN DATA so Equal (=) won't Work
    7. Use IS NULL or IS NOT NULL when dealing with NULLs
    8. NULL is UNKNOWN DATA so NOT Equal won't Work
    9. Use IS NULL or IS NOT NULL when dealing with NULLs
    10. Using Greater Than Or Equal To (>=)
    11. AND in the WHERE Clause
    12. Troubleshooting AND
    13. OR in the WHERE Clause
    14. Troubleshooting OR
    15. OR must utilize the Column Name Each Time
    16. Troubleshooting Character Data
    17. Using Different Columns in an AND Statement
    18. Quiz – How many rows will return?
    19. Answer to Quiz – How many rows will return?
    20. What is the Order of Precedence?
    21. Using Parentheses to change the Order of Precedence
    22. Using an IN List in place of OR
    23. The IN List is an Excellent Technique
    24. IN List vs. OR brings the same Results
    25. Using a NOT IN List
    26. A Technique for Handling Nulls with a NOT IN List
    27. A Better Technique for Handling Nulls with a NOT IN List
    28. BETWEEN is Inclusive
    29. BETWEEN Works for Character Data
    30. LIKE uses Wildcards Percent '%' and Underscore '_'
    31. LIKE command Underscore is Wildcard for one Character
    32. LIKE Command Works Differently on Char Vs Varchar
    33. Troubleshooting LIKE Command on Character Data
    34. Introducing the TRIM Command
    35. Quiz – What Data is Left Justified and What is Right?
    36. Numbers are Right Justified and Character Data is Left
    37. Answer – What Data is Left Justified and What is Right?
    38. An Example of Data with Left and Right Justification
    39. A Visual of CHARACTER Data vs. VARCHAR Data
    40. Use the TRIM command to remove spaces on CHAR Data
    41. TRIM Eliminates Leading and Trailing Spaces
    42. Escape Character in the LIKE Command changes Wildcards
    43. Escape Characters Turn off Wildcards in the LIKE Command
    44. Quiz – Turn off that Wildcard
    45. ANSWER – To Find that Wildcard
  11. Chapter 3 – Distinct Vs Group By
    1. The Distinct Command
    2. Distinct vs. GROUP BY
    3. Rules of Thumb for DISTINCT Vs GROUP BY
    4. Quiz – How many rows come back from the Distinct?
    5. Answer – How many rows come back from the Distinct?
  12. Chapter 4 – Review
    1. Testing Your Knowledge 1
    2. Testing Your Knowledge 2
    3. Testing Your Knowledge 3
    4. Testing Your Knowledge 4
    5. Testing Your Knowledge 5
    6. Testing Your Knowledge 6
    7. Testing Your Knowledge 7
  13. Chapter 5 – Aggregation Function
    1. Quiz – You calculate the Answer Set in your own Mind
    2. Answer – You calculate the Answer Set in your own Mind
    3. The 3 Rules of Aggregation
    4. There are Five Aggregates
    5. Quiz – How many rows come back?
    6. Troubleshooting Aggregates
    7. GROUP BY when Aggregates and Normal Columns Mix
    8. GROUP BY Delivers one row per Group
    9. GROUP BY Dept_No or GROUP BY 1 the same thing
    10. Aggregates and Derived Data
    11. Limiting Rows and Improving Performance with WHERE
    12. WHERE Clause in Aggregation limits unneeded Calculations
    13. Keyword HAVING tests Aggregates after they are Totaled
    14. Keyword HAVING is like an Extra WHERE Clause for Totals
    15. Getting the Average Values Per Column
    16. Average Values Per Column For all Columns in a Table
    17. Three types of Advanced Grouping
    18. GROUP BY Grouping Sets
    19. GROUP BY Rollup
    20. GROUP BY Rollup Result Set
    21. GROUP BY Cube
    22. GROUP BY CUBE Result Set
    23. GROUP BY CUBE Result Set
    24. Testing Your Knowledge
    25. Testing Your Knowledge
    26. Testing Your Knowledge
    27. Testing Your Knowledge
    28. Testing Your Knowledge
    29. Final Answer to Test Your Knowledge on Aggregates
  14. Chapter 6 – Join Functions
    1. A two-table join using Non-ANSI Syntax
    2. A two-table join using Non-ANSI Syntax with Table Alias
    3. Aliases and Fully Qualifying Columns
    4. A two-table join using Non-ANSI Syntax
    5. Both Queries have the same Results and Performance
    6. Quiz – Can You Finish the Join Syntax?
    7. Answer to Quiz – Can You Finish the Join Syntax?
    8. Quiz – Can You Find the Error?
    9. Answer to Quiz – Can You Find the Error?
    10. Quiz – Which rows from both tables Won't Return?
    11. Answer to Quiz – Which rows from both tables Won't Return?
    12. LEFT OUTER JOIN
    13. LEFT OUTER JOIN Example and Results
    14. RIGHT OUTER JOIN
    15. RIGHT OUTER JOIN Example and Results
    16. FULL OUTER JOIN
    17. FULL OUTER JOIN Example and Results
    18. Which Tables are the Left and Which are the Right?
    19. Answer - Which Tables are the Left and Which are the Right?
    20. INNER JOIN with Additional AND Clause
    21. ANSI INNER JOIN with Additional AND Clause
    22. ANSI INNER JOIN with Additional WHERE Clause
    23. OUTER JOIN with Additional WHERE Clause
    24. OUTER JOIN with Additional AND Clause
    25. OUTER JOIN with Additional AND Clause Example
    26. Quiz – Why is this Considered an INNER JOIN?
    27. The DREADED Product Join
    28. The DREADED Product Join
    29. The Horrifying Cartesian Product Join
    30. The ANSI Cartesian Join will ERROR
    31. Quiz – Do these Joins Return the Same Answer Set?
    32. Answer – Do these Joins Return the Same Answer Set?
    33. The CROSS JOIN
    34. The CROSS JOIN Answer Set
    35. The Self Join
    36. The Self Join with ANSI Syntax
    37. Quiz – Will both queries bring back the same Answer Set?
    38. Answer – Will both queries bring back the same Answer Set?
    39. Quiz – Will both queries bring back the same Answer Set?
    40. Answer – Will both queries bring back the same Answer Set?
    41. How would you Join these two tables?
    42. How would you Join these two tables? You Can't....Yet!
    43. An Associative Table is a Bridge that Joins Two Table
    44. Quiz – Can you Write the 3-Table Join?
    45. Answer to Quiz – Can you Write the 3-Table Join?
    46. Quiz – Can you Write the 3-Table Join to ANSI Syntax?
    47. Answer – Can you Write the 3-Table Join to ANSI Syntax?
    48. Quiz – Can you Place the ON Clauses at the End?
    49. Answer – Can you Place the ON Clauses at the End?
    50. The 5-Table Join – Logical Insurance Model
    51. Quiz - Write a Five Table Join Using ANSI Syntax
    52. Answer - Write a Five Table Join Using ANSI Syntax
    53. Quiz – Write a Five Table Join Using Non-ANSI Syntax
    54. Answer - Write a Five Table Join Using Non-ANSI Syntax
    55. Quiz –Re-Write this putting the ON clauses at the END
    56. Answer –Re-Write this putting the ON clauses at the END
    57. The Nexus Query Chameleon Writes the SQL for Users.
  15. Chapter 7 – Date Functions
    1. Date, Time, and Timestamp Keywords
    2. Add or Subtract Days from a date
    3. The to_char command
    4. Conversion Functions
    5. Conversion Function Templates
    6. Conversion Function Templates Continued
    7. Formatting A Date
    8. A Summary of Math Operations on Dates
    9. Using a Math Operation to find your Age in Years
    10. Find What Day of the week you were Born
    11. The ADD_MONTHS Command
    12. Using the ADD_MONTHS Command to Add 1-Year
    13. Using the ADD_MONTHS Command to Add 5-Years
    14. Date Related Functions
    15. The EXTRACT Command
    16. EXTRACT from DATES and TIME
    17. EXTRACT with DATE and TIME Literals
    18. EXTRACT of the Month on Aggregate Queries
    19. A Side Title example with Reserved Words as an Alias
    20. Implied Extract of Day, Month, and Year
    21. DATE_PART Function
    22. DATE_PART Function using an ALIAS
    23. DATE_TRUNC Function
    24. DATE_TRUNC Function using TIME
    25. MONTHS_BETWEEN Function
    26. MONTHS_BETWEEN Function in Action
    27. ANSI TIME
    28. ANSI TIMESTAMP
    29. Netezza TIMESTAMP Function
    30. Netezza TO_TIMESTAMP Function
    31. Netezza NOW() Function
    32. Netezza TIMEOFDAY Function
    33. Netezza AGE Function
    34. Time Zones
    35. Setting Time Zones
    36. Using Time Zones
    37. Intervals for Date, Time, and Timestamp
    38. Using Intervals
    39. Troubleshooting The Basics of a Simple Interval
    40. Interval Arithmetic Results
    41. A Date Interval Example
    42. A Time Interval Example
    43. A - DATE Interval Example
    44. A Complex Time Interval Example using CAST
    45. A Complex Time Interval Example using CAST
    46. The OVERLAPS Command
    47. An OVERLAPS Example that Returns No Rows
    48. The OVERLAPS Command using TIME
    49. The OVERLAPS Command using a NULL Value
  16. Chapter 8 – OLAP Functions
    1. A Better Choice – The ANSI Version of CSUM
    2. The ANSI Version of CSUM – The Sort Explained
    3. The ANSI CSUM – Rows Unbounded Preceding Explained
    4. The ANSI CSUM – Making Sense of the Data
    5. The ANSI CSUM – Making Even More Sense of the Data
    6. The ANSI CSUM – The Major and Minor Sort Key(s)
    7. The ANSI CSUM – Getting a Sequential Number
    8. Troubleshooting The ANSI OLAP on a GROUP BY
    9. The ANSI OLAP – Reset with a PARTITION BY Statement
    10. PARTITION BY only Resets a Single OLAP not ALL of them
    11. ANSI Moving Window is Current Row and Preceding n Rows
    12. How ANSI Moving SUM Handles the Sort
    13. Quiz – How is that Total Calculated?
    14. Answer to Quiz – How is that Total Calculated?
    15. Moving SUM every 3-rows Vs a Continuous Average
    16. Partition By Resets an ANSI OLAP
    17. The ANSI Moving Window is Current Row and Preceding
    18. How ANSI Moving Average Handles the Sort
    19. Quiz – How is that Total Calculated?
    20. Answer to Quiz – How is that Total Calculated?
    21. Quiz – How is that 4th Row Calculated?
    22. Answer to Quiz – How is that 4th Row Calculated?
    23. Moving Average every 3-rows Vs a Continuous Average
    24. Partition By Resets an ANSI OLAP
    25. Moving Difference using ANSI Syntax
    26. Moving Difference using ANSI Syntax with Partition By
    27. RANK using ANSI Syntax Defaults to Ascending Order
    28. Getting RANK using ANSI Syntax to Sort in DESC Order
    29. RANK() OVER and PARTITION BY
    30. RANK() OVER And LIMIT
    31. PERCENT_RANK() OVER
    32. PERCENT_RANK() OVER with 14 rows in Calculation
    33. PERCENT_RANK() OVER with 21 rows in Calculation
    34. Quiz – What Causes the Product_ID to Reset?
    35. Answer to Quiz – What Cause the Product_ID to Reset?
    36. COUNT OVER for a Sequential Number
    37. Troubleshooting COUNT OVER
    38. Quiz – What caused the COUNT OVER to Reset?
    39. Answer to Quiz – What caused the COUNT OVER to Reset?
    40. The MAX OVER Command
    41. MAX OVER with PARTITION BY Reset
    42. Troubleshooting MAX OVER
    43. The MIN OVER Command
    44. Troubleshooting MIN OVER
    45. Quiz – Fill in the Blank
    46. Answer to Quiz – Fill in the Blank
    47. The Row_Number Command
    48. Quiz – How did the Row_Number Reset?
    49. Quiz – How did the Row_Number Reset?
    50. Standard Deviation Functions Using STDDEV / OVER
    51. Standard Deviation Functions and STDDEV / OVER Syntax
    52. STDDEV / OVER Example
    53. Variance Functions Using VARIANCE / OVER
    54. VARIANCE / OVER Syntax
    55. Using VARIANCE with PARTITION BY Example
    56. Using FIRST_VALUE and LAST_VALUE
    57. Using FIRST_VALUE
    58. Using LAST_VALUE
    59. Using LAG and LEAD
    60. Using LEAD
    61. Using LEAD With and Offset of 2
    62. Using LAG
    63. Using LAG With an Offset of 2
  17. Chapter 9 – Temporary Tables
    1. There are Three Types of Temporary Tables
    2. CREATING A Derived Table
    3. Naming the Derived Table
    4. Aliasing the Column Names in The Derived Table
    5. Multiple Ways to Alias the Columns in a Derived Table
    6. CREATING A Derived Table using the WITH Command
    7. Naming the Derived Table Columns using WITH
    8. The Same Derived Query shown Three Different Ways
    9. Most Derived Tables Are Used To Join To Other Tables
    10. Our Join Example With A Different Column Aliasing Style
    11. Column Aliasing Can Default For Normal Columns
    12. Our Join Example With The WITH Syntax
    13. Quiz - Answer the Questions
    14. Answer to Quiz - Answer the Questions
    15. Clever Tricks on Aliasing Columns in a Derived Table
    16. An Example of Two Derived Tables in a Single Query
    17. Syntax For Creating A Temporary Table
    18. Creating and Populating a Temporary Table
    19. A Temporary Table in Action
    20. A Temporary Table Can Be Used Again and Again
    21. Alternative CREATE TEMPORARY TABLE Option
    22. A CTAS Temp Table to Improve Zone Map Selectivity
    23. Creating a Temp Table as a Cluster Based Table (CBT)
    24. What Are External Tables?
    25. External Tables Data Loading Formats
    26. External Table Log Files
    27. External Table Syntax
    28. Exporting Data Off of Netezza into an External Table
    29. Importing Data Into Netezza Using an External Table
    30. What is the Problem Here?
  18. Chapter 10 – Sub-query Functions
    1. An IN List is much like a Subquery
    2. An IN List Never has Duplicates – Just like a Subquery
    3. An IN List Ignores Duplicates
    4. The Subquery
    5. How a Basic Subquery Works
    6. The Final Answer Set from the Subquery
    7. Quiz- Answer the Difficult Question
    8. Answer to Quiz- Answer the Difficult Question
    9. Should you use a Subquery of a Join?
    10. Quiz- Write the Subquery
    11. Answer to Quiz- Write the Subquery
    12. Quiz- Write the More Difficult Subquery
    13. Answer to Quiz- Write the More Difficult Subquery
    14. Quiz- Write the Subquery with an Aggregate
    15. Answer to Quiz- Write the Subquery with an Aggregate
    16. Quiz- Write the Correlated Subquery
    17. Answer to Quiz- Write the Correlated Subquery
    18. The Basics of a Correlated Subquery
    19. The Top Query always runs first in a Correlated Subquery
    20. The Bottom Query runs Last in a Correlated Subquery
    21. Quiz- Who is coming back in the Final Answer Set?
    22. Answer- Who is coming back in the Final Answer Set?
    23. Correlated Subquery Example vs. a Join with a Derived Table
    24. Quiz- A Second Chance To Write a Correlated Subquery
    25. Answer - A Second Chance to Write a Correlated Subquery
    26. Quiz- A Third Chance To Write a Correlated Subquery
    27. Answer - A Third Chance to Write a Correlated Subquery
    28. Quiz- Last Chance To Write a Correlated Subquery
    29. Answer – Last Chance to Write a Correlated Subquery
    30. Correlated Subquery that Finds Duplicates
    31. Quiz- Write the NOT Subquery
    32. Answer to Quiz- Write the NOT Subquery
    33. Quiz- Write the Subquery using a WHERE Clause
    34. Answer - Write the Subquery using a WHERE Clause
    35. Quiz- Write the Subquery with Two Parameters
    36. Answer to Quiz- Write the Subquery with Two Parameters
    37. How the Double Parameter Subquery Works
    38. More on how the Double Parameter Subquery Works
    39. Quiz – Write the Triple Subquery
    40. Answer to Quiz – Write the Triple Subquery
    41. Quiz – How many rows return on a NOT IN with a NULL?
    42. Answer – How many rows return on a NOT IN with a NULL?
    43. How to handle a NOT IN with Potential NULL Values
    44. IN is equivalent to =ANY
    45. Using a Correlated Exists
    46. How a Correlated Exists matches up
    47. The Correlated NOT Exists
    48. The Correlated NOT Exists Answer Set
    49. Quiz – How many rows come back from this NOT Exists?
    50. Answer – How many rows come back from this NOT Exists?
  19. Chapter 11 - Substrings and Positioning Functions
    1. The LOWER Function
    2. The UPPER Function
    3. CHARACTER_LENGTH
    4. OCTET_LENGTH
    5. TRIM for Troubleshooting the CHARACTERS Command
    6. The TRIM Command trims both Leading and Trailing Spaces
    7. Trim and Trailing is Case Sensitive
    8. Trim and Trailing works if Case right
    9. Trim Combined with the CHARACTERS Command
    10. How to TRIM only the Trailing Spaces
    11. How to TRIM Trailing Letters
    12. How to TRIM Trailing Letters and use CHARACTER_Length
    13. LTRIM Function
    14. RTRIM Function
    15. BTRIM Function
    16. The SUBSTRING Command
    17. How SUBSTRING Works with NO ENDING POSITION
    18. Using SUBSTRING to move Backwards
    19. How SUBSTRING Works with a Starting Position of -1
    20. How SUBSTRING Works with an Ending Position of 0
    21. An Example using SUBSTRING, TRIM, and CHAR Together
    22. SUBSTRING and SUBSTR are equal, but use different syntax
    23. The POSITION Command finds a Letters Position
    24. STRPOS Function
    25. The POSITION And STRPOS Do The Same Thing
    26. SUBSTRING and POSITION Used Together In An UPDATE
    27. The POSITION Command is brilliant with SUBSTRING
    28. Quiz – Name that SUBSTRING Starting and For Length
    29. Answer to Quiz – Name that Starting and For Length
    30. Using the SUBSTRING to Find the Second Word On
    31. Quiz – Why Did only one Row Return
    32. Answer to Quiz – Why Did only one Row Return
    33. Concatenation
    34. Concatenation and SUBSTRING
    35. Four Concatenations Together
    36. Troubleshooting Concatenation
    37. Miscellaneous Character Functions - ASCII
    38. Miscellaneous Character Functions - CHR
    39. Miscellaneous Character Functions - INITCAP
    40. Miscellaneous Character Functions - REPEAT
    41. Miscellaneous Character Functions - TRANSLATE
    42. Character Padding Functions - LPAD Function
    43. Character Padding Functions - RPAD Function
  20. Chapter 12 – Interrogating the Data
    1. NVL Syntax
    2. NVL Example
    3. NVL Is Often Used With Calculations
    4. Comparisons of NVL
    5. A Real-World NVL Example
    6. NVL2 Syntax
    7. NVL2 Example
    8. NVL2 Syntax
    9. A Real-World NVL2 Example
    10. DECODE Syntax
    11. DECODE Example
    12. A Real-World DECODE Example
    13. Quiz – Fill in the Answers for the NULLIF Command
    14. Quiz – Fill in the Answers for the NULLIF Command
    15. The COALESCE Command
    16. The COALESCE Answer Set
    17. The Coalesce Quiz
    18. Answer – The Coalesce Quiz
    19. The Basics of CAST (Convert And STore)
    20. Some Great CAST (Convert And Store) Examples
    21. Some Great CAST (Convert And Store) Examples
    22. Some Great CAST (Convert And Store) Examples
    23. Round Function
    24. Round Function Continued
    25. The Basics of the CASE Statements
    26. The Basics of the CASE Statement shown Visually
    27. Valued Case Vs. A Searched Case
    28. Quiz - Valued Case Statement
    29. Answer - Valued Case Statement
    30. Quiz - Searched Case Statement
    31. Answer - Searched Case Statement
    32. Quiz - When NO ELSE is present in CASE Statement
    33. Answer - When NO ELSE is present in CASE Statement
    34. When an ELSE is present in CASE Statement
    35. When NO ELSE is present in CASE Statement
    36. When an Alias is NOT used in a CASE Statement
    37. When an Alias is NOT used in a CASE Statement
    38. Combining Searched Case and Valued Case
    39. A Trick for getting a Horizontal Case
    40. Nested Case
    41. Put a CASE in the ORDER BY
  21. Chapter 13 – View Functions
    1. Creating a Simple View
    2. Basic Rules for Views
    3. Views sometimes CREATED for Formatting or Row Security
    4. Another Way to Alias Columns in a View CREATE
    5. Resolving Aliasing Problems in a View CREATE
    6. Resolving Aliasing Problems in a View CREATE
    7. Resolving Aliasing Problems in a View CREATE
    8. CREATING Views for Complex SQL such as Joins
    9. WHY certain columns need Aliasing in a View
    10. Using a WHERE Clause When Selecting From a View
    11. Altering A Table
    12. Altering A Table After a View has been Created
    13. A View that Errors After An ALTER
    14. Troubleshooting a View
  22. Chapter 14 – Set Operators Functions
    1. Rules of Set Operators
    2. INTERSECT Explained Logically
    3. INTERSECT Explained Logically
    4. UNION Explained Logically
    5. UNION Explained Logically
    6. UNION ALL Explained Logically
    7. UNION Explained Logically
    8. EXCEPT Explained Logically
    9. EXCEPT Explained Logically
    10. Minus Explained Logically
    11. Minus Explained Logically
    12. Testing Your Knowledge
    13. Testing Your Knowledge
    14. An Equal Amount of Columns in both SELECT List
    15. Columns in the SELECT list should be from the same Domain
    16. The Top Query handles all Aliases
    17. The Bottom Query does the ORDER BY (a Number)
    18. Great Trick: Place your Set Operator in a Derived Table
    19. UNION Vs UNION ALL
    20. Using UNION ALL and Literals
    21. A Great Example of how EXCEPT works
    22. USING Multiple SET Operators in a Single Request
    23. Changing the Order of Precedence with Parentheses
    24. Using UNION to be same as GROUP BY GROUPING SETS
    25. Using UNION to be same as GROUP BY ROLLUP
    26. Using UNION to be the same as GROUP BY Cube
    27. Using UNION to be same as GROUP BY Cube
  23. Chapter 15 – Data Manipulations
    1. Netezza Transactions
    2. BEGIN Command
    3. COMMIT Command
    4. What Happens on a Transaction Error?
    5. Can I See My Uncommitted Changes?
    6. Until the Commit Others Can't See Your Changes?
    7. ROLLBACK Command
    8. ROLLBACK Command in ACTION
    9. INSERT Command
    10. INSERT With Keyword Null
    11. A Different Syntax for the INSERT Statements
    12. These Three Statements are the Same
    13. A Third Way of Doing an INSERT
    14. Netezza Has Implemented the Default Values Clause
    15. INSERT/SELECT
    16. INSERT/SELECT Examples
    17. Another Syntax for the INSERT/SELECT
    18. INSERT/SELECT Used To CREATE A Data Mart
    19. UPDATE
    20. An UPDATE In Action
    21. An UPDATE With Multiple WHERE and AND Clauses
    22. An UPDATE With Multiple WHERE and AND Clauses
    23. UPDATE Using A Subquery
    24. UPDATE Using A Subquery
    25. UPDATE Using A Subquery
    26. UPDATE Using A Join
    27. DELETE
    28. Two DELETE Examples
    29. DELETE Through a Subquery or Join
    30. DELETE Through a Subquery And A Join Examples
    31. Multi-Statement Example
    32. How to Undo A Delete
    33. A Delete Example Query
    34. How to Undo a Delete
    35. How to Undo a Delete In Action
  24. Chapter 16 – Tables, DDL, and Data Types
    1. CREATE TABLE Syntax
    2. Viewing the DDL
    3. Netezza Tables - Distribution Key or Random Distribution
    4. Table CREATE Examples with 4 different Distribution Keys
    5. The Worst Mistake You Can Make For A Distribution Key
    6. Good things to know about Table and Object Names
    7. Netezza Data Types
    8. Netezza Data Types in More Detail
    9. Netezza Data Type Extensions
    10. Reserved Names Within A Table
    11. How To Query and See Non-Active Rows
    12. Column Attributes
    13. Constraints
    14. Constraints
    15. Column Level Constraint Example
    16. Defining Constraints at the Table Level
    17. Utilizing Default Values for a Table
    18. CTAS (Create Table AS)
    19. CTAS Facts
    20. Using the CTAS (Create Table AS) Table For Co-Location
    21. Altering a CTAS Table to Rename It
    22. FPGA Card and Zone Maps – The Netezza Secret Weapon
    23. How A CTAS with ORDER BY Improves Queries
    24. A CTAS Major Sort Benefits over the Minor Sort
    25. Altering A Table
    26. Altering a Table Examples
    27. Drop Table, Truncate, and Delete Compared
    28. Creating and Dropping a Netezza Database
    29. How to Determine the Database you are in?
    30. Netezza Users
    31. Altering a Netezza User
    32. Reserved Words to find out about a User
  25. Chapter 17 – Statistical Aggregate Functions
    1. The Stats Table
    2. The STDDEV_POP Function
    3. A STDDEV_POP Example
    4. The STDDEV_SAMP Function
    5. A STDDEV_SAMP Example
    6. The VAR_POP Function
    7. A VAR_POP Example
    8. The VAR_SAMP Function
    9. A VAR_SAMP Example
    10. Using GROUP BY
    11. A Great Query Example
  26. Chapter 18 – Stored Procedure Functions
    1. Netezza Stored Procedures
    2. Creating and Executing a Stored Procedure
    3. Creating a Stored Procedure
    4. Netezza Provides Multiple Ways to Run the Stored Procedure
    5. You Can Have Multiple BEGIN and END statements
    6. How to Declare and Set a Variable
    7. Declaring a Variable With A Value
    8. Input Parameters
    9. Input Parameters Using Character Data
    10. Calling a Procedure With Multiple Input Parameters
    11. CREATE OR REPLACE Procedure
    12. IF THEN ELSE IF Techniques
    13. An Easier Way for IF THEN ELSE is ELSIF or ELSEIF
    14. Using Loops in Stored Procedures
    15. Using Loops with Different EXIT strategies
    16. Looping With The WHILE Statement
    17. Stored Procedure Workshop
    18. Stored Procedure Workshop
    19. Using FOR to Loop
  27. Chapter 19 – Nexus Query Chameleon
    1. The Old Nexus Logo
    2. The New Nexus Logo
    3. Watch the Video on the new Nexus Super Join Builder
    4. How to Customize your System Tree View
    5. Introducing the new Nexus Super Join Builder
    6. Define your Joins and tell Nexus to "Add and Remember Me"
    7. Nexus knows what Tables Join together
    8. Nexus Presents Tables and their columns in Color
    9. Nexus Builds your SQL Automagically
    10. Nexus can Cube a Table and Join to Everything Possible
    11. Nexus can Cube a Table and Join to Everything Possible
    12. The Cube SQL created Automagically
    13. Manipulate the Columns with the Columns Tab
    14. Single Click and ORDER BY using the Sort Tab
    15. Using the Joins Tab of Nexus
    16. The SQL Tab reflects the changes we make in all other Tabs
    17. WHERE Tab shows Tables Indexes
    18. The Answer Set Tab shows the Results
    19. The Answer Set Tab shows the Results
    20. The Answer Set Tab shows the Results
    21. The Answer Set Tab shows the Results
    22. The Metadata Tab shows Metadata
    23. Nexus Makes a View look like a Table
    24. Nexus Joins Views to other Views in seconds
    25. Nexus can Cube a View and Join to all other related Views
    26. Nexus Cubes Views in Seconds
    27. The Cube SQL created on Views is done Automagically
    28. Views with the Underlying Indexes of the Base Tables
    29. WHERE Tab shows Views Underlying Base Table Indexes
    30. After an Answer Set Returns, you can do many things
    31. After an Answer Set Returns, Perform OLAP Calculations
    32. After an Answer Set Returns, you can Graph and Chart
    33. Custom Joins With Nexus
    34. Users Who Want to Load the Model
    35. Users Who Want to Load the Model (Continued)
    36. How Custom Joins Will Look in the Super Join Builder
    37. Loading an ERwin Mode
    38. Loading an ERwin Model (Continued)
    39. Attaching The ERwin Model
    40. Attaching The ERwin Model (Continued)
    41. Managing The ERwin Model (Continued)
    42. Saving an Answer Set in another Format
    43. Sandbox – How to Create a Sandbox (1 of 5)
    44. Sandbox - Join Answer Sets from different Systems (2 of 5)
    45. Sandbox - Join Answer Sets from different Systems (3 of 5)
    46. Sandbox - Join Answer Sets from different Systems (4 of 5)
    47. Sandbox - Join Answer Sets from different Systems (5 of 5)
    48. Convert Netezza DDL to Another Database Vendor
    49. Replicate Data from One Netezza System to Another
    50. Tera-Tom in Malaysia
3.133.144.59