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
Copy file name to clipboardExpand all lines: articles/cosmos-db/sql-query-mathematical-functions.md
+27-29Lines changed: 27 additions & 29 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,7 +5,7 @@ author: ginamr
5
5
ms.service: cosmos-db
6
6
ms.subservice: cosmosdb-sql
7
7
ms.topic: conceptual
8
-
ms.date: 09/13/2019
8
+
ms.date: 05/26/2021
9
9
ms.author: girobins
10
10
ms.custom: query-reference
11
11
---
@@ -28,35 +28,33 @@ The result is:
28
28
29
29
## Functions
30
30
31
-
The following supported built-in mathematical functions perform a calculation, usually based on input arguments, and return a numeric expression:
31
+
The following supported built-in mathematical functions perform a calculation, usually based on input arguments, and return a numeric expression. The **index usage** column assumes, where applicable, that you're comparing the mathematical system function to another value with an equality filter.
32
32
33
-
*[ABS](sql-query-abs.md)
34
-
*[ACOS](sql-query-acos.md)
35
-
*[ASIN](sql-query-asin.md)
36
-
*[ATAN](sql-query-atan.md)
37
-
*[ATN2](sql-query-atn2.md)
38
-
*[CEILING](sql-query-ceiling.md)
39
-
*[COS](sql-query-cos.md)
40
-
*[COT](sql-query-cot.md)
41
-
*[DEGREES](sql-query-degrees.md)
42
-
*[EXP](sql-query-exp.md)
43
-
*[FLOOR](sql-query-floor.md)
44
-
*[LOG](sql-query-log.md)
45
-
*[LOG10](sql-query-log10.md)
46
-
*[PI](sql-query-pi.md)
47
-
*[POWER](sql-query-power.md)
48
-
*[RADIANS](sql-query-radians.md)
49
-
*[RAND](sql-query-rand.md)
50
-
*[ROUND](sql-query-round.md)
51
-
*[SIGN](sql-query-sign.md)
52
-
*[SIN](sql-query-sin.md)
53
-
*[SQRT](sql-query-sqrt.md)
54
-
*[SQUARE](sql-query-square.md)
55
-
*[TAN](sql-query-tan.md)
56
-
*[TRUNC](sql-query-trunc.md)
57
-
58
-
59
-
All mathematical functions, except for RAND, are deterministic functions. This means they return the same results each time they are called with a specific set of input values.
33
+
| System function | Index usage |[Index usage in queries with scalar aggregate functions](index-overview.md#index-utilization-for-scalar-aggregate-functions)| Remarks |
|[ABS](sql-query-abs.md)| Index seek | Index seek ||
36
+
|[ACOS](sql-query-acos.md)| Full scan | Full scan ||
37
+
|[ASIN](sql-query-asin.md)| Full scan | Full scan ||
38
+
|[ATAN](sql-query-atan.md)| Full scan | Full scan ||
39
+
|[ATN2](sql-query-atn2.md)| Full scan | Full scan ||
40
+
|[CEILING](sql-query-ceiling.md)| Index seek | Index seek ||
41
+
|[COS](sql-query-cos.md)| Full scan | Full scan ||
42
+
|[COT](sql-query-cot.md)| Full scan | Full scan ||
43
+
|[DEGREES](sql-query-degrees.md)| Index seek | Index seek ||
44
+
|[EXP](sql-query-exp.md)| Full scan | Full scan ||
45
+
|[FLOOR](sql-query-floor.md)| Index seek | Index seek ||
46
+
|[LOG](sql-query-log.md)| Full scan | Full scan ||
47
+
|[LOG10](sql-query-log10.md)| Full scan | Full scan ||
48
+
|[PI](sql-query-pi.md)| N/A | N/A | PI () returns a constant value. Because the result is deterministic, comparisons with PI() can use the index. |
49
+
|[POWER](sql-query-power.md)| Full scan | Full scan ||
50
+
|[RADIANS](sql-query-radians.md)| Index seek | Index seek ||
51
+
|[RAND](sql-query-rand.md)| N/A | N/A | Rand() returns a random number. Because the result is non-deterministic, comparisons that involve Rand() cannot use the index. |
52
+
|[ROUND](sql-query-round.md)| Index seek | Index seek ||
53
+
|[SIGN](sql-query-sign.md)| Index seek | Index seek ||
54
+
|[SIN](sql-query-sin.md)| Full scan | Full scan ||
55
+
|[SQRT](sql-query-sqrt.md)| Full scan | Full scan ||
56
+
|[SQUARE](sql-query-square.md)| Full scan | Full scan ||
57
+
|[TAN](sql-query-tan.md)| Full scan | Full scan ||
Copy file name to clipboardExpand all lines: articles/cosmos-db/sql-query-string-functions.md
+4-4Lines changed: 4 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,7 +5,7 @@ author: timsander1
5
5
ms.service: cosmos-db
6
6
ms.subservice: cosmosdb-sql
7
7
ms.topic: conceptual
8
-
ms.date: 05/04/2021
8
+
ms.date: 05/26/2021
9
9
ms.author: tisande
10
10
ms.custom: query-reference
11
11
---
@@ -16,9 +16,9 @@ The string functions let you perform operations on strings in Azure Cosmos DB.
16
16
17
17
## Functions
18
18
19
-
The following scalar functions perform an operation on a string input value and return a string, numeric, or Boolean value:
20
-
21
-
| System function | Index usage | Index usage in queries with [scalar aggregate functions](index-overview.md#index-utilization-for-scalar-aggregate-functions)| Remarks |
19
+
The below scalar functions perform an operation on a string input value and return a string, numeric, or Boolean value. The **index usage** column assumes, where applicable, that you're comparing the string system function to another value with an equality filter.
20
+
21
+
| System function | Index usage |[Index usage in queries with scalar aggregate functions](index-overview.md#index-utilization-for-scalar-aggregate-functions)| Remarks |
Copy file name to clipboardExpand all lines: articles/cosmos-db/sql-query-type-checking-functions.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,7 +5,7 @@ author: timsander1
5
5
ms.service: cosmos-db
6
6
ms.subservice: cosmosdb-sql
7
7
ms.topic: conceptual
8
-
ms.date: 05/04/2021
8
+
ms.date: 05/26/2021
9
9
ms.author: tisande
10
10
ms.custom: query-reference
11
11
---
@@ -16,7 +16,7 @@ The type-checking functions let you check the type of an expression within a SQL
16
16
17
17
## Functions
18
18
19
-
The following functions support type checking against input values, and each return a Boolean value:
19
+
The following functions support type checking against input values, and each return a Boolean value. The **index usage** column assumes, where applicable, that you're comparing the type checking functions to another value with an equality filter.
20
20
21
21
| System function | Index usage |[Index usage in queries with scalar aggregate functions](index-overview.md#index-utilization-for-scalar-aggregate-functions)| Remarks |
0 commit comments