Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
05/28/13 10:30:43 (11 years ago)
Author:
pfleck
Message:

#2063:
As suggested by gkronber, added user to primary key again in ClientFact table and added a 'NULL'-user in the DimUser table instead.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/HiveStatistics/sources/HeuristicLab.Services.Hive/3.3/HiveStatisticsGenerator.cs

    r9545 r9546  
    9292
    9393      db.DimUsers.InsertAllOnSubmit(newDimUsers);
     94
     95      // insert NULL-User
     96      if (!db.DimUsers.Any(x => x.UserId == Guid.Empty)) {
     97        db.DimUsers.InsertOnSubmit(new DimUser { UserId = Guid.Empty, Name = "NULL" });
     98      }
    9499    }
    95100
     
    168173          DimClient = s.Client,
    169174          DimTime = newTime,
    170           UserId = s.Slave.OwnerUserId,
     175          UserId = s.Slave.OwnerUserId ?? Guid.Empty,
    171176          NumUsedCores =
    172177            s.Slave.Cores != null && s.Slave.FreeCores != null
Note: See TracChangeset for help on using the changeset viewer.