English

Write the name of the functions to perform the following operation: To display the specified number of characters from a particular position of the given string. - Computer Science (Python)

Advertisements
Advertisements

Question

Write the name of the functions to perform the following operation:

To display the specified number of characters from a particular position of the given string.

One Line Answer
Advertisements

Solution

MID( ) or SUBSTRING( )

shaalaa.com
Functions in SQL
  Is there an error in this question or solution?
Chapter 9: Structured Query Language (SQL) - Exercise [Page 177]

APPEARS IN

NCERT Computer Science [English] Class 12
Chapter 9 Structured Query Language (SQL)
Exercise | Q 1. f) ii) | Page 177

RELATED QUESTIONS

______ keyword is used to find out the number of values in a column?


Consider the table STUDENT given below:

RollNo Name Class DOB Gender City Marks
1 Anand XI 6/6/97 M Agra 430
2 Chetan XII 7/5/94 M Mumbai 460
3 Geet XI 6/5/97 F Agra 470
4 Preeti XII 8/8/95 F Mumbai 492
5 Saniyal XII 8/10/95 M Delhi 360
6 Maakhiy XI 12/12/94 F Dubai 256
7 Neha X 8/12/95 F Moscow 324
8 Nishant X 12/6/95 M Moscow 429

State the command that will give the output as:

Name
Anand
Chetan
Geet
Preeti

(i) select Name from student where Class ='XI' and Class='XII';

(ii) select name from student where not Class='XI' and Class='XII';

(iii) select name from student where City="Agra" or City="Mumbai";

(iv) select name from student where City in("Agra", "Mumbai");

Choose the correct option:


What will be the output of the following SQL statement? 

SELECT DAY NAME (2022-04-08) 


Assertion (A): COUNf function ignores DISTINCT

Reason (R): DISTINCT ignores the duplicate values.


What will be returned by the given query? select day of year('2015-02-10') = ______.


What will be returned by the given query? select substr("Computer", 4) = ______.


What will be returned by the given query? select power(3, 2) = ______.


What will be returned by the given query? Select length(trim("ABC Public School")) = ______.


What will be returned by the given query? SELECT MID('LeaminglsFun', 2, 4) = ______.


"COUNT" keyword belongs to which categories in Mysql?


The ______ function returns m raised to the nth power.


Name a function of MySQL used to give position of the first occurrence of a string2 in string1.


Which of the following is not a date function?


The string function that returns the index of the first occurrence of substring is ______.


Site any two differences between Single Row Functions and Aggregate Functions.


Write the name of the functions to perform the following operation:

To display the name of the month in which you were born.


Write the output produced by the following SQL statement:

SELECT LENGTH("Informatics Practices");


Write the output produced by the following SQL statement:

SELECT    YEAR(“1979/11/26”),
MONTH(“1979/11/26”),    DAY(“1979/11/26”), MONTHNAME(“1979/11/26”);


Write the output produced by the following SQL statement:

SELECT    LEFT("INDIA", 3),    RIGHT("Computer Science", 4),    MID("Informatics", 3, 4), SUBSTR("Practices", 3);


If column “Fees” contains the data set (5000,8000,7500,5000,8000), what will be the output after the execution of the given query?

SELECT SUM (DISTINCT Fees) FROM student;


In SQL, which function is used to display the current date and time?


Write suitable SQL query for the following:

Display 7 characters extracted from the 7th left character onwards from the string ‘INDIA SHINING’.


Write suitable SQL query for the following:

Remove all the expected leading and trailing spaces from a column userid of the table ‘USERS’.


Explain the following SQL function using a suitable example.

TRIM()


Explain the following SQL function using a suitable example.

DAYNAME()


Explain the following SQL function using a suitable example.

POWER()


Share
Notifications

Englishहिंदीमराठी


      Forgot password?
Use app×