Be slightly more tolerant of weird spreadsheet data

git-svn-id: http://google-refine.googlecode.com/svn/trunk@2501 7d457c2a-affb-35e4-300a-418c747d4874
This commit is contained in:
Tom Morris 2012-06-02 21:00:30 +00:00
parent 07ed203ddd
commit a0812c5751

View File

@ -204,6 +204,13 @@ public class OdsImporter extends TabularImportingParserBase {
value = cell.getPercentageValue(); value = cell.getPercentageValue();
} else if ("string".equals(cellType)) { } else if ("string".equals(cellType)) {
value = cell.getStringValue(); value = cell.getStringValue();
} else if (cellType == null) {
value = cell.getDisplayText();
if ("".equals(value)) {
value = null;
} else {
logger.info("Null cell type with non-empty value: " + value);
}
} else { } else {
logger.info("Unexpected cell type " + cellType); logger.info("Unexpected cell type " + cellType);
value = cell.getDisplayText(); value = cell.getDisplayText();