It seems we are using SQLUtils.getSQLDataType for type string in structField.
It looks we can replace this with CatalystSqlParser.parseDataType.
They look similar DDL-like type definitions as below:
Such type strings looks identical when R’s one as below:
It seems R’s one is more stricter because we are checking the types via regular expressions in R side.
Actual logics there look a bit different but as we check it ahead in R side, it looks replacing it would not introduce no behaviour changes.
To make this sure, the tests dedicated for it was added in