Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
03/15/12 17:51:45 (13 years ago)
Author:
mkommend
Message:

#1734: merged changes in data importer from the heureka rep

Location:
branches/HeuristicLab.DataImporter/HeuristicLab.DataImporter.Command
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • branches/HeuristicLab.DataImporter/HeuristicLab.DataImporter.Command/Aggregation/AggregateCommandBase.cs

    r7267 r7625  
    7474    public override void Execute() {
    7575      base.Execute();
     76      if (!ColumnGroup.Columns.Any()) return;
    7677      if (!ColumnGroup.Sorted)
    7778        throw new CommandExecutionException("ColumnGroup must be sorted to use aggregation commands.", this);
  • branches/HeuristicLab.DataImporter/HeuristicLab.DataImporter.Command/Aggregation/DeleteRowsWithDuplicateKeyValuesCommand.cs

    r7267 r7625  
    5050    public override void Execute() {
    5151      base.Execute();
     52      if (!ColumnGroup.Columns.Any()) return;
    5253      if (!ColumnGroup.Sorted)
    5354        throw new CommandExecutionException("ColumnGroup must be sorted to delete rows with duplicate key.", this);
  • branches/HeuristicLab.DataImporter/HeuristicLab.DataImporter.Command/ChangeDataset/AlignColumnGroupsCommand.cs

    r7267 r7625  
    5656      this.removePos2 = this.DataSet.IndexOfColumnGroup(oldColumnGroup2);
    5757
     58      if (!oldColumnGroup1.Columns.Any() || !oldColumnGroup2.Columns.Any()) return;
     59
    5860      if (oldColumnGroup1.SortedColumnsCount < 1 || oldColumnGroup1.SortedColumnsCount != oldColumnGroup2.SortedColumnsCount)
    5961        throw new CommandExecutionException("Both ColumnGroups must be sorted by at least one column and must be sorted by the same number of columns.", this);
     
    6466        if (this.oldColumnGroup1.Columns.ElementAt(oldColumnGroup1.SortedColumnIndexes.ElementAt(i)).DataType !=
    6567            this.oldColumnGroup2.Columns.ElementAt(oldColumnGroup2.SortedColumnIndexes.ElementAt(i)).DataType)
    66           throw new CommandExecutionException("Both ColumnGroups must be sorted by columns of the same type",this);
     68          throw new CommandExecutionException("Both ColumnGroups must be sorted by columns of the same type", this);
    6769      }
    6870
Note: See TracChangeset for help on using the changeset viewer.