Tag: databases

Questions Related to databases

delete will lower the water mark

  1. True

  2. False


Correct Option: B
  1. having

  2. group by

  3. where

  4. both 1 and 2


Correct Option: D

If base table does not exists, can we create a view?

  1. True

  2. False


Correct Option: A
  1. Gives the columns referred in select statement of view

  2. Reports a error

  3. Select only particular columns of view table

  4. Outputs the whole view table


Correct Option: B

Which of the following data types are used in SQL?

  1. Long

  2. Date

  3. rowid

  4. all above


Correct Option: D

Which of the following SQL statement create a sequence SE with starting value as 30 and in increments of 20?

  1. GENERATE SEQUENCE SE START WITH 30 ADD BY 20;

  2. CREATE SEQUENCE SE START WITH 30 ADD BY 20;

  3. CREATE SEQUENCE SE START WITH 30 INCREMENT BY 20;

  4. GENERATE SEQUENCE SE INITIATE WITH 30 INCREMENT BY 20;


Correct Option: C

Which of the following is TRUE about Primary Key?

  1. Same value of Primary Key can appear in more than one row in the table

  2. A Primary key defined column can be of type LONG

  3. A column that is defined as Primary Key cannot contain NULL value

  4. Both A. and B.


Correct Option: C

Which of the following is not allowed while creating a table using CRRATE TABLE in SQL?

  1. Table name can be an oracle reserved word

  2. Table names must begin with a letter

  3. Table names can contain in it numbers also

  4. None of the Above


Correct Option: A
  1. SELECT COLUMNS(*) FROM Persons

  2. SELECT COUNT() FROM Persons

  3. SELECT COUNT(*) FROM Persons

  4. SELECT COLUMNS() FROM Persons


Correct Option: C

Which SQL keyword is used to sort the result-set?

  1. order

  2. sort

  3. order by

  4. sort by


Correct Option: C