You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
`String_LastIndexOfCurrentCultureIgnoreCase` returns the zero-based index of the last occurrence of a `searchValue` Unicode character or string within the `source` string using culture-sensitive sort rules, the current culture, and ignoring the case of the strings.
4
+
5
+
```csharp
6
+
String_LastIndexOfCurrentCultureIgnoreCase (
7
+
@sourceNVARCHAR (MAX),
8
+
@searchValueNVARCHAR (MAX)
9
+
)
10
+
RETURNSINT
11
+
```
12
+
13
+
## Parameters
14
+
15
+
-**source**: The source string.
16
+
-**searchValue**: The string to search within the source string.
17
+
18
+
## Returns
19
+
20
+
The zero-based index position of the `searchValue` parameter from the start of the `source` string if that string is found, or -1 if it is not. If `searchValue` is Empty, the return value is 0.
21
+
22
+
## Example
23
+
24
+
```csharp
25
+
SELECTSQLNET::String_LastIndexOfCurrentCultureIgnoreCase('This is a string.', 'string')
It is equivalent to `String_LastIndexOfCurrentCultureIgnoreCase` except no NVARCHAR(MAX) parameters; it can be used when input data will never be over 4000 characters as this function offers better performance.
32
+
33
+
```csharp
34
+
String_LastIndexOfCurrentCultureIgnoreCase4k (
35
+
@sourceNVARCHAR (4000),
36
+
@searchValueNVARCHAR (4000)
37
+
)
38
+
RETURNSINT
39
+
```
40
+
41
+
## Example
42
+
43
+
```csharp
44
+
SELECTSQLNET::String_LastIndexOfCurrentCultureIgnoreCase4k('This is a string.', 'string')
`String_LastIndexOfCurrentCulture` returns the zero-based index of the last occurrence of a `searchValue` Unicode character or string within the `source` string using culture-sensitive sort rules and the current culture.
4
+
5
+
```csharp
6
+
String_LastIndexOfCurrentCulture (
7
+
@sourceNVARCHAR (MAX),
8
+
@searchValueNVARCHAR (MAX)
9
+
)
10
+
RETURNSINT
11
+
```
12
+
13
+
## Parameters
14
+
15
+
-**source**: The source string.
16
+
-**searchValue**: The string to search within the source string.
17
+
18
+
## Returns
19
+
20
+
The zero-based index position of the `searchValue` parameter from the start of the `source` string if that string is found, or -1 if it is not. If `searchValue` is Empty, the return value is 0.
21
+
22
+
## Example
23
+
24
+
```csharp
25
+
SELECTSQLNET::String_LastIndexOfCurrentCulture('This is a string.', 'string')
It is equivalent to `String_LastIndexOfCurrentCulture` except no NVARCHAR(MAX) parameters; it can be used when input data will never be over 4000 characters as this function offers better performance.
32
+
33
+
```csharp
34
+
String_LastIndexOfCurrentCulture4k (
35
+
@sourceNVARCHAR (4000),
36
+
@searchValueNVARCHAR (4000)
37
+
)
38
+
RETURNSINT
39
+
```
40
+
41
+
## Example
42
+
43
+
```csharp
44
+
SELECTSQLNET::String_LastIndexOfCurrentCulture4k('This is a string.', 'string')
`String_LastIndexOfInvariantCultureIgnoreCase` returns the zero-based index of the last occurrence of a `searchValue` Unicode character or string within the `source` string using culture-sensitive sort rules, the invariant culture, and ignoring the case of the strings.
4
+
5
+
```csharp
6
+
String_LastIndexOfInvariantCultureIgnoreCase (
7
+
@sourceNVARCHAR (MAX),
8
+
@searchValueNVARCHAR (MAX)
9
+
)
10
+
RETURNSINT
11
+
```
12
+
13
+
## Parameters
14
+
15
+
-**source**: The source string.
16
+
-**searchValue**: The string to search within the source string.
17
+
18
+
## Returns
19
+
20
+
The zero-based index position of the `searchValue` parameter from the start of the `source` string if that string is found, or -1 if it is not. If `searchValue` is Empty, the return value is 0.
21
+
22
+
## Example
23
+
24
+
```csharp
25
+
SELECTSQLNET::String_LastIndexOfInvariantCultureIgnoreCase('This is a string.', 'string')
It is equivalent to `String_LastIndexOfInvariantCultureIgnoreCase` except no NVARCHAR(MAX) parameters; it can be used when input data will never be over 4000 characters as this function offers better performance.
32
+
33
+
```csharp
34
+
String_LastIndexOfInvariantCultureIgnoreCase4k (
35
+
@sourceNVARCHAR (4000),
36
+
@searchValueNVARCHAR (4000)
37
+
)
38
+
RETURNSINT
39
+
```
40
+
41
+
## Example
42
+
43
+
```csharp
44
+
SELECTSQLNET::String_LastIndexOfInvariantCultureIgnoreCase4k('This is a string.', 'string')
`String_LastIndexOfInvariantCulture` returns the zero-based index of the last occurrence of a `searchValue` Unicode character or string within the `source` string using culture-sensitive sort rules and the invariant culture.
4
+
5
+
```csharp
6
+
String_LastIndexOfInvariantCulture (
7
+
@sourceNVARCHAR (MAX),
8
+
@searchValueNVARCHAR (MAX)
9
+
)
10
+
RETURNSINT
11
+
```
12
+
13
+
## Parameters
14
+
15
+
-**source**: The source string.
16
+
-**searchValue**: The string to search within the source string.
17
+
18
+
## Returns
19
+
20
+
The zero-based index position of the `searchValue` parameter from the start of the `source` string if that string is found, or -1 if it is not. If `searchValue` is Empty, the return value is 0.
21
+
22
+
## Example
23
+
24
+
```csharp
25
+
SELECTSQLNET::String_LastIndexOfInvariantCulture('This is a string.', 'string')
It is equivalent to `String_LastIndexOfInvariantCulture` except no NVARCHAR(MAX) parameters; it can be used when input data will never be over 4000 characters as this function offers better performance.
32
+
33
+
```csharp
34
+
String_LastIndexOfInvariantCulture4k (
35
+
@sourceNVARCHAR (4000),
36
+
@searchValueNVARCHAR (4000)
37
+
)
38
+
RETURNSINT
39
+
```
40
+
41
+
## Example
42
+
43
+
```csharp
44
+
SELECTSQLNET::String_LastIndexOfInvariantCulture4k('This is a string.', 'string')
`String_LastIndexOfOrdinalIgnoreCase` returns the zero-based index of the last occurrence of a `searchValue` Unicode character or string within the `source` string using ordinal (binary) sort rules and ignoring the case of the strings.
4
+
5
+
```csharp
6
+
String_LastIndexOfOrdinalIgnoreCase (
7
+
@sourceNVARCHAR (MAX),
8
+
@searchValueNVARCHAR (MAX)
9
+
)
10
+
RETURNSINT
11
+
```
12
+
13
+
## Parameters
14
+
15
+
-**source**: The source string.
16
+
-**searchValue**: The string to search within the source string.
17
+
18
+
## Returns
19
+
20
+
The zero-based index position of the `searchValue` parameter from the start of the `source` string if that string is found, or -1 if it is not. If `searchValue` is Empty, the return value is 0.
21
+
22
+
## Example
23
+
24
+
```csharp
25
+
SELECTSQLNET::String_LastIndexOfOrdinalIgnoreCase('This is a string.', 'string')
It is equivalent to `String_LastIndexOfOrdinalIgnoreCase` except no NVARCHAR(MAX) parameters; it can be used when input data will never be over 4000 characters as this function offers better performance.
32
+
33
+
```csharp
34
+
String_LastIndexOfOrdinalIgnoreCase4k (
35
+
@sourceNVARCHAR (4000),
36
+
@searchValueNVARCHAR (4000)
37
+
)
38
+
RETURNSINT
39
+
```
40
+
41
+
## Example
42
+
43
+
```csharp
44
+
SELECTSQLNET::String_LastIndexOfOrdinalIgnoreCase4k('This is a string.', 'string')
`String_LastIndexOfOrdinal` returns the zero-based index of the last occurrence of a `searchValue` Unicode character or string within the `source` string using ordinal (binary) sort rules.
4
+
5
+
```csharp
6
+
String_LastIndexOfOrdinal (
7
+
@sourceNVARCHAR (MAX),
8
+
@searchValueNVARCHAR (MAX)
9
+
)
10
+
RETURNSINT
11
+
```
12
+
13
+
## Parameters
14
+
15
+
-**source**: The source string.
16
+
-**searchValue**: The string to search within the source string.
17
+
18
+
## Returns
19
+
20
+
The zero-based index position of the `searchValue` parameter from the start of the `source` string if that string is found, or -1 if it is not. If `searchValue` is Empty, the return value is 0.
21
+
22
+
## Example
23
+
24
+
```csharp
25
+
SELECTSQLNET::String_LastIndexOfOrdinal('This is a string.', 'string')
It is equivalent to `String_LastIndexOfOrdinal` except no NVARCHAR(MAX) parameters; it can be used when input data will never be over 4000 characters as this function offers better performance.
32
+
33
+
```csharp
34
+
String_LastIndexOfOrdinal4k (
35
+
@sourceNVARCHAR (4000),
36
+
@searchValueNVARCHAR (4000)
37
+
)
38
+
RETURNSINT
39
+
```
40
+
41
+
## Example
42
+
43
+
```csharp
44
+
SELECTSQLNET::String_LastIndexOfOrdinal4k('This is a string.', 'string')
`String_LastIndexOf` returns the zero-based index of the last occurrence of a `searchValue` Unicode character or string within the `source` string.
4
+
5
+
```csharp
6
+
String_LastIndexOf (
7
+
@sourceNVARCHAR (MAX),
8
+
@searchValueNVARCHAR (MAX)
9
+
)
10
+
RETURNSINT
11
+
```
12
+
13
+
## Parameters
14
+
15
+
-**source**: The source string.
16
+
-**searchValue**: The string to search within the source string.
17
+
18
+
## Returns
19
+
20
+
The zero-based index position of the `searchValue` parameter from the start of the `source` string if that string is found, or -1 if it is not. If `searchValue` is Empty, the return value is 0.
21
+
22
+
## Example
23
+
24
+
```csharp
25
+
SELECTSQLNET::String_LastIndexOf('This is a string.', 'string')
26
+
```
27
+
28
+
# String_LastIndexOf4k
29
+
30
+
It is equivalent to `String_LastIndexOf` except no NVARCHAR(MAX) parameters; it can be used when input data will never be over 4000 characters as this function offers better performance.
31
+
32
+
```csharp
33
+
String_LastIndexOf4k (
34
+
@sourceNVARCHAR (4000),
35
+
@searchValueNVARCHAR (4000)
36
+
)
37
+
RETURNSINT
38
+
```
39
+
40
+
## Example
41
+
42
+
```csharp
43
+
SELECTSQLNET::String_LastIndexOf4k('This is a string.', 'string')
Copy file name to clipboardExpand all lines: docs2/pages/documentations/string/string.md
+8Lines changed: 8 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -22,3 +22,11 @@ Represents text as a sequence of UTF-16 code units.
22
22
|[String_IndexOfInvariantCultureIgnoreCase(source, searchValue)](/string-indexof-invariant-culture-ignore-case)| Returns the zero-based index of the first occurrence of the specified string using culture-sensitive sort rules, the invariant culture, and ignoring the case of the strings. |[Try it]()|
23
23
|[String_IndexOfOrdinal(source, searchValue)](/string-indexof-ordinal)| Returns the zero-based index of the first occurrence of the specified string using ordinal (binary) sort rules. |[Try it]()|
24
24
|[String_IndexOfOrdinalIgnoreCase(source, searchValue)](/string-indexof-ordinal-ignore-case)| Returns the zero-based index of the first occurrence of the specified string using ordinal (binary) sort rules, and ignoring the case of the strings. |[Try it]()|
25
+
|[String_Insert(source, startIndex, value)](/string-insert)| Returns a new string in which a specified string is inserted at a specified index position. |[Try it]()|
26
+
|[String_LastIndexOf(source, searchValue)](/string-last-indexof)| Returns the zero-based index of the last occurrence of the specified string. |[Try it]()|
27
+
|[String_LastIndexOfCurrentCulture(source, searchValue)](/string-last-indexof-current-culture)| Returns the zero-based index of the last occurrence of the specified string using culture-sensitive sort rules and the current culture. |[Try it]()|
28
+
|[String_LastIndexOfCurrentCultureIgnoreCase(source, searchValue)](/string-last-indexof-current-culture-ignore-case)| Returns the zero-based index of the last occurrence of the specified string using culture-sensitive sort rules, the current culture, and ignoring the case of the strings. |[Try it]()|
29
+
|[String_LastIndexOfInvariantCulture(source, searchValue)](/string-last-indexof-invariant-culture)| Returns the zero-based index of the last occurrence of the specified string using culture-sensitive sort rules and the invariant culture. |[Try it]()|
30
+
|[String_LastIndexOfInvariantCultureIgnoreCase(source, searchValue)](/string-last-indexof-invariant-culture-ignore-case)| Returns the zero-based index of the last occurrence of the specified string using culture-sensitive sort rules, the invariant culture, and ignoring the case of the strings. |[Try it]()|
31
+
|[String_LastIndexOfOrdinal(source, searchValue)](/string-last-indexof-ordinal)| Returns the zero-based index of the last occurrence of the specified string using ordinal (binary) sort rules. |[Try it]()|
32
+
|[String_LastIndexOfOrdinalIgnoreCase(source, searchValue)](/string-last-indexof-ordinal-ignore-case)| Returns the zero-based index of the last occurrence of the specified string using ordinal (binary) sort rules, and ignoring the case of the strings. |[Try it]()|
0 commit comments