Database - Sql Test

Test Instructions :

1. The Test is 1hr duration.
2. The Test Paper consists of 30 questions. The maximum marks are 30.
3. All the questions are multiple choice question type with three options for each question.
4. Out of the three options given for each question, only one option is the correct answer.
5. Each question is allotted 1 mark for each correct response.
6. 0.25 will be deducted for incorrect response of each question.
Start Test

   Time Left : 00 : 30    : 00

The ............. statement is used to delete a table.

  

  

  

  

Which of the following is not a valid aggregate function?

  

  

  

  

MySQL Access security is controlled through?

  

  

  

  

MySQL is

  

  

  

  

Which SQL statement is used to delete data from a database?

  

  

  

  

How is structure of a table got in MySQL?

  

  

  

  

How can you change "Hansen" into "Nilsen" in the "LastName" column in the Persons table?

  

  

  

  

Which of these is not a valid name for a column

  

  

  

  

The main MySQL program that does all the data handling is called?

  

  

  

  

Can I define multiple unique constraints on a table?

  

  

Which SQL statement is used to update data in a database?

  

  

  

  

What kind of replication is supported by the MySQL server?

  

  

  

  

MySQL supports the complete SQL99 standard

  

  

Which SQL statement is used to insert a new data in a database?

  

  

  

  

The result of a SELECT statement can contain duplicate rows.

  

  

  

mysql_pconnect() is used to make a persistent connection to the database which means a SQL link that do not close when the execution of your script ends.

  

  

Enum values are stored according to their index numbers

  

  

MySQL runs on which operating systems?

  

  

  

  

The “Mysql command line tool” formats are bounded by

  

  

  

  

Which of the following file extension is a valid MyISAM file extension?

  

  

  

  

Primary Key does allow the Null Values. where as in Unique key doesn't accept the Null values.

  

  

What will happen at the end of the following sequence of SQL commands? BEGIN TRANSACTION DELETE FROM MYTABLE WHERE ID=1 DELETE FROM OTHERTABLE ROLLBACK TRANSACTION

  

  

  

  

  

A view is nothing but a ________ table or a stored query

  

  

  

  

The “Mysql command line tool” format the results in which of the following format:

  

  

  

  

Transactions are used to treat sets of SQL statements atomically.

  

  

Which one will delete the table data as well as table structure?

  

  

How much storage space does DATETIME require?

  

  

  

  

Sometimes the expression "select count(*)" will return fewer rows than the expression "select count(value)".

  

  

What MySQL property is used to create a surrogate key in MySQL?

  

  

  

  

On executing DELETE command, if you get an error "foreign key constraint" what does it imply?

  

  

  

  

A SELECT command without a WHERE clause returns?

  

  

  

  

With SQL, how do you select all the records from a table named "Persons" where the value of the column "FirstName" is "Peter"?

  

  

  

  

If you want to undo a GRANT, you should use

  

  

  

  

  

SQL is not case sensitive. SELECT is the same as select.

  

  

What is the command for counting all the rows in a table in MySQL?

  

  

  

  

Can joins be nested?

  

  

Which of the following is NOT available in MySQL?

  

  

  

  

What does the DESC keyword do in the following query? SELECT * FROM MY_TABLE WHERE ID > 0 ORDER BY ID, NAME DESC

  

  

  

  

  

Which command is used on Mysql command line tool to return to window command shell?

  

  

  

  

If you're writing a client using the C language API, your source code should include the following line at the top:

  

  

  

  

The "father" of MySQL is

  

  

  

  

How can we get the number of records or rows in a table?

  

  

  

  

Internally information is held in tables. Which of these is NOT a valid format:

  

  

  

  

  

Which of the following can add a row to a table?

  

  

  

  

Which of these commands will delete a table called XXX if you have appropriate authority:

  

  

  

  

To remove duplicate rows from the result set of a SELECT use the following keyword:

  

  

  

  

