Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -179,6 +179,8 @@ public void ModelOperationTest() {
public void callInferenceTest() {
String sql = "CALL INFERENCE(identity, \"select s0,s1,s2 from root.AI.data\")";
String sql2 = "CALL INFERENCE(identity, \"select s2,s0,s1 from root.AI.data\")";
String sql3 =
"CALL INFERENCE(_NaiveForecaster, \"select s0 from root.AI.data\", predict_length=3)";
try (Connection connection = EnvFactory.getEnv().getConnection();
Statement statement = connection.createStatement()) {

Expand Down Expand Up @@ -215,6 +217,17 @@ public void callInferenceTest() {
}
assertEquals(7, count);
}

try (ResultSet resultSet = statement.executeQuery(sql3)) {
ResultSetMetaData resultSetMetaData = resultSet.getMetaData();
checkHeader(resultSetMetaData, "output0,output1,output2");
int count = 0;
while (resultSet.next()) {
count++;
}
assertEquals(3, count);
}

} catch (SQLException e) {
fail(e.getMessage());
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ def fetch_built_in_model(model_id, inference_attributes):
else:
raise BuiltInModelNotSupportError(model_id)

return model, attributes
return model


class Attribute(object):
Expand Down