Package cx.fbn.nevernote.sql.driver

Examples of cx.fbn.nevernote.sql.driver.NSqlQuery.exec()


        NSqlQuery query = new NSqlQuery(db.getConnection());
               
    check = query.prepare("Select guid "
        +"from "+dbName+" where publishingUri=:uri");
    query.bindValue(":uri", uri);
    check = query.exec();
    if (!check)
      logger.log(logger.EXTREME, "Notebook SQL retrieve guid by uri has failed.");
    if (query.next()) {
      return query.valueString(0);
   
View Full Code Here


        +"from "+dbName+" where guid=:guid");
        else
          check = query.prepare("Select narrow_sort_column "
      +"from "+dbName+" where guid=:guid");
    query.bindValue(":guid", guid);
    check = query.exec();
    if (!check) {
      logger.log(logger.EXTREME, "Notebook SQL retrieve sort order has failed.");
      return -1;
    }
    if (query.next()) {
View Full Code Here

        +"from "+dbName+" where guid=:guid");
        else
          check = query.prepare("Select narrow_sort_order "
      +"from "+dbName+" where guid=:guid");
    query.bindValue(":guid", guid);
    check = query.exec();
    if (!check) {
      logger.log(logger.EXTREME, "Notebook SQL retrieve sort order has failed.");
      return -1;
    }
    if (query.next()) {
View Full Code Here

          check = query.prepare("Update "+dbName+" set narrow_sort_order=:order, narrow_sort_column=:column where guid=:guid");

    query.bindValue(":guid", guid);
    query.bindValue(":order", order);
    query.bindValue(":column", column);
    check = query.exec();
    if (!check)
      logger.log(logger.EXTREME, "Notebook SQL set sort order has failed.");
 
  // Is a notebook a linked notebook?
  public boolean isLinked(String guid) {
View Full Code Here

        NSqlQuery query = new NSqlQuery(db.getConnection());
               
    check = query.prepare("Select guid "
        +"from "+dbName+" where guid=:guid and linked=true");
    query.bindValue(":guid", guid);
    check = query.exec();
    if (!check)
      logger.log(logger.EXTREME, "Notebook SQL isLinked failed.");
    if (query.next()) {
      return true;
   
View Full Code Here

        NSqlQuery query = new NSqlQuery(db.getConnection());              
    check = query.prepare("select distinct tagGuid from noteTags " +
        "where noteGuid in " +
        "(SELECT guid from note where notebookguid=:guid)");
    query.bindValue(":guid", guid);
    check = query.exec();
    if (!check)
      logger.log(logger.EXTREME, "Notebook SQL getValidLinedTags failed.");
    while (query.next()) {
      tags.add(query.valueString(0));
   
View Full Code Here

        NSqlQuery query = new NSqlQuery(db.getConnection());              
    query.prepare("select distinct tagguid from noteTags " +
        "where noteGuid in " +
        "(SELECT guid from note where notebookguid=:guid)");
    query.bindValue(":guid", guid);
    boolean check = query.exec();
    if (!check)
      logger.log(logger.EXTREME, "Notebook SQL getValidLinedTags failed.");
    while(query.next()) {
      db.getTagTable().expungeTag(query.valueString(0), false);
    }
View Full Code Here

   
   
    query.prepare("delete from note " +
        "where notebookguid=:guid");
    query.bindValue(":guid", guid);
    check = query.exec();
    if (!check)
      logger.log(logger.EXTREME, "Notebook SQL getValidLinedTags failed.");

   
    return;
View Full Code Here

    if (local)
      query.bindValue(":local", true);
    else
      query.bindValue(":local", false);
   
    if (!query.exec())
      logger.log(logger.EXTREME, "NotebookTable.convertToLocalNotebook error.");
   
        query.prepare("Update Note set updatesequencenumber=0, isdirty=true"
        +" where notebookguid=:guid");
    query.bindValue(":guid", guid);
View Full Code Here

      logger.log(logger.EXTREME, "NotebookTable.convertToLocalNotebook error.");
   
        query.prepare("Update Note set updatesequencenumber=0, isdirty=true"
        +" where notebookguid=:guid");
    query.bindValue(":guid", guid);
    if (!query.exec())
      logger.log(logger.EXTREME, "NotebookTable.convertToLocalNotebook #2 error.");
     
    return;
   
   
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.