I am beginning with HSQLDB, but I hit this issue and can't figure out what's going on:
CREATE TEXT TABLE ozizkaindata (
jobName VARCHAR(255) NOT NULL,
buildNumber VARCHAR(255) NOT NULL,
config VARCHAR(255) NOT NULL,
ar VARCHAR(255) NOT NULL,
arFile VARCHAR(255) NOT NULL,
deployDur VARCHAR(255) NOT NULL,
warmupDur VARCHAR(255) NOT NULL,
scale VARCHAR(255) NOT NULL
)
SELECT *, ((0.0 + warmupDur) / deployDur) AS xwarmupSlower FROM ozizkaindata ORDER BY deployDur
Throws:
Caused by: org.hsqldb.HsqlException: duplicate column name in derived table
at org.hsqldb.error.Error.error(Unknown Source)
at org.hsqldb.error.Error.error(Unknown Source)
at org.hsqldb.QuerySpecification.addSelectColumnExpression(Unknown Source)
at org.hsqldb.ParserDQL.XreadSelect(Unknown Source)
...
SELECT ((0.0 + warmupDur) / deployDur) FROM ozizkaindata ORDER BY deployDur
Throws:
Caused by: java.lang.RuntimeException: unsupported internal operation: Type
at org.hsqldb.error.Error.runtimeError(Unknown Source)
at org.hsqldb.types.Type.divide(Unknown Source)
at org.hsqldb.ExpressionArithmetic.getValue(Unknown Source)
at org.hsqldb.QuerySpecification.buildResult(Unknown Source)
at org.hsqldb.QuerySpecification.getSingleResult(Unknown Source)
at org.hsqldb.QuerySpecification.getResult(Unknown Source)
at org.hsqldb.StatementQuery.getResult(Unknown Source)
SELECT ((0.0 + CAST(warmupDur AS INT)) / CAST(deployDur AS INT)) AS xwarmupSlower FROM ozizkaindata
Throws:
Caused by: org.hsqldb.HsqlException: data exception: invalid character value for cast
at org.hsqldb.error.Error.error(Unknown Source)
at org.hsqldb.error.Error.error(Unknown Source)
at org.hsqldb.Scanner.convertToNumber(Unknown Source)
at org.hsqldb.types.NumberType.convertToType(Unknown Source)
at org.hsqldb.types.Type.castToType(Unknown Source)
at org.hsqldb.ExpressionOp.getValue(Unknown Source)
at org.hsqldb.ExpressionArithmetic.getValue(Unknown Source)
at org.hsqldb.ExpressionArithmetic.getValue(Unknown Source)
at org.hsqldb.QuerySpecification.buildResult(Unknown Source)
at org.hsqldb.QuerySpecification.getSingleResult(Unknown Source)
at org.hsqldb.QuerySpecification.getResult(Unknown Source)