Teradata and SQL Database Quiz

Covers Teradata architecture, SQL functions, and Oracle database concepts

20 Questions Published

Questions

Question 1 Multiple Choice (Single Answer)

What is the Max size of NVARCHAR2 in PL/SQL?

  1. 4000
  2. 8000
  3. 32768
  4. 32767
Question 2 Multiple Choice (Single Answer)

What is the correct order to get a correct SQL statement?

  1. SELECT FROM GROUP BY WHERE
  2. SELECT FROM GROUP BY ROLLUP
  3. SELECT GROUP BY FROM
  4. SELECT WHERE FROM GROUP BY
Question 3 True/False

NULL values violate CHECK constraint

  1. True
  2. False
Question 4 Multiple Choice (Single Answer)

Which of these operators is used to calculate super aggregate results?

  1. ROLLUP
  2. COUNT
  3. AVG
  4. SUM
Question 5 Multiple Choice (Single Answer)

Which is the syntax for enforcing the rule of deleting the dependent Foreign Key values on the deletion of a Primary Key?

  1. ON DELETE SET NULL
  2. ON DELETE CASCADE
  3. ON DELETE DELETE
  4. ON DELETE RESTRICT
Question 6 True/False

UNION ALL has a comparitively faster performance compared to UNION?

  1. True
  2. False
Question 7 Multiple Choice (Single Answer)

Which of these is a String Aggregation function used to get values from different rows into a single column?

  1. SUBSTR
  2. CON_STR
  3. CON_CAT
  4. WM_CONCAT
Question 8 Multiple Choice (Single Answer)

TRANSLATE

  1. Restricts the length of the String
  2. Replaces a sequence of characters in a string with another set of characters
  3. Modifies the datatype of a column
  4. Renames a column
Question 9 Multiple Choice (Single Answer)

which of these can be used to filter aggregate functions?

  1. WHEN
  2. HAVING
  3. WHERE
  4. ANY
Question 10 Multiple Choice (Single Answer)

REPLACE

  1. Replaces word by word
  2. Replaces a column with another column
  3. Replaces character by character
  4. Replaces a row with another row
Question 11 Multiple Choice (Single Answer)

How is IN different form EXISTS ?

  1. IN executes the inner query for each row affected by the outer query and EXISTS executes the inner query only once irrespective of the outer query
  2. IN executes the inner query only once irrespective of the outer query and EXISTS executes the inner query only once irrespective of the outer query
  3. IN executes the inner query only once irrespective of the outer query and EXISTS executes the outer query for each row affected by the outer query
  4. IN executes the inner query for each row affected by the outer query and EXISTS executes the outer query for each row affected by the outer query
Question 12 Multiple Choice (Single Answer)

Teradata components handle data distribution by

  1. AMP bucket number
  2. Primary Index
  3. Primary Key
  4. None of the above
Question 13 Multiple Choice (Single Answer)

_____ and _____ are true about the Primary Index

  1. Defined immediately after the table CREATE statement, used to find the Primary Key
  2. Defined during the table CREATE statement, used to assign rows to an AMP
  3. Defined immediately after the table CREATE statement, used to assign rows to an AMP
  4. Defined during the table CREATE statement, used to find the Primary Key
Question 14 Multiple Choice (Single Answer)

_____ and _____ are true about the Primary Index

  1. Defined immediately after the table CREATE statement, used to assign rows to an AMP
  2. Defined immediately after the table CREATE statement, used to find the Primary Key
  3. Defined during the table CREATE statement, used to assign rows to an AMP
  4. Defined during the table CREATE statement, used to find the Primary Key
Question 15 Multiple Choice (Single Answer)

A new table has been created in the employee. There are no rows in the table.What would be the output of the following query?select count(*) from employee

  1. Error
  2. 1
  3. No data Found
  4. 0
Question 16 Multiple Choice (Single Answer)

Which of the query will print the output as 'TCS' (single quotes should come in the output of the query)

  1. select '''||'TCS'||''' from dual
  2. select 'TCS' from dual
  3. select '''TCS''' from dual
  4. select "TCS" from dual
Question 17 Multiple Choice (Single Answer)

What's the output select to_Date('2009-may-25','yyyymmdd') from dual

  1. 2009-may-25
  2. Error
  3. may-2009-25
  4. 200925may
Question 18 Multiple Choice (Single Answer)

Which of the query will print the output as 'TCS' (single quotes should come in the output)

  1. select '''||'TCS ||''' from dual
  2. select '''TCS''' from dual
  3. select "TCS" from dual
  4. select 'TCS' from dual
Question 19 Multiple Choice (Single Answer)

Session Handling is done by which part of teradata system?

  1. AMP
  2. PE
  3. BYNET
  4. CLIQUE
Question 20 Multiple Choice (Single Answer)

TERADATA is Shared _________ architecture.

  1. Nothing
  2. Everything
  3. Disk
  4. Processor