Open Source RDBMS - Seamless, Scalable, Stable and Free

한국어 | Login |Register

Versions available for this page: CUBRID 8.4.1 |  CUBRID 8.4.3 |  CUBRID 9.0.0 | 



FIND_IN_SET Function

Description

The FIND_IN_SET function looks for the string str in the string list strlist and returns a position of str if it exists. A string list is a string composed of substrings separated by a comma (,).

If str is not in strlist or strlist is an empty string, 0 is returned. If either argument is NULL, NULL is returned. This function does not work properly if str contains a comma (,).

Syntax

FIND_IN_SET(str, strlist)

  • str : A string to be searched
  • strlist : A group of strings separated by a comma
Example

SELECT FIND_IN_SET('b','a,b,c,d');

2