change
This commit is contained in:
parent
c967956212
commit
6538d19603
|
@ -17,6 +17,7 @@ package com.taosdata.jdbc;
|
|||
import java.sql.*;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.concurrent.TimeUnit;
|
||||
|
||||
public class TSDBStatement implements Statement {
|
||||
private TSDBJNIConnector connector = null;
|
||||
|
@ -67,6 +68,12 @@ public class TSDBStatement implements Statement {
|
|||
// TODO make sure it is not a update query
|
||||
pSql = this.connector.executeQuery(sql);
|
||||
|
||||
try {
|
||||
TimeUnit.SECONDS.sleep(10);
|
||||
} catch (InterruptedException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
|
||||
long resultSetPointer = this.connector.getResultSet();
|
||||
|
||||
if (resultSetPointer == TSDBConstants.JNI_CONNECTION_NULL) {
|
||||
|
|
|
@ -31,7 +31,6 @@ public class MultiThreadsWithSameStatmentTest {
|
|||
Thread t1 = new Thread(() -> {
|
||||
try {
|
||||
ResultSet resultSet = stmt.executeQuery("select * from jdbctest.weather");
|
||||
sleep(5000);
|
||||
while (resultSet.next()) {
|
||||
ResultSetMetaData metaData = resultSet.getMetaData();
|
||||
for (int i = 1; i <= metaData.getColumnCount(); i++) {
|
||||
|
|
Loading…
Reference in New Issue