Skip to content

Commit

Permalink
Fixed QC: don't try to check ID patterns, if no pattern is defined (e…
Browse files Browse the repository at this point in the history
….g. when the IDs have a DataSource defined in the Derby file)
  • Loading branch information
egonw committed May 18, 2017
1 parent 05d5fff commit 0def8f7
Showing 1 changed file with 12 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -72,16 +72,19 @@ public void run (File f) throws SQLException, IDMapperException
while (rs.next())
{
String id = rs.getString(1);
DataSource ds = DataSource.getExistingBySystemCode(rs.getString(2));
if (patterns.get(ds) == null) continue; // skip if there is no pattern defined.

Set<DataSource> matches = DataSourcePatterns.getDataSourceMatches(id);
if (!matches.contains(ds))
{
if (missExamples.get(ds).size() < 10) missExamples.put(ds, id);
misses.add (ds);
String syscode = rs.getString(2);
if (DataSource.systemCodeExists(syscode)) {
DataSource ds = DataSource.getExistingBySystemCode(syscode);
if (patterns.get(ds) == null) continue; // skip if there is no pattern defined.

Set<DataSource> matches = DataSourcePatterns.getDataSourceMatches(id);
if (!matches.contains(ds))
{
if (missExamples.get(ds).size() < 10) missExamples.put(ds, id);
misses.add (ds);
}
totals.add (ds);
}
totals.add (ds);
}


Expand Down

0 comments on commit 0def8f7

Please sign in to comment.