EXPAND ALL
  • Home

find

Returns the index of the first occurrence of the substring in the given string. If no match is found, returns -1.

Returns: INT64

The index of the first occurence of the substring. -1 if no match is found.

Arguments

VariableTypeDescription
arg1STRINGThe string to search through.
arg2STRINGThe substring to find.

Examples:

df.svc_name = "pixie-labs"
df.found = px.find(df.svc_name, '-labs') # 5
This site uses cookies to provide you with a better user experience. By using Pixie, you consent to our use of cookies.