如何以编程方式为DataFlow设置AutoAdjustBufferSize属性?即。
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
<script>
$(document).ready(function(){
// Add smooth scrolling to all links
$("a.arrow").on('click', function(event) {
// Make sure this.hash has a value before overriding default behavior
if (this.hash !== "") {
// Prevent default anchor click behavior
event.preventDefault();
// Store hash
var hash = this.hash;
// Using jQuery's animate() method to add smooth page scroll
// The optional number (800) specifies the number of milliseconds it takes to scroll to the specified area
$('html, body').animate({
scrollTop: $(hash).offset().top -140
}, 800, function(){
// Add hash (#) to URL when done scrolling (default click behavior)
window.location.hash = hash;
});
} // End if
});
});
</script>
答案 0 :(得分:1)
MainPipe仅实现IDTSPipeline100接口。 AutoAdjustBufferSize在IDTSPipeline100接口上不可用,但在IDTSPipeline130接口上可用。因此,您可以执行以下操作之一:
IDTSPipeline130 mp = ((TaskHost)p.Executables.Add("DTS.Pipeline")).InnerObject as IDTSPipeline130;
mp.AutoAdjustBufferSize = true;
OR
MainPipe mp = ((TaskHost)p.Executables.Add("DTS.Pipeline")).InnerObject as MainPipe;
(mp as IDTSPipeline130).AutoAdjustBufferSize = true;
“130”类/接口扩展了一些SSIS功能,但仅适用于SQL Server 2016+;如果添加了Microsoft.SQLServer.DTSPipelineWrap程序集的v4.0_13.0.0.0版本,则可以使用IDTSPipeline130 itnerface