Which of the following are 'String Functions'?
(A) LENGTH
(B) INSTR
(C) MID
(D) COUNT
Which of the following are 'String Functions'?
(A) LENGTH
(B) INSTR
(C) MID
(D) COUNT
Solution
✅ Correct Option: 4
LENGTH returns the number of characters in a string, INSTR returns the position of a substring within a string, and MID extracts a part of a string. All three work on text, so they are string functions.
COUNT (options 1, 2 and 3): it is an aggregate function that counts rows or non-NULL values in a column, and it does not work on the characters of a string.
Other aggregate functions are SUM, AVG, MAX and MIN.
Related questions:
2026: 23 May Shift 1