1. Question: Where should sub queries be used?

    A
    To define the set of rows to be inserted in a table

    B
    To define the set of rows to be included in a view

    C
    To define one or more values to be assigned to existing rows

    D
    To provide values for conditions in the Where clause

    E
    To define a table to be operated on by a containing query

    F
    All of the above are correct

    G
    None of the above is correct

    Note: Not available
    1. Report
  2. Question: In which sequence are queries and sub-queries executed by the SQL Engine?

    A
    primary query -> sub query -> sub sub query and so on

    B
    sub sub query -> sub query -> prime query

    C
    the whole query is interpreted at one time

    D
    there is no fixed sequence of interpretation, the query parser takes a decision on the fly

    Note: Not available
    1. Report
  3. Question: Are both the statements correct? (a)where deptno in(2,4,5) (b)where deptno=2 or deptno=4 or deptno=5

    A
    True

    B
    False

    Note: Not available
    1. Report
  4. Question: What is the correct order of clauses in the select statement? 1 select 2 order by 3 where 4 having 5 group by

    A
    1,2,3,4,5

    B
    1,3,5,4,2

    C
    1,3,5,2,4

    D
    1,3,2,5,4

    E
    1,3,2,4,5

    F
    1,5,2,3,4

    G
    1,4,2,3,5

    H
    1,4,3,2,5

    Note: Not available
    1. Report
  5. Question: There are two tables A and B. You are retreiving data from both tables where all rows from B table and only matching rows from A table should be displayed. Which type of join you will apply between A and B tables?

    A
    Inner join

    B
    Left outer join

    C
    Right outer join

    D
    Self join

    Note: Not available
    1. Report
  6. Question: Point out the incorrect statement regarding group functions:

    A
    Group functions act on a group of rows

    B
    Group functions return one result for all the rows operated upon

    C
    Group functions ignore the null values

    D
    Stdev and variance are examples of group functions

    E
    One cannot combine group and single value functions in a query

    F
    Sum is not a group function

    Note: Not available
    1. Report
  7. Question: How many foreign key constraints can a table have?

    A
    1

    B
    2

    C
    3

    D
    4

    E
    5

    F
    6

    G
    None of these above

    Note: Not available
    1. Report
  8. Question: Which statement is correct for FIRST NORMAL FORM?

    A
    Includes only tables that do not have composite primary keys

    B
    Must have data stored in a two-dimensional table with no repeating groups

    C
    Every non-key column is nontransitively dependent upon its primary key

    D
    None of these above

    Note: Not available
    1. Report
  9. Question: What is wrong with the following query: select * from Orders where OrderID = (select OrderID from OrderItems where ItemQty > 50)

    A
    In the sub query, '*' should be used instead of 'OrderID'

    B
    The sub query can return more than one row, so, '=' should be replaced with 'in'

    C
    The sub query should not be in parenthesis

    D
    None of these above

    Note: Not available
    1. Report
  10. Question: A company has the following departments: Marketing , Designing , Production , Packing What will be the result of the following query? select * from table where department < 'Marketing';

    A
    The query will return " Designing , Packing "

    B
    The query will return " Designing , production ,Packing "

    C
    The query will return "Packing"

    D
    Strings cannot be compared using < operator

    E
    The query will return " Designing "

    Note: Not available
    1. Report
Copyright © 2024. Powered by Intellect Software Ltd