Book Image

Teradata Cookbook

By : Abhinav Khandelwal, Viswanath Kasi, Rajsekhar Bhamidipati
Book Image

Teradata Cookbook

By: Abhinav Khandelwal, Viswanath Kasi, Rajsekhar Bhamidipati

Overview of this book

Teradata is an enterprise software company that develops and sells its eponymous relational database management system (RDBMS), which is considered to be a leading data warehousing solutions and provides data management solutions for analytics. This book will help you get all the practical information you need for the creation and implementation of your data warehousing solution using Teradata. The book begins with recipes on quickly setting up a development environment so you can work with different types of data structuring and manipulation function. You will tackle all problems related to efficient querying, stored procedure searching, and navigation techniques. Additionally, you’ll master various administrative tasks such as user and security management, workload management, high availability, performance tuning, and monitoring. This book is designed to take you through the best practices of performing the real daily tasks of a Teradata DBA, and will help you tackle any problem you might encounter in the process.
Table of Contents (19 chapters)
Title Page
Dedication
Packt Upsell
Contributors
Preface
Index

Building a query builder


Query builder is your quick reference guide to SQL syntax. It not only lets you use its own SQLs, but also provides you with the option to add your own along with editing the existing ones.

How to do it...

Query builder is available both in SQLA and Teradata Studio Express. Express query builder is more interactive and has drag-and-drop features. Let's first cover SQLA, followed by Studio Express.

Query builder in SQLA

Here is how you can proceed with query builder in SQLA:

  1. Query builder in SQLA is under the Help tab, or you can press F2. Here, you can click on any existing command or browse for the one you need. 
  2. You can also add frequently used queries in query builder. Click on + as shown in the following screenshot and add the queries that you need most, so that you don't have to search for them: 

Query builder in Express

Here is how to proceed with query builder in Express:

  1. In express, you can edit an existing query using the query builder. Selecting the query in the SQL Editor, right-click and select the Edit in Query Builder option:

    .

  2. Once you click on the Edit option, your query will be opened in a new window with many other options. Here, you can add new tables to the existing query, creating a relationship between them. There is also a tab that gives you options to put conditions (where, or, and) in queries. You can also add the group by clause; refer to the screenshot for details:

There is an option to change the statement type when you click on the statement box.