Select chapter



Basics (2.papers)
Data Types (2.papers)
Table-designing (1.papers)
Queries-Commands (3.papers)
String functions (2.papers)
Subqueries (1.papers)
Joins (1.papers)
Constraints (1.papers)
Triggers (1.papers)
Hide

Sponsored Links


  

sql interview questions and answers

1
What is the syntax for if, else if and else in T-SQL?
  1. If (expression)
    {
       --some sql code goes here
    }
    else if(expression)
    {
      --some sql code goes here
    }
    else
    {
      --some sql code goes here
    }
  2. If (expression)
    begin if
       --some sql code goes here
    end if
    else if(expression)
    begin
      --some sql code goes here
    end
    else
    begin
      --some sql code goes here
    end
  3. if(expression)
    begin
    --some sql code
    end
    else if(expression)
    begin
     --some sql code
    end
    else
    begin
    --some sql code
    end
  4. Sql will not support conditional statements
Show Answer
Share Facebook gmail Twitter
2
Identify the correct syntax for while loop in T-SQL?
  1. while(expression)
    {
      --some t-sql code here
    }
  2. while(expression)
    begin while
      --some t-sql commands
    end while
  3. while(expression)
    begin
      --some t-sql commands goes here.
    end
  4. None of the above
Show Answer
Share Facebook gmail Twitter
Read more papers :