mirror of
https://github.com/dbeaver/cloudbeaver.git
synced 2026-09-24 16:04:36 +08:00
CB-1708 add parseQuery function
This commit is contained in:
@@ -243,7 +243,7 @@ extend type Query {
|
||||
|
||||
sqlParseQuery(
|
||||
connectionId: ID!,
|
||||
script: String!
|
||||
script: String!,
|
||||
position: Int!
|
||||
): SQLScriptQuery!
|
||||
}
|
||||
|
||||
+1
-1
@@ -132,5 +132,5 @@ public interface DBWServiceSQL extends DBWService {
|
||||
WebSQLScriptInfo parseSqlScript(@NotNull WebConnectionInfo connectionInfo, @NotNull String sqlScript) throws DBWebException;
|
||||
|
||||
@WebAction
|
||||
WebSQLQueryInfo parseSqlQuery(@NotNull WebConnectionInfo connectionInfo, @NotNull String sqlScript, int currentPosition) throws DBWebException;
|
||||
WebSQLQueryInfo parseSqlQuery(@NotNull WebConnectionInfo connectionInfo, @NotNull String sqlScript, int cursorPosition) throws DBWebException;
|
||||
}
|
||||
|
||||
+1
@@ -438,6 +438,7 @@ public class WebServiceSQL implements DBWServiceSQL {
|
||||
.collect(Collectors.toList());
|
||||
return new WebSQLScriptInfo(queriesInfo);
|
||||
}
|
||||
|
||||
@Override
|
||||
public WebSQLQueryInfo parseSqlQuery(@NotNull WebConnectionInfo connectionInfo, @NotNull String sqlScript, int cursorPosition) throws DBWebException {
|
||||
SQLDialect dialect = getSqlDialectFromConnection(connectionInfo.getDataSourceContainer());
|
||||
|
||||
@@ -1,13 +0,0 @@
|
||||
query parseSQLQuery(
|
||||
$connectionId: ID!
|
||||
$script: String!
|
||||
$position: Int!
|
||||
) {
|
||||
scriptInfo: sqlParseQuery(
|
||||
connectionId: $connectionId
|
||||
script: $script
|
||||
position: $position
|
||||
) {
|
||||
...SQLQueryInfo
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user