Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Teradata Cookbook

You're reading from   Teradata Cookbook Over 85 recipes to implement efficient data warehousing solutions

Arrow left icon
Product type Paperback
Published in Feb 2018
Publisher Packt
ISBN-13 9781787280786
Length 454 pages
Edition 1st Edition
Languages
Arrow right icon
Authors (3):
Arrow left icon
Abhinav Khandelwal Abhinav Khandelwal
Author Profile Icon Abhinav Khandelwal
Abhinav Khandelwal
Viswanath Kasi Viswanath Kasi
Author Profile Icon Viswanath Kasi
Viswanath Kasi
Rajsekhar Bhamidipati Rajsekhar Bhamidipati
Author Profile Icon Rajsekhar Bhamidipati
Rajsekhar Bhamidipati
Arrow right icon
View More author details
Toc

Table of Contents (14) Chapters Close

Preface 1. Installation 2. SQLs FREE CHAPTER 3. Advanced SQL with Backup and Restore 4. All about Indexes 5. Mixing Strategies – Joining of Tables 6. Building Loading Utility – Replication and Loading 7. Monitoring the better way 8. Collect Statistics the Better Way 9. Application and OPS DBA Insight 10. DBA Insight 11. Performance Tuning 12. Troubleshooting 13. Other Books You May Enjoy

Setting up Teradata SQLA

We will now turn our focus to the traditional but easy to use tool, SQL Assistant (SQLA). We now have a SQLA Java version just like Teradata Studio or Teradata Studio Express.

Getting ready

For SQLA to work, you need to download it from the developer.teradata.com website and download Teradata Tools and Utilities, also known as TTUOnce downloaded and installed, start making the connection using ODBC, .NET, or JDBC.

SQLA can informally be referred to as a lightweight version of Studio or Express; you will find it easier to navigate and use.

 Here, we will use SQLA 16.0. It is highly recommended that you use the TTU version that matches or is higher than the major release version number of the Teradata Database that you intend to connect with. So, if you are on Teradata Database 15.10, use TTU 15.10 or 16. TTU 13.10 is not recommended. Now that we have this covered, let's move on to the connection.

How to do it...

Use the following steps to establish a connection:

  1. Click on the plug icon in the top-left corner; now you can either select file data source or machine data source.
  2. Click on New... if you don't have a connection file. Select user or system data source:
  1. Then select the option of Teradata Database ODBC driver 16.00; after this, you will see the screen for providing the name of your data connection and source IP.
  2. Enter your credentials; you have the option to save the password if you don't want to enter it every time you connect to the database: 

Wouldn't it be great to have an option to run SQL using the command-line interface with SQLA?

How it works...

Teradata SQLA allows you to connect to a data source using the ODBC and .NET framework. When you install SQLA from TTU toolkit, make sure to check all the options. You will have two executables:

  • TTU_BASE has the following:
    • ODBC driver
    • BTEQ
    • All the loading tools, such as fastexport, fastload, and many others
    • Named pipe modules
    • Websphere access modules
    • .NET data provider
    • C preprocessor 2
    • Tearadata adminstrator
    • SQLA
    • Teradata Wallet and many more
  • TTU_DBM has the following:
    • Index wizard
    • BTEQ
    • ODBC driver
    • Query scheduler admin, client, server
    • TSET
    • Workload analyzer
    • Visual explain
    • Teradata Wallet

There's more...

Here are some shortcuts to make your daily job easier:

  • F2: It will open query builder, with syntax for all SQL queries
  • F5: Execute SQL query
  • F6: Explain plan for SQL query
  • F9: Execute SQL queries in parallel
  • F10: Abort SQL query
  • F11: Display last error encountered
  • Ctrl + N: New SQL query window
  • Ctrl + Q: Format SQL query
  • Ctrl + U: Convert to UPPERCASE
  • Ctrl + H: Find and replace
lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image