### questions

Title
###### GROUP BY clause is placed before which clause in SQL?

GROUP BY clause is placed before which clause in SQL?

1. HAVING
2. WHERE
3. ORDER BY
4. FROM
###### Which one if these is used to put the same value in all the rows?

Which one if these is used to put the same value in all the rows?

1. Group by unique column
2. Group by single column
3. Group by one column
4. Group by same value
###### In order to convert the expression from one to another data type, which SQL Function is used?

In order to convert the expression from one to another data type, which SQL Function is used?

1. CONVERT
2. CHANGE
3. CAST
4. TRANSIT
###### What is the syntax of SQL CAST Function?

What is the syntax of SQL CAST Function?

1. CAST (expression AS [data type])
2. CAST (expression IN [data type])
3. CAST (expression TO [data type])
4. CAST (expression FOR [data type])
###### What is the default length of any data type in the CAST function?

What is the default length of any data type in the CAST function?

1. 10
2. 20
3. 30
4. 40
###### Select the correct type(s) of SQL Comments

Select the correct type(s) of SQL Comments.

4. All of the above
###### Select the syntax of Single Line Comment

Select the syntax of Single Line Comment.

1. .
2. !
3. --
4. #
###### Comments whose starting and ending lines are different are known as –

Comments whose starting and ending lines are different are known as –

###### Select the correct syntax for Multi-line Comments

Select the correct syntax for Multi-line Comments.

1. //*Line1 Line2*//
2. /*Line1 Line2/*
3. */Line1 Line2*/
4. /*Line1 Line2*/
###### What will be the output of the below SQL statement?

What will be the output of the below SQL statement?

``SELECT CAST(25.65 AS int);``

1. 25
2. 26
###### What will be the output of the below SQL statement?

What will be the output of the below SQL statement?

``SELECT CAST(25.65 AS varchar);``

1. 25
2. 26
3. 25.65
4. 25.00
###### What will be the output of the below SQL statement?

What will be the output of the below SQL statement?

``SELECT CAST('2021-10-06' AS datetime);``

1. 2021-10-06 00:00:00.000
2. 2021-10-06
3. 2021 OCT 06
4. 06-10-2021

MCQs

Views