返回指定日志序列号(LSN)的cdc.lsn_time_mapping系统表中tran_end_time列中的日期和时间值。 您可以使用此函数系统地将 LSN 范围映射到更改表中的日期范围。 Transact-SQL 语法约定 语法 sys.fn_cdc_map_lsn_to_time ( lsn_value ) 参数 lsn_value ...
对于上限,关系运算符 largest less than or equal to 用于确保范围包括当天的所有条目,包括那些将午夜作为值 tran_end_time。 如果具有不同 LSN 值的多个条目共享 tran_end_time 标识为上限的值,该函数将返回最大的 LSN,确保包含所有条目。 权限 要求公共 角色具有成员身份。 示例 以下示例使用sys...
The lower bound of the time range would be up to but not including midnight of the previous day. The upper bound would be up to and including midnight of the given day. The following example shows how the function sys.fn_cdc_map_time_to_lsn can be used to systematically map this time...
To understand how thesys.fn_cdc_map_time_lsncan be used to map datetime ranges to LSN ranges, consider the following scenario. Assume that a consumer wants to extract change data on a daily basis. That is, the consumer wants only changes for a given day up to and including midnight. Th...
tracking_time Is the datetime value to match against. tracking_time is datetime. Return Type binary(10) Remarks To understand how thesys.fn_cdc_map_time_lsncan be used to map datetime ranges to LSN ranges, consider the following scenario. Assume that a consumer wants to extract change data...
对于上限,关系运算符 largest less than or equal to 用于确保范围包括当天的所有条目,包括那些将午夜作为值 tran_end_time。 如果具有不同 LSN 值的多个条目共享 tran_end_time 标识为上限的值,该函数将返回最大的 LSN,确保包含所有条目。 权限 要求公共 角色具有成员身份。...
对于上限,关系运算符 largest less than or equal to 用于确保范围包括当天的所有条目,包括那些将午夜作为值 tran_end_time。 如果具有不同 LSN 值的多个条目共享 tran_end_time 标识为上限的值,该函数将返回最大的 LSN,确保包含所有条目。 权限 要求公共 角色具有成员身份。 示例 以下示例使用sys.fn_cdc_map_...
对于上限,关系运算符 largest less than or equal to 用于确保范围包括当天的所有条目,包括那些将午夜作为值 tran_end_time。 如果具有不同 LSN 值的多个条目共享 tran_end_time 标识为上限的值,该函数将返回最大的 LSN,确保包含所有条目。 权限 要求公共 角色具有成员身份。 示例 以下示例使用sys.fn_cdc_map_...
00.000'; SELECT @begin_lsn = sys.fn_cdc_map_time_to_lsn('smallest greater than', @begin_time); SELECT @end_lsn = sys.fn_cdc_map_time_to_lsn('largest less than or equal', @end_time); SELECT * FROM cdc.fn_cdc_get_net_changes_HR_Department(@begin_lsn, @end_lsn...
time range would be up to but not including midnight of the previous day. The upper bound would be up to and including midnight of the given day. The following example shows how the functionsys.fn_cdc_map_time_to_lsncan be used to systematically map this time-based range into the LSN-...