This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private const string SSIS_AUTO_GENERATED_PARAM_PREFIX = "CM."; | |
private static void DeployIspac(string targetConnectionString, string folderName, string ispacSourcePath) | |
{ | |
using (var targetConn = new SqlConnection(targetConnectionString)) | |
{ | |
IntegrationServices targetIntegrationSvcs = new IntegrationServices(targetConn); | |
Catalog targetCatalog = targetIntegrationSvcs.Catalogs["SSISDB"]; | |
CatalogFolder targetFolder = targetCatalog.Folders.FirstOrDefault(f => f.Name == folderName); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static class StatisticalCalculation | |
{ | |
public static double Trend(IEnumerable<double> knownYValues, IEnumerable<double> knownXValues, double newX) | |
{ | |
var line = LineByLeastSquares(knownYValues, knownXValues); | |
return line.slope * newX + line.intercept; | |
} | |
private static (double slope, double intercept) LineByLeastSquares(IEnumerable<double> knownYValues, IEnumerable<double> knownXValues) | |
{ |