Skip to content

Commit 6929fea

Browse files
author
Christopher McClister
committed
LinkFix: sql-docs-pr (2022-07) - 1
1 parent 30bc584 commit 6929fea

39 files changed

Lines changed: 141 additions & 143 deletions

File tree

docs/relational-databases/security/ledger/ledger-how-to-updatable-ledger-tables.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ This article shows you how to create an [updatable ledger table](ledger-updatabl
1919

2020
## Prerequisites
2121

22-
- [SQL Server Management Studio](/sql/ssms/download-sql-server-management-studio-ssms) or [Azure Data Studio](/sql/azure-data-studio/download-azure-data-studio).
22+
- [SQL Server Management Studio](../../../ssms/download-sql-server-management-studio-ssms.md) or [Azure Data Studio](../../../azure-data-studio/download-azure-data-studio.md).
2323

2424
## Create an updatable ledger table
2525

@@ -33,9 +33,9 @@ We'll create an account balance table with the following schema.
3333
| Balance | decimal (10,2) | Account balance |
3434

3535
> [!IMPORTANT]
36-
> Creating updatable ledger tables requires the **ENABLE LEDGER** permission. For more information on permissions related to ledger tables, see [Permissions](/sql/relational-databases/security/permissions-database-engine#asdbpermissions).
36+
> Creating updatable ledger tables requires the **ENABLE LEDGER** permission. For more information on permissions related to ledger tables, see [Permissions](../permissions-database-engine.md#asdbpermissions).
3737
38-
1. Use [SQL Server Management Studio](/sql/ssms/download-sql-server-management-studio-ssms) or [Azure Data Studio](/sql/azure-data-studio/download-azure-data-studio) to create a new schema and table called `[Account].[Balance]`.
38+
1. Use [SQL Server Management Studio](../../../ssms/download-sql-server-management-studio-ssms.md) or [Azure Data Studio](../../../azure-data-studio/download-azure-data-studio.md) to create a new schema and table called `[Account].[Balance]`.
3939

4040
```sql
4141
CREATE SCHEMA [Account];
@@ -91,7 +91,7 @@ We'll create an account balance table with the following schema.
9191
(4, 'Michaels', 'Mary', 200);
9292
```
9393

94-
1. View the `[Account].[Balance]` updatable ledger table, and specify the [GENERATED ALWAYS](/sql/t-sql/statements/create-table-transact-sql#generate-always-columns) columns added to the table.
94+
1. View the `[Account].[Balance]` updatable ledger table, and specify the [GENERATED ALWAYS](../../../t-sql/statements/create-table-transact-sql.md#generate-always-columns) columns added to the table.
9595

9696
```sql
9797
SELECT [CustomerID]
@@ -147,4 +147,4 @@ We'll create an account balance table with the following schema.
147147
- [Database ledger](ledger-database-ledger.md)
148148
- [Updatable ledger tables](ledger-updatable-ledger-tables.md)
149149
- [Append-only ledger tables](ledger-append-only-ledger-tables.md)
150-
- [How to migrate data from regular tables to ledger tables](ledger-how-to-migrate-data-to-ledger-tables.md)
150+
- [How to migrate data from regular tables to ledger tables](ledger-how-to-migrate-data-to-ledger-tables.md)

docs/relational-databases/security/ledger/ledger-landing-sql-server.yml

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -95,15 +95,15 @@ landingContent:
9595
- linkListType: reference
9696
links:
9797
- text: sys.database_ledger_blocks (Transact-SQL)
98-
url: /sql/relational-databases/system-catalog-views/sys-database-ledger-blocks-transact-sql
98+
url: ../../system-catalog-views/sys-database-ledger-blocks-transact-sql.md
9999
- text: sys.database_ledger_transactions (Transact-SQL)
100-
url: /sql/relational-databases/system-catalog-views/sys-database-ledger-transactions-transact-sql
100+
url: ../../system-catalog-views/sys-database-ledger-transactions-transact-sql.md
101101
- text: sys.database_ledger_digest_locations (Transact-SQL)
102-
url: /sql/relational-databases/system-catalog-views/sys-database-ledger-digest-locations-transact-sql
102+
url: ../../system-catalog-views/sys-database-ledger-digest-locations-transact-sql.md
103103
- text: sys.ledger_table_history (Transact-SQL)
104-
url: /sql/relational-databases/system-catalog-views/sys-ledger-table-history-transact-sql
104+
url: ../../system-catalog-views/sys-ledger-table-history-transact-sql.md
105105
- text: sys.ledger_column_history (Transact-SQL)
106-
url: /sql/relational-databases/system-catalog-views/sys-ledger-column-history-transact-sql
106+
url: ../../system-catalog-views/sys-ledger-column-history-transact-sql.md
107107

108108

109109
# Card
@@ -112,10 +112,10 @@ landingContent:
112112
- linkListType: reference
113113
links:
114114
- text: sys.sp_generate_database_ledger_digest (Transact-SQL)
115-
url: /sql/relational-databases/system-stored-procedures/sys-sp-generate-database-ledger-digest-transact-sql
115+
url: ../../system-stored-procedures/sys-sp-generate-database-ledger-digest-transact-sql.md
116116
- text: sys.sp_verify_database_ledger (Transact-SQL)
117-
url: /sql/relational-databases/system-stored-procedures/sys-sp-verify-database-ledger-transact-sql
117+
url: ../../system-stored-procedures/sys-sp-verify-database-ledger-transact-sql.md
118118
- text: sys.sp_verify_database_ledger_from_digest_storage (Transact-SQL)
119-
url: /sql/relational-databases/system-stored-procedures/sys-sp-verify-database-ledger-from-digest-storage-transact-sql
119+
url: ../../system-stored-procedures/sys-sp-verify-database-ledger-from-digest-storage-transact-sql.md
120120
- text: sys.sp_copy_data_in_batches (Transact-SQL)
121-
url: /sql/relational-databases/system-stored-procedures/sys-sp-copy-data-in-batches-transact-sql
121+
url: ../../system-stored-procedures/sys-sp-copy-data-in-batches-transact-sql.md

docs/relational-databases/security/ledger/ledger-limits.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ Consider the following when working with ledger.
2626
- A [ledger database](ledger-database-ledger.md), a database with the ledger property set to on, can't be converted to a regular database, with the ledger property set to off.
2727
- Automatic generation and storage of database digests is currently available in Azure SQL Database, but not supported on SQL Server.
2828
- Automated digest management with ledger tables by using [Azure Storage immutable blobs](/azure/storage/blobs/immutable-storage-overview) doesn't offer the ability for users to use [locally redundant storage (LRS)](/azure/storage/common/storage-redundancy#locally-redundant-storage) accounts.
29-
- When a ledger database is created, all new tables created by default (without specifying the `APPEND_ONLY = ON` clause) in the database will be [updatable ledger tables](ledger-updatable-ledger-tables.md). To create [append-only ledger tables](ledger-append-only-ledger-tables.md), use the `APPEND_ONLY = ON` clause in the [CREATE TABLE (Transact-SQL)](/sql/t-sql/statements/create-table-transact-sql) statements.
29+
- When a ledger database is created, all new tables created by default (without specifying the `APPEND_ONLY = ON` clause) in the database will be [updatable ledger tables](ledger-updatable-ledger-tables.md). To create [append-only ledger tables](ledger-append-only-ledger-tables.md), use the `APPEND_ONLY = ON` clause in the [CREATE TABLE (Transact-SQL)](../../../t-sql/statements/create-table-transact-sql.md) statements.
3030
- A transaction can update up to 200 ledger tables.
3131

3232
## Ledger table considerations and limitations
@@ -35,7 +35,7 @@ Consider the following when working with ledger.
3535
- After a ledger table is created, it can't be reverted to a table that isn't a ledger table.
3636
- Deleting older data in [append-only ledger tables](ledger-append-only-ledger-tables.md) or the history table of [updatable ledger tables](ledger-updatable-ledger-tables.md) isn't supported.
3737
- `TRUNCATE TABLE` isn't supported.
38-
- When an [updatable ledger table](ledger-updatable-ledger-tables.md) is created, it adds four [GENERATED ALWAYS](/sql/t-sql/statements/create-table-transact-sql#generate-always-columns) columns to the ledger table. An [append-only ledger table](ledger-append-only-ledger-tables.md) adds two columns to the ledger table. These new columns count against the maximum supported number of columns in Azure SQL Database (1,024).
38+
- When an [updatable ledger table](ledger-updatable-ledger-tables.md) is created, it adds four [GENERATED ALWAYS](../../../t-sql/statements/create-table-transact-sql.md#generate-always-columns) columns to the ledger table. An [append-only ledger table](ledger-append-only-ledger-tables.md) adds two columns to the ledger table. These new columns count against the maximum supported number of columns in Azure SQL Database (1,024).
3939
- In-memory tables aren't supported.
4040
- Sparse column sets aren't supported.
4141
- SWITCH IN/OUT partition isn't supported.
@@ -56,7 +56,7 @@ Consider the following when working with ledger.
5656

5757
### Temporal table limitations
5858

59-
Updatable ledger tables are based on the technology of [temporal tables](/sql/relational-databases/tables/temporal-tables) and inherits most of the [limitations](/sql/relational-databases/tables/temporal-table-considerations-and-limitations) but not all of them. Below is a list of limitations that is inherited from temporal tables.
59+
Updatable ledger tables are based on the technology of [temporal tables](../../tables/temporal-tables.md) and inherits most of the [limitations](../../tables/temporal-table-considerations-and-limitations.md) but not all of them. Below is a list of limitations that is inherited from temporal tables.
6060

6161
- If the name of a history table is specified during history table creation, you must specify the schema and table name and also the name of the ledger view.
6262
- By default, the history table is PAGE compressed.
@@ -67,7 +67,7 @@ Updatable ledger tables are based on the technology of [temporal tables](/sql/re
6767
- The history table must be created in the same database as the current table. Temporal querying over Linked Server isn't supported.
6868
- The history table can't have constraints (Primary Key, Foreign Key, table, or column constraints).
6969
- Online option (`WITH (ONLINE = ON`) has no effect on `ALTER TABLE ALTER COLUMN` in case of system-versioned temporal table. `ALTER COLUMN` isn't performed as online regardless of which value was specified for the `ONLINE` option.
70-
- `INSERT` and `UPDATE` statements can't reference the [GENERATED ALWAYS](/sql/t-sql/statements/create-table-transact-sql#generate-always-columns) columns. Attempts to insert values directly into these columns will be blocked.
70+
- `INSERT` and `UPDATE` statements can't reference the [GENERATED ALWAYS](../../../t-sql/statements/create-table-transact-sql.md#generate-always-columns) columns. Attempts to insert values directly into these columns will be blocked.
7171
- `UPDATETEXT` and `WRITETEXT` aren't supported.
7272
- Triggers on the history table aren't allowed.
7373
- Usage of replication technologies is limited:
@@ -89,11 +89,11 @@ Updatable ledger tables are based on the technology of [temporal tables](/sql/re
8989

9090
### Adding columns
9191

92-
Adding nullable columns is supported. Ledger is designed to ignore NULL values when computing the hash of a row version. Based on that, when a nullable column is added, ledger will modify the schema of the ledger and history tables to include the new column, however, this doesn't impact the hashes of existing rows. Adding columns in ledger tables is captured in [sys.ledger_column_history](/sql/relational-databases/system-catalog-views/sys-ledger-column-history-transact-sql).
92+
Adding nullable columns is supported. Ledger is designed to ignore NULL values when computing the hash of a row version. Based on that, when a nullable column is added, ledger will modify the schema of the ledger and history tables to include the new column, however, this doesn't impact the hashes of existing rows. Adding columns in ledger tables is captured in [sys.ledger_column_history](../../system-catalog-views/sys-ledger-column-history-transact-sql.md).
9393

9494
### Dropping columns and tables
9595

96-
Normally, dropping a column or table completely erases the underlying data from the database and is fundamentally incompatible with the ledger functionality that requires data to be immutable. Instead of deleting the data, ledger simply renames the objects being dropped so that they're logically removed from the user schema, but physically remain in the database. Any dropped columns are also hidden from the ledger table schema, so that they're invisible to the user application. However, the data of such dropped objects remains available for the ledger verification process, and allows users to inspect any historical data through the corresponding ledger views. Dropping columns in ledger tables is captured in [sys.ledger_column_history](/sql/relational-databases/system-catalog-views/sys-ledger-column-history-transact-sql). Dropping a ledger table is captured in [sys.ledger_table_history](/sql/relational-databases/system-catalog-views/sys-ledger-table-history-transact-sql). Dropping ledger tables and its dependent objects are marked as dropped in system catalog views and renamed:
96+
Normally, dropping a column or table completely erases the underlying data from the database and is fundamentally incompatible with the ledger functionality that requires data to be immutable. Instead of deleting the data, ledger simply renames the objects being dropped so that they're logically removed from the user schema, but physically remain in the database. Any dropped columns are also hidden from the ledger table schema, so that they're invisible to the user application. However, the data of such dropped objects remains available for the ledger verification process, and allows users to inspect any historical data through the corresponding ledger views. Dropping columns in ledger tables is captured in [sys.ledger_column_history](../../system-catalog-views/sys-ledger-column-history-transact-sql.md). Dropping a ledger table is captured in [sys.ledger_table_history](../../system-catalog-views/sys-ledger-table-history-transact-sql.md). Dropping ledger tables and its dependent objects are marked as dropped in system catalog views and renamed:
9797

9898
- Dropped ledger tables are marked as dropped by setting `is_dropped_ledger_table` in **sys.tables** and renamed using the following format: `MSSQL_DroppedLedgerTable_<dropped_ledger_table_name>_<GUID>`.
9999
- Dropped history tables for updatable ledger tables are renamed using the following format: `MSSQL_DroppedLedgerHistory_<dropped_history_table_name>_<GUID>`.
@@ -114,4 +114,4 @@ However, any operations that might affect the format of existing data, such as c
114114
- [Ledger overview](ledger-overview.md)
115115
- [Updatable ledger tables](ledger-updatable-ledger-tables.md)
116116
- [Append-only ledger tables](ledger-append-only-ledger-tables.md)
117-
- [Database ledger](ledger-database-ledger.md)
117+
- [Database ledger](ledger-database-ledger.md)

0 commit comments

Comments
 (0)