Package org.openrdf.sail.rdbms.evaluation

Examples of org.openrdf.sail.rdbms.evaluation.SqlQueryBuilder.select()


    query.select().append(
        "CASE WHEN su.value IS NOT NULL THEN su.value WHEN slu.value IS NOT NULL THEN slu.value ELSE sb.value END");
    query.select().column("pu", "id");
    query.select().column("pu", "value");
    query.select().column("t", "obj");
    query.select().append(
        "CASE WHEN ou.value IS NOT NULL THEN ou.value" + " WHEN olu.value IS NOT NULL THEN olu.value"
            + " WHEN ob.value IS NOT NULL THEN ob.value"
            + " WHEN ol.value IS NOT NULL THEN ol.value ELSE oll.value END");
    query.select().column("od", "value");
    query.select().column("og", "value");
View Full Code Here


    query.select().column("t", "obj");
    query.select().append(
        "CASE WHEN ou.value IS NOT NULL THEN ou.value" + " WHEN olu.value IS NOT NULL THEN olu.value"
            + " WHEN ob.value IS NOT NULL THEN ob.value"
            + " WHEN ol.value IS NOT NULL THEN ol.value ELSE oll.value END");
    query.select().column("od", "value");
    query.select().column("og", "value");
    SqlJoinBuilder join;
    if (pred != null) {
      join = query.from(uris.getShortTableName(), "pu");
      // TODO what about long predicate URIs?
View Full Code Here

    query.select().append(
        "CASE WHEN ou.value IS NOT NULL THEN ou.value" + " WHEN olu.value IS NOT NULL THEN olu.value"
            + " WHEN ob.value IS NOT NULL THEN ob.value"
            + " WHEN ol.value IS NOT NULL THEN ol.value ELSE oll.value END");
    query.select().column("od", "value");
    query.select().column("og", "value");
    SqlJoinBuilder join;
    if (pred != null) {
      join = query.from(uris.getShortTableName(), "pu");
      // TODO what about long predicate URIs?
      join = join.join(tableName, "t");
View Full Code Here

  private String buildContextQuery() throws SQLException {
    if (statements.isEmpty())
      return null;
    String tableName = statements.getCombinedTableName();
    SqlQueryBuilder query = factory.createSqlQueryBuilder();
    query.select().column("t", "ctx");
    query
        .select()
        .append(
            "CASE WHEN MIN(u.value) IS NOT NULL THEN MIN(u.value) ELSE MIN(b.value) END");
    SqlJoinBuilder join = query.from(tableName, "t");
View Full Code Here

    if (statements.isEmpty())
      return null;
    String tableName = statements.getCombinedTableName();
    SqlQueryBuilder query = factory.createSqlQueryBuilder();
    query.select().column("t", "ctx");
    query
        .select()
        .append(
            "CASE WHEN MIN(u.value) IS NOT NULL THEN MIN(u.value) ELSE MIN(b.value) END");
    SqlJoinBuilder join = query.from(tableName, "t");
    join.leftjoin(bnodes.getName(), "b").on("id", "t.ctx");
View Full Code Here

    if (obj != null)
      objId = vf.getInternalId(obj);
   
    String tableName = statements.getTableName(vf.getInternalId(pred), subjId, objId, ctxIds);
    SqlQueryBuilder query = factory.createSqlQueryBuilder();
    query.select().column("t", "ctx");
    query.select().append("CASE WHEN cu.value IS NOT NULL THEN cu.value WHEN clu.value IS NOT NULL THEN clu.value ELSE cb.value END");
    query.select().column("t", "subj");
    query.select().append("CASE WHEN su.value IS NOT NULL THEN su.value WHEN slu.value IS NOT NULL THEN slu.value ELSE sb.value END");
    query.select().column("pu", "id");
    query.select().column("pu", "value");
View Full Code Here

      objId = vf.getInternalId(obj);
   
    String tableName = statements.getTableName(vf.getInternalId(pred), subjId, objId, ctxIds);
    SqlQueryBuilder query = factory.createSqlQueryBuilder();
    query.select().column("t", "ctx");
    query.select().append("CASE WHEN cu.value IS NOT NULL THEN cu.value WHEN clu.value IS NOT NULL THEN clu.value ELSE cb.value END");
    query.select().column("t", "subj");
    query.select().append("CASE WHEN su.value IS NOT NULL THEN su.value WHEN slu.value IS NOT NULL THEN slu.value ELSE sb.value END");
    query.select().column("pu", "id");
    query.select().column("pu", "value");
    query.select().column("t", "obj");
View Full Code Here

   
    String tableName = statements.getTableName(vf.getInternalId(pred), subjId, objId, ctxIds);
    SqlQueryBuilder query = factory.createSqlQueryBuilder();
    query.select().column("t", "ctx");
    query.select().append("CASE WHEN cu.value IS NOT NULL THEN cu.value WHEN clu.value IS NOT NULL THEN clu.value ELSE cb.value END");
    query.select().column("t", "subj");
    query.select().append("CASE WHEN su.value IS NOT NULL THEN su.value WHEN slu.value IS NOT NULL THEN slu.value ELSE sb.value END");
    query.select().column("pu", "id");
    query.select().column("pu", "value");
    query.select().column("t", "obj");
    query.select().append("CASE WHEN ou.value IS NOT NULL THEN ou.value" +
View Full Code Here

    String tableName = statements.getTableName(vf.getInternalId(pred), subjId, objId, ctxIds);
    SqlQueryBuilder query = factory.createSqlQueryBuilder();
    query.select().column("t", "ctx");
    query.select().append("CASE WHEN cu.value IS NOT NULL THEN cu.value WHEN clu.value IS NOT NULL THEN clu.value ELSE cb.value END");
    query.select().column("t", "subj");
    query.select().append("CASE WHEN su.value IS NOT NULL THEN su.value WHEN slu.value IS NOT NULL THEN slu.value ELSE sb.value END");
    query.select().column("pu", "id");
    query.select().column("pu", "value");
    query.select().column("t", "obj");
    query.select().append("CASE WHEN ou.value IS NOT NULL THEN ou.value" +
        " WHEN olu.value IS NOT NULL THEN olu.value" +
View Full Code Here

    SqlQueryBuilder query = factory.createSqlQueryBuilder();
    query.select().column("t", "ctx");
    query.select().append("CASE WHEN cu.value IS NOT NULL THEN cu.value WHEN clu.value IS NOT NULL THEN clu.value ELSE cb.value END");
    query.select().column("t", "subj");
    query.select().append("CASE WHEN su.value IS NOT NULL THEN su.value WHEN slu.value IS NOT NULL THEN slu.value ELSE sb.value END");
    query.select().column("pu", "id");
    query.select().column("pu", "value");
    query.select().column("t", "obj");
    query.select().append("CASE WHEN ou.value IS NOT NULL THEN ou.value" +
        " WHEN olu.value IS NOT NULL THEN olu.value" +
        " WHEN ob.value IS NOT NULL THEN ob.value" +
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.