public SqlVerificationSepc(string name, SqlTableSpec tableSpec, string classname, List <SqlFieldMapping> fieldMap) { Name = name; TableSpec = tableSpec; Classname = classname; FieldMap = fieldMap; }
public bool Equals(SqlTableSpec sc) { return (Instance == sc.Instance && Catalog == sc.Catalog && Table == sc.Table && SqlAuthentication == sc.SqlAuthentication && Username == sc.Username && Password == sc.Password); }
public void Test_SqlVerification() { string repository = @"\\JSCHACHTGXY3JC2\DOKuStarDispatchData\Repositories\Standard\SqlVtion.jc15.0000\"; string dataPoolFile = Path.Combine(repository, "20201_o51405_wj5_Rec.data"); DataPool data = new DataPool(); data.Load(dataPoolFile); SqlTableSpec tableSpec = new SqlTableSpec( @"jschachtGXY3JC2\DOKUSTAR", "OCCExport", "CustomerDB", "sa", "#DOKuStar#"); List <SqlFieldMapping> fieldMap = new List <SqlFieldMapping>() { new SqlFieldMapping("Firstname", "Firstname"), new SqlFieldMapping("Lastname", "Lastname"), new SqlFieldMapping("Street", "Street"), }; //ScriptingUtilities.SqlVerification(data, tableSpec, fieldMap, "Confirmation"); // Preparation //ScriptingUtilities.AddSqlVerificationSpec(data, // new SqlVerificationSepc("Test", tableSpec, "DocumentClass", fieldMap)); //ScriptingUtilities.AddSqlVerificationSpec(data, // new SqlVerificationSepc("Test1", tableSpec, "DocumentClass", fieldMap)); //ScriptingUtilities.SqlVerify(data, "Test"); // Execution data.RootNode.Annotations.Add(new Annotation(data, "SU_SqlVerify", "Test")); XmlDocument xmlDoc = data.XmlDocument; ScriptingUtilitiesProfileExtension supe = new ScriptingUtilitiesProfileExtension(); supe.transform(xmlDoc, null); data.Save(Path.Combine(repository, "xx.data")); }