Yesterday, we experimented with CDC, and there was an error executing the following statement in the database.
EXECsys.sp_cdc_enable_table@source_schema =N'STG', @source_name =N'Cdcsalesorderheader', @role_name =N'Cdc_role', @supports_net_changes = 1; MSG22832, Level -, state1,ProcedureSp_cdc_enable_table_internal, line623Could not UpdateThe metadata that indicatesTable [STG].[Cdcsalesorderheader] isEnabled forChange Data Capture. The failure occurred whenExecuting the command'[SYS]. [Sp_cdc_add_job] @job_type = N'Capture"'. The error returned was22836:'Could not update the metadata for database TK463DW to indicate, a change Data Capture job with been added. The failure occurred when executing the command'Sp_add_jobstep_internal'. The error returned was 14234:'The specified'@server' isInvalid (validValuesis returned bysp_helpserver).'. Use the action and error to determine the cause of the failure and resubmit the request.'. UseThe action andError toDetermine the cause ofThe failure andResubmit the request.
At first, I saw a scheme to change the owner of the database to SA. Invalid after execution.
EXEC ' SA '
According to the following error and check again, only to find that because I changed the computer name, resulting in the database instance name is different.
14234 ' '@server' is invalid (valid values was returned by sp_helpserver)
Process steps:
1. Execute sp_helpserver View the current instance manifest
Exec
2. Add an instance name using sp_addserver
EXEC ' win2k8\sql2k8 '
sp_addserver is obsolete in SQL Server 2012 and needs to be replaced bysp_addlinkedserver
EXEC ' win2k8\sql2k8 ','sql Server'
3. Execute the CDC code again to
Reference documents
#0164-sql Server 2012-discontinued features-sp_addserver-remote server registration-msg:15663
The
SSIS CDC (change Data Capture) component enables error in the database. The error returned was 14234: ' The specified ' @server ' is invalid