Skip to content

Commit 664129a

Browse files
Merge pull request #12 from waqasm78/master
Added documentation articles
2 parents 64ac6ba + 3324ee8 commit 664129a

File tree

6 files changed

+270
-0
lines changed

6 files changed

+270
-0
lines changed
Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
# String_CompareCurrentCultureIgnoreCase
2+
3+
`String_CompareCurrentCultureIgnoreCase` compares two specified String objects using culture-sensitive sort rules, the current culture, and ignoring the case of the strings, and returns an integer that indicates their relative position in the sort order.
4+
5+
```csharp
6+
String_CompareCurrentCultureIgnoreCase (
7+
@strA NVARCHAR (MAX),
8+
@strB NVARCHAR (MAX)
9+
)
10+
RETURNS INT
11+
```
12+
13+
## Parameters
14+
15+
- **strA**: The first string to compare.
16+
- **strB**: The second string to compare.
17+
18+
## Returns
19+
20+
A 32-bit signed integer that indicates the lexical relationship between the two comparands.
21+
22+
| Value | Condition |
23+
|:--------- |:--------- |
24+
|Less than zero |strA precedes strB in the sort order.|
25+
|Zero |strA occurs in the same position as strB in the sort order.|
26+
|Greater than zero |strA follows strB in the sort order.|
27+
28+
## Example
29+
30+
```csharp
31+
SELECT SQLNET::String_CompareCurrentCultureIgnoreCase('case', 'Case')
32+
SELECT SQLNET::String_CompareCurrentCultureIgnoreCase('encyclopædia', 'encyclopaedia')
33+
```
34+
35+
# String_CompareCurrentCultureIgnoreCase4k
36+
37+
It is equivalent to `String_CompareCurrentCultureIgnoreCase` except no NVARCHAR(MAX) parameters; it can be used when input data will never be over 4000 characters as this function offers better performance.
38+
39+
```csharp
40+
String_CompareCurrentCultureIgnoreCase4k (
41+
@strA NVARCHAR (4000),
42+
@strB NVARCHAR (4000)
43+
)
44+
RETURNS INT
45+
```
46+
47+
## Example
48+
49+
```csharp
50+
SELECT SQLNET::String_CompareCurrentCultureIgnoreCase4k('case', 'Case')
51+
SELECT SQLNET::String_CompareCurrentCultureIgnoreCase4k('encyclopædia', 'encyclopaedia')
52+
```
Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
# String_CompareCurrentCulture
2+
3+
`String_CompareCurrentCulture` compares two specified String objects using culture-sensitive sort rules and the current culture, and returns an integer that indicates their relative position in the sort order.
4+
5+
```csharp
6+
String_CompareCurrentCulture (
7+
@strA NVARCHAR (MAX),
8+
@strB NVARCHAR (MAX)
9+
)
10+
RETURNS INT
11+
```
12+
13+
## Parameters
14+
15+
- **strA**: The first string to compare.
16+
- **strB**: The second string to compare.
17+
18+
## Returns
19+
20+
A 32-bit signed integer that indicates the lexical relationship between the two comparands.
21+
22+
| Value | Condition |
23+
|:--------- |:--------- |
24+
|Less than zero |strA precedes strB in the sort order.|
25+
|Zero |strA occurs in the same position as strB in the sort order.|
26+
|Greater than zero |strA follows strB in the sort order.|
27+
28+
## Example
29+
30+
```csharp
31+
SELECT SQLNET::String_CompareCurrentCulture('case', 'Case')
32+
SELECT SQLNET::String_CompareCurrentCulture('encyclopædia', 'encyclopaedia')
33+
```
34+
35+
# String_CompareCurrentCulture4k
36+
37+
It is equivalent to `String_CompareCurrentCulture` except no NVARCHAR(MAX) parameters; it can be used when input data will never be over 4000 characters as this function offers better performance.
38+
39+
```csharp
40+
String_CompareCurrentCulture4k (
41+
@strA NVARCHAR (4000),
42+
@strB NVARCHAR (4000)
43+
)
44+
RETURNS INT
45+
```
46+
47+
## Example
48+
49+
```csharp
50+
SELECT SQLNET::String_CompareCurrentCulture4k('case', 'Case')
51+
SELECT SQLNET::String_CompareCurrentCulture4k('encyclopædia', 'encyclopaedia')
52+
```
Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
# String_CompareIgnoreCase
2+
3+
`String_CompareIgnoreCase` compares two specified String objects, ignoring or honoring their case, and returns an integer that indicates their relative position in the sort order.
4+
5+
```csharp
6+
String_CompareIgnoreCase (
7+
@strA NVARCHAR (MAX),
8+
@strB NVARCHAR (MAX)
9+
)
10+
RETURNS INT
11+
```
12+
13+
## Parameters
14+
15+
- **strA**: The first string to compare.
16+
- **strB**: The second string to compare.
17+
18+
## Returns
19+
20+
A 32-bit signed integer that indicates the lexical relationship between the two comparands.
21+
22+
| Value | Condition |
23+
|:--------- |:--------- |
24+
|Less than zero |strA precedes strB in the sort order.|
25+
|Zero |strA occurs in the same position as strB in the sort order.|
26+
|Greater than zero |strA follows strB in the sort order.|
27+
28+
## Example
29+
30+
```csharp
31+
SELECT SQLNET::String_CompareIgnoreCase('case', 'Case')
32+
SELECT SQLNET::String_CompareIgnoreCase('Archæology', 'ARCHÆOLOGY')
33+
```
34+
35+
# String_CompareIgnoreCase4k
36+
37+
It is equivalent to `String_CompareIgnoreCase` except no NVARCHAR(MAX) parameters; it can be used when input data will never be over 4000 characters as this function offers better performance.
38+
39+
```csharp
40+
String_CompareIgnoreCase4k (
41+
@strA NVARCHAR (4000),
42+
@strB NVARCHAR (4000)
43+
)
44+
RETURNS INT
45+
```
46+
47+
## Example
48+
49+
```csharp
50+
SELECT SQLNET::String_CompareIgnoreCase4k('case', 'Case')
51+
SELECT SQLNET::String_CompareIgnoreCase4k('Archæology', 'ARCHÆOLOGY')
52+
```
Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
# String_CompareInvariantCulture
2+
3+
`String_CompareInvariantCulture` compares two specified String objects using culture-sensitive sort rules and the invariant culture, and returns an integer that indicates their relative position in the sort order.
4+
5+
```csharp
6+
String_CompareInvariantCulture (
7+
@strA NVARCHAR (MAX),
8+
@strB NVARCHAR (MAX)
9+
)
10+
RETURNS INT
11+
```
12+
13+
## Parameters
14+
15+
- **strA**: The first string to compare.
16+
- **strB**: The second string to compare.
17+
18+
## Returns
19+
20+
A 32-bit signed integer that indicates the lexical relationship between the two comparands.
21+
22+
| Value | Condition |
23+
|:--------- |:--------- |
24+
|Less than zero |strA precedes strB in the sort order.|
25+
|Zero |strA occurs in the same position as strB in the sort order.|
26+
|Greater than zero |strA follows strB in the sort order.|
27+
28+
## Example
29+
30+
```csharp
31+
SELECT SQLNET::String_CompareInvariantCulture('case', 'Case')
32+
SELECT SQLNET::String_CompareInvariantCulture('encyclopædia', 'encyclopaedia')
33+
```
34+
35+
# String_CompareInvariantCulture4k
36+
37+
It is equivalent to `String_CompareInvariantCulture` except no NVARCHAR(MAX) parameters; it can be used when input data will never be over 4000 characters as this function offers better performance.
38+
39+
```csharp
40+
String_CompareInvariantCulture4k (
41+
@strA NVARCHAR (4000),
42+
@strB NVARCHAR (4000)
43+
)
44+
RETURNS INT
45+
```
46+
47+
## Example
48+
49+
```csharp
50+
SELECT SQLNET::String_CompareInvariantCulture4k('case', 'Case')
51+
SELECT SQLNET::String_CompareInvariantCulture4k('encyclopædia', 'encyclopaedia')
52+
```
Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
# String_Compare
2+
3+
`String_Compare` compares two specified String objects and returns an integer that indicates their relative position in the sort order.
4+
5+
```csharp
6+
String_Compare (
7+
@strA NVARCHAR (MAX),
8+
@strB NVARCHAR (MAX)
9+
)
10+
RETURNS INT
11+
```
12+
13+
## Parameters
14+
15+
- **strA**: The first string to compare.
16+
- **strB**: The second string to compare.
17+
18+
## Returns
19+
20+
A 32-bit signed integer that indicates the lexical relationship between the two comparands.
21+
22+
| Value | Condition |
23+
|:--------- |:--------- |
24+
|Less than zero |strA precedes strB in the sort order.|
25+
|Zero |strA occurs in the same position as strB in the sort order.|
26+
|Greater than zero |strA follows strB in the sort order.|
27+
28+
## Example
29+
30+
```csharp
31+
SELECT SQLNET::String_Compare('abc', 'abc')
32+
```
33+
34+
# String_Compare4k
35+
36+
It is equivalent to `String_Compare` except no NVARCHAR(MAX) parameters; it can be used when input data will never be over 4000 characters as this function offers better performance.
37+
38+
```csharp
39+
String_Compare4k (
40+
@strA NVARCHAR (4000),
41+
@strB NVARCHAR (4000)
42+
)
43+
RETURNS INT
44+
```
45+
46+
## Example
47+
48+
```csharp
49+
SELECT SQLNET::String_Compare4k('abc', 'abc')
50+
```
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# String
2+
3+
Represents text as a sequence of UTF-16 code units.
4+
5+
6+
| Name | Description | Example |
7+
| :--- | :---------- | :------ |
8+
| [String_Compare](/string-compare) | Compares two specified String objects. | [Try it]()|
9+
| [String_CompareCurrentCulture](/string-compare-current-culture) | Compares two specified String objects using culture-sensitive sort rules and the current culture. | [Try it]()|
10+
| [String_CompareCurrentCultureIgnoreCase](/string-compare-current-culture-ignore-case) | Compares two specified String objects using culture-sensitive sort rules, the current culture, and ignoring the case of the strings. | [Try it]()|
11+
| [String_CompareIgnoreCase](/string-compare-ignore-case) | Compares two specified String objects ignoring their case. | [Try it]()|
12+
| [String_CompareInvariantCulture](/string-compare-invariant-culture) | Compares two specified String objects using culture-sensitive sort rules and the invariant culture. | [Try it]()|

0 commit comments

Comments
 (0)