MCPcopy Index your code
hub / github.com/ddf-project/DDF / sql

Method sql

core/src/main/java/io/ddf/DDF.java:380–395  ·  view source on GitHub ↗
(String sqlCommand, String errorMessage)

Source from the content-addressed store, hash-verified

378
379 // ///// Execute a sqlcmd
380 public SqlResult sql(String sqlCommand, String errorMessage) throws DDFException {
381 try {
382 // sqlCommand = sqlCommand.replace("@this", this.getTableName());
383 // TODO: what is format?
384 // return this.getManager().sql(String.format(sqlCommand, this.getTableName()));
385 sqlCommand = sqlCommand.replace("@this", "{1}");
386 sqlCommand = String.format(sqlCommand, "{1}");
387 SQLDataSourceDescriptor sqlDS = new SQLDataSourceDescriptor(sqlCommand,
388 null, null, null, this.getUUID().toString());
389 return this.getManager().sql(sqlCommand, null, sqlDS);
390 } catch (DDFException e) {
391 throw e;
392 } catch (Exception e) {
393 throw new DDFException(String.format(errorMessage, this.getTableName()), e);
394 }
395 }
396
397 public SqlTypedResult sqlTyped(String sqlCommand, String errorMessage) throws DDFException {
398 try {

Callers 2

testBasicCopyForS3Method · 0.95
testCopyFromHDFSMethod · 0.95

Calls 5

getUUIDMethod · 0.95
getManagerMethod · 0.95
getTableNameMethod · 0.95
sqlMethod · 0.65
toStringMethod · 0.45

Tested by 2

testBasicCopyForS3Method · 0.76
testCopyFromHDFSMethod · 0.76