The XML for the TSQQueryCollector needs to add the XMLNS namespace qualifier for this to work:SELECT @paramters = CONVERT(xml, N'<ns:TSQLQueryCollector xmlns:ns="DataCollectorType"> <Query> <Value>SELECT * FROM sys.dm_cdc_log_scan_sessions</Value> <OutputTable>cdc_log_scan_data</OutputTable> </Query> </ns:TSQLQueryCollector>');Thanks, Mark Kromer
↧