A Java library for automatic relationship detection between database tables based on column name and data matching. Ideal for OLTP data where physical relationships may be absent at the RDBMS level. Users can configure column name and data match confidence thresholds to fine-tune results.
The code would be more robust if instead of the current code in isTypeBoolean you simply did the following:
return FTAType.BOOLEAN.equals(result.getType())
If you really wanted to preserve the current functionality (i.e. ignoring fields that are Booleans represented as 0/1) then you could use the following:
return FTAType.BOOLEAN.equals(result.getType()) && Arrays.asList(new String[] { "YES_NO", "Y_N", "TRUE_FALSE" }).contains(result.getTypeModifier());
Making the above change enables you to work in any language not just English.
The code would be more robust if instead of the current code in isTypeBoolean you simply did the following:
return FTAType.BOOLEAN.equals(result.getType())
If you really wanted to preserve the current functionality (i.e. ignoring fields that are Booleans represented as 0/1) then you could use the following:
return FTAType.BOOLEAN.equals(result.getType()) && Arrays.asList(new String[] { "YES_NO", "Y_N", "TRUE_FALSE" }).contains(result.getTypeModifier());
Making the above change enables you to work in any language not just English.