Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add note for null and coalesce for mssql #1397

Merged
merged 1 commit into from
May 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions content/docs/2.10/scalers/mssql.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ The `mssql` trigger always requires the following information:
- `targetValue` - A threshold that is used as `targetValue` or `targetAverageValue` (depending on the trigger metric type) in the Horizontal Pod Autoscaler (HPA). (This value can be a float)
- `activationTargetValue` - Target value for activating the scaler. Learn more about activation [here](./../concepts/scaling-deployments.md#activating-and-scaling-thresholds).(Default: `0`, Optional, This value can be a float)

> Note that the query must return a single integer value. If the query has a possibility of returning `null`, a default value can be set using the `COALESCE` function. For example, `SELECT COALESCE(column_name, 0) FROM table_name;`. See [MSSQL documentation](https://learn.microsoft.com/en-us/sql/t-sql/language-elements/coalesce-transact-sql) for more information on the `COALESCE` function.

To connect to the MSSQL instance, you can provide either:

- `connectionStringFromEnv` - The name of an environment variable containing a valid MSSQL connection string.
Expand Down
2 changes: 2 additions & 0 deletions content/docs/2.11/scalers/mssql.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ The `mssql` trigger always requires the following information:
- `targetValue` - A threshold that is used as `targetValue` or `targetAverageValue` (depending on the trigger metric type) in the Horizontal Pod Autoscaler (HPA). (This value can be a float)
- `activationTargetValue` - Target value for activating the scaler. Learn more about activation [here](./../concepts/scaling-deployments.md#activating-and-scaling-thresholds).(Default: `0`, Optional, This value can be a float)

> Note that the query must return a single integer value. If the query has a possibility of returning `null`, a default value can be set using the `COALESCE` function. For example, `SELECT COALESCE(column_name, 0) FROM table_name;`. See [MSSQL documentation](https://learn.microsoft.com/en-us/sql/t-sql/language-elements/coalesce-transact-sql) for more information on the `COALESCE` function.

To connect to the MSSQL instance, you can provide either:

- `connectionStringFromEnv` - The name of an environment variable containing a valid MSSQL connection string.
Expand Down
2 changes: 2 additions & 0 deletions content/docs/2.12/scalers/mssql.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ The `mssql` trigger always requires the following information:
- `targetValue` - A threshold that is used as `targetValue` or `targetAverageValue` (depending on the trigger metric type) in the Horizontal Pod Autoscaler (HPA). (This value can be a float)
- `activationTargetValue` - Target value for activating the scaler. Learn more about activation [here](./../concepts/scaling-deployments.md#activating-and-scaling-thresholds).(Default: `0`, Optional, This value can be a float)

> Note that the query must return a single integer value. If the query has a possibility of returning `null`, a default value can be set using the `COALESCE` function. For example, `SELECT COALESCE(column_name, 0) FROM table_name;`. See [MSSQL documentation](https://learn.microsoft.com/en-us/sql/t-sql/language-elements/coalesce-transact-sql) for more information on the `COALESCE` function.

To connect to the MSSQL instance, you can provide either:

- `connectionStringFromEnv` - The name of an environment variable containing a valid MSSQL connection string.
Expand Down
2 changes: 2 additions & 0 deletions content/docs/2.13/scalers/mssql.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ The `mssql` trigger always requires the following information:
- `targetValue` - A threshold that is used as `targetValue` or `targetAverageValue` (depending on the trigger metric type) in the Horizontal Pod Autoscaler (HPA). (This value can be a float)
- `activationTargetValue` - Target value for activating the scaler. Learn more about activation [here](./../concepts/scaling-deployments.md#activating-and-scaling-thresholds).(Default: `0`, Optional, This value can be a float)

> Note that the query must return a single integer value. If the query has a possibility of returning `null`, a default value can be set using the `COALESCE` function. For example, `SELECT COALESCE(column_name, 0) FROM table_name;`. See [MSSQL documentation](https://learn.microsoft.com/en-us/sql/t-sql/language-elements/coalesce-transact-sql) for more information on the `COALESCE` function.

To connect to the MSSQL instance, you can provide either:

- `connectionStringFromEnv` - The name of an environment variable containing a valid MSSQL connection string.
Expand Down
2 changes: 2 additions & 0 deletions content/docs/2.14/scalers/mssql.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ The `mssql` trigger always requires the following information:
- `targetValue` - A threshold that is used as `targetValue` or `targetAverageValue` (depending on the trigger metric type) in the Horizontal Pod Autoscaler (HPA). (This value can be a float)
- `activationTargetValue` - Target value for activating the scaler. Learn more about activation [here](./../concepts/scaling-deployments.md#activating-and-scaling-thresholds).(Default: `0`, Optional, This value can be a float)

> Note that the query must return a single integer value. If the query has a possibility of returning `null`, a default value can be set using the `COALESCE` function. For example, `SELECT COALESCE(column_name, 0) FROM table_name;`. See [MSSQL documentation](https://learn.microsoft.com/en-us/sql/t-sql/language-elements/coalesce-transact-sql) for more information on the `COALESCE` function.

To connect to the MSSQL instance, you can provide either:

- `connectionStringFromEnv` - The name of an environment variable containing a valid MSSQL connection string.
Expand Down
2 changes: 2 additions & 0 deletions content/docs/2.15/scalers/mssql.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ The `mssql` trigger always requires the following information:
- `targetValue` - A threshold that is used as `targetValue` or `targetAverageValue` (depending on the trigger metric type) in the Horizontal Pod Autoscaler (HPA). (This value can be a float)
- `activationTargetValue` - Target value for activating the scaler. Learn more about activation [here](./../concepts/scaling-deployments.md#activating-and-scaling-thresholds).(Default: `0`, Optional, This value can be a float)

> Note that the query must return a single integer value. If the query has a possibility of returning `null`, a default value can be set using the `COALESCE` function. For example, `SELECT COALESCE(column_name, 0) FROM table_name;`. See [MSSQL documentation](https://learn.microsoft.com/en-us/sql/t-sql/language-elements/coalesce-transact-sql) for more information on the `COALESCE` function.

To connect to the MSSQL instance, you can provide either:

- `connectionStringFromEnv` - The name of an environment variable containing a valid MSSQL connection string.
Expand Down
2 changes: 2 additions & 0 deletions content/docs/2.2/scalers/mssql.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ The `mssql` trigger always requires the following information:
- `query` - A [T-SQL](https://docs.microsoft.com/sql/t-sql/language-reference) query that returns a single numeric value. This can be a regular query or the name of a stored procedure.
- `targetValue` - A threshold that is used as `targetAverageValue` in the Horizontal Pod Autoscaler (HPA).

> Note that the query must return a single integer value. If the query has a possibility of returning `null`, a default value can be set using the `COALESCE` function. For example, `SELECT COALESCE(column_name, 0) FROM table_name;`. See [MSSQL documentation](https://learn.microsoft.com/en-us/sql/t-sql/language-elements/coalesce-transact-sql) for more information on the `COALESCE` function.

To connect to the MSSQL instance, you can provide either:

- `connectionStringFromEnv` - The name of an environment variable containing a valid MSSQL connection string.
Expand Down
2 changes: 2 additions & 0 deletions content/docs/2.3/scalers/mssql.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ The `mssql` trigger always requires the following information:
- `query` - A [T-SQL](https://docs.microsoft.com/sql/t-sql/language-reference) query that returns a single numeric value. This can be a regular query or the name of a stored procedure.
- `targetValue` - A threshold that is used as `targetAverageValue` in the Horizontal Pod Autoscaler (HPA).

> Note that the query must return a single integer value. If the query has a possibility of returning `null`, a default value can be set using the `COALESCE` function. For example, `SELECT COALESCE(column_name, 0) FROM table_name;`. See [MSSQL documentation](https://learn.microsoft.com/en-us/sql/t-sql/language-elements/coalesce-transact-sql) for more information on the `COALESCE` function.

To connect to the MSSQL instance, you can provide either:

- `connectionStringFromEnv` - The name of an environment variable containing a valid MSSQL connection string.
Expand Down
2 changes: 2 additions & 0 deletions content/docs/2.4/scalers/mssql.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ The `mssql` trigger always requires the following information:
- `query` - A [T-SQL](https://docs.microsoft.com/sql/t-sql/language-reference) query that returns a single numeric value. This can be a regular query or the name of a stored procedure.
- `targetValue` - A threshold that is used as `targetAverageValue` in the Horizontal Pod Autoscaler (HPA).

> Note that the query must return a single integer value. If the query has a possibility of returning `null`, a default value can be set using the `COALESCE` function. For example, `SELECT COALESCE(column_name, 0) FROM table_name;`. See [MSSQL documentation](https://learn.microsoft.com/en-us/sql/t-sql/language-elements/coalesce-transact-sql) for more information on the `COALESCE` function.

To connect to the MSSQL instance, you can provide either:

- `connectionStringFromEnv` - The name of an environment variable containing a valid MSSQL connection string.
Expand Down
2 changes: 2 additions & 0 deletions content/docs/2.5/scalers/mssql.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ The `mssql` trigger always requires the following information:
- `query` - A [T-SQL](https://docs.microsoft.com/sql/t-sql/language-reference) query that returns a single numeric value. This can be a regular query or the name of a stored procedure.
- `targetValue` - A threshold that is used as `targetAverageValue` in the Horizontal Pod Autoscaler (HPA).

> Note that the query must return a single integer value. If the query has a possibility of returning `null`, a default value can be set using the `COALESCE` function. For example, `SELECT COALESCE(column_name, 0) FROM table_name;`. See [MSSQL documentation](https://learn.microsoft.com/en-us/sql/t-sql/language-elements/coalesce-transact-sql) for more information on the `COALESCE` function.

To connect to the MSSQL instance, you can provide either:

- `connectionStringFromEnv` - The name of an environment variable containing a valid MSSQL connection string.
Expand Down
2 changes: 2 additions & 0 deletions content/docs/2.6/scalers/mssql.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ The `mssql` trigger always requires the following information:
- `query` - A [T-SQL](https://docs.microsoft.com/sql/t-sql/language-reference) query that returns a single numeric value. This can be a regular query or the name of a stored procedure.
- `targetValue` - A threshold that is used as `targetAverageValue` in the Horizontal Pod Autoscaler (HPA).

> Note that the query must return a single integer value. If the query has a possibility of returning `null`, a default value can be set using the `COALESCE` function. For example, `SELECT COALESCE(column_name, 0) FROM table_name;`. See [MSSQL documentation](https://learn.microsoft.com/en-us/sql/t-sql/language-elements/coalesce-transact-sql) for more information on the `COALESCE` function.

To connect to the MSSQL instance, you can provide either:

- `connectionStringFromEnv` - The name of an environment variable containing a valid MSSQL connection string.
Expand Down
2 changes: 2 additions & 0 deletions content/docs/2.7/scalers/mssql.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ The `mssql` trigger always requires the following information:
- `query` - A [T-SQL](https://docs.microsoft.com/sql/t-sql/language-reference) query that returns a single numeric value. This can be a regular query or the name of a stored procedure.
- `targetValue` - A threshold that is used as `targetValue` or `targetAverageValue` (depending on the trigger metric type) in the Horizontal Pod Autoscaler (HPA).

> Note that the query must return a single integer value. If the query has a possibility of returning `null`, a default value can be set using the `COALESCE` function. For example, `SELECT COALESCE(column_name, 0) FROM table_name;`. See [MSSQL documentation](https://learn.microsoft.com/en-us/sql/t-sql/language-elements/coalesce-transact-sql) for more information on the `COALESCE` function.

To connect to the MSSQL instance, you can provide either:

- `connectionStringFromEnv` - The name of an environment variable containing a valid MSSQL connection string.
Expand Down
2 changes: 2 additions & 0 deletions content/docs/2.8/scalers/mssql.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ The `mssql` trigger always requires the following information:
- `targetValue` - A threshold that is used as `targetValue` or `targetAverageValue` (depending on the trigger metric type) in the Horizontal Pod Autoscaler (HPA). (This value can be a float)
- `activationTargetValue` - Target value for activating the scaler. Learn more about activation [here](./../concepts/scaling-deployments.md#activating-and-scaling-thresholds).(Default: `0`, Optional, This value can be a float)

> Note that the query must return a single integer value. If the query has a possibility of returning `null`, a default value can be set using the `COALESCE` function. For example, `SELECT COALESCE(column_name, 0) FROM table_name;`. See [MSSQL documentation](https://learn.microsoft.com/en-us/sql/t-sql/language-elements/coalesce-transact-sql) for more information on the `COALESCE` function.

To connect to the MSSQL instance, you can provide either:

- `connectionStringFromEnv` - The name of an environment variable containing a valid MSSQL connection string.
Expand Down
2 changes: 2 additions & 0 deletions content/docs/2.9/scalers/mssql.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ The `mssql` trigger always requires the following information:
- `targetValue` - A threshold that is used as `targetValue` or `targetAverageValue` (depending on the trigger metric type) in the Horizontal Pod Autoscaler (HPA). (This value can be a float)
- `activationTargetValue` - Target value for activating the scaler. Learn more about activation [here](./../concepts/scaling-deployments.md#activating-and-scaling-thresholds).(Default: `0`, Optional, This value can be a float)

> Note that the query must return a single integer value. If the query has a possibility of returning `null`, a default value can be set using the `COALESCE` function. For example, `SELECT COALESCE(column_name, 0) FROM table_name;`. See [MSSQL documentation](https://learn.microsoft.com/en-us/sql/t-sql/language-elements/coalesce-transact-sql) for more information on the `COALESCE` function.

To connect to the MSSQL instance, you can provide either:

- `connectionStringFromEnv` - The name of an environment variable containing a valid MSSQL connection string.
Expand Down