In a SELECT with a GROUP BY clause, a WHERE clause, and a HAVING clause, the WHERE conditions are applied before the HAVING conditions.

  

  

  

  

An outer join requires each record in the two joined tables to have a matching record.

  

  

  

  

With SQL, how can you insert "Olsen" as the "LastName" in the "Persons" table?

  

  

  

With SQL, how can you return all the records from a table named "Persons" sorted descending by "FirstName"?

  

  

  

  

Which of the following commands should be used to create a database named “student”?

  

  

  

  

What is DDL?

  

  

  

  

Which of the following is not an SQL aggregate function?

  

  

  

  

  

Which SQL statement is used to return only different values?

  

  

  

  

Which of the following is the correct SQL statement to use to remove rows from a table?

  

  

  

  

Which function used to get the current time in mysql?

  

  

  

How to view all Triggers in MySQL?

  

  

  

  

In a LIKE clause, you can ask for any 6 letter value by writing?

  

  

  

  

Which of the following ways below are the correct way to get the current date?

  

  

  

  

Which SQL statement is used to extract data from a database?

  

  

  

  

  

Can I call a trigger directly called from an application?

  

  

Which of the following is used to delete an entire MYSQL database?

  

  

  

  

With SQL, how do you select all the records from a table named "Persons" where the value of the column "FirstName" starts with an "a"?

  

  

  

  

  

What does SQL stand for?

  

  

  

  

Which of these is a valid call to a function (watch the spaces carefully!)

  

  

  

  

User() fucntion returns the current users user name and ___________

  

  

  

  

Where is metadata stored in MySQL?

  

  

  

  

What MySQL property is used to create a surrogate key in MySQL?

  

  

  

  

If an ENUM column is declared NOT NULL, its default value is the first element of the list of allowed values.

  

  

  

  

What's the difference between the DESCRIBE and SHOW FIELDS FROM commands?

  

  

  

What is DCL?

  

  

  

  

With SQL, how can you insert a new record into the "Persons" table?

  

  

  

Which is the default order of sort in ORDER BY clause?

  

  

What is Row?

  

  

  

  

USE keyword is used to select a ___________

  

  

  

  

What is Table?

  

  

  

  

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

  

  

  

  

What is a candidate key?

  

  

  

  

A user with RELOAD priveliges can

  

  

  

  

How much character are allowed to create database name?

  

  

  

  

MySql | Which of the following is available in MySQL:

  

  

  

  

  

When do we use a HAVING clause?

  

  

  

  

To use MySQL on your computer, you'll need?

  

  

  

  

Which of the following is NOT supported by MySQL

  

  

  

  

A table may be joined to itself.

  

  

  

One of the early proponents of relational database who laid down many of the principles we use to this day was:

  

  

  

  

  

Can DISTINCT command be used for more than one column?

  

  

What is Column?

  

  

  

  

MySQL comes with as standard with client libraries for:

  

  

  

  

Mysql command line tool is used to show “how many rows are returned and how long SQL command took to execute”

  

  

  

  

Given an employees table as follows:   emp_id emp_name 1 Brush 2 Jerrin  what value will be return by below query ? Select count(*) from employees  

  

  

  

  

The program called mysql is

  

  

  

  

  

What type of lock will deny users any access to a table?

  

  

  

  

  

How many TRIGGERS are allowed in MySql table?

  

  

  

  

What SQL clause is used to restrict the rows returned by a query?

  

  

  

  

Which of the following DBMSs do not have a native PHP extension?

  

  

  

  

  

What is DML?

  

  

  

  

How do I find out all databases starting with ‘test to which I have access to?

  

  

  

  

________ is an open source DBMS product that runs on UNIX, Linux and Windows.

  

  

  

  

With SQL, how do you select a column named "FirstName" from a table named "Persons"?

  

  

  

Note:
  • Click the 'Submit Test' button given in the bottom of this page to Submit your answers.
  • Test will be submitted automatically if the time expired.
  • Don't refresh the page.