Codota Logo
NonUniqueResultException.<init>
Code IndexAdd Codota to your IDE (free)

How to use
com.enioka.jqm.jdbc.NonUniqueResultException
constructor

Best Java code snippets using com.enioka.jqm.jdbc.NonUniqueResultException.<init> (Showing top 17 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
StringBuilder s =
  • Codota Iconnew StringBuilder()
  • Codota Iconnew StringBuilder(32)
  • Codota IconString str;new StringBuilder(str)
  • Smart code suggestions by Codota
}
origin: enioka/jqm

public static PKI select_key(DbConn cnx, String key)
{
  List<PKI> pp = select(cnx, "pki_select_by_key", key);
  if (pp.size() == 0)
  {
    throw new NoResultException("No PKI with key " + key);
  }
  if (pp.size() > 1)
  {
    throw new NonUniqueResultException("Configuration is not valid");
  }
  return pp.get(0);
}
origin: enioka/jqm

private static JndiObjectResourceDto getUniqueJndiResource(DbConn cnx, String query_key, Object key)
{
  List<JndiObjectResourceDto> res = getJndiObjectResources(cnx, query_key, key);
  if (res.isEmpty())
  {
    throw new NoResultException("The query returned zero rows when one was expected.");
  }
  if (res.size() > 1)
  {
    throw new NonUniqueResultException("The query returned more than one row when one was expected");
  }
  return res.get(0);
}
origin: enioka/jqm

  public static JndiObjectResource select_alias(DbConn cnx, String alias)
  {
    List<JndiObjectResource> res = select(cnx, "jndi_select_by_key", alias);
    if (res.isEmpty())
    {
      throw new NoResultException("no result for query by key for key " + alias);
    }
    if (res.size() > 1)
    {
      throw new NonUniqueResultException("Inconsistent database! Multiple results for query by key for key " + alias);
    }
    return res.get(0);
  }
}
origin: com.enioka.jqm/jqm-model

public static PKI select_key(DbConn cnx, String key)
{
  List<PKI> pp = select(cnx, "pki_select_by_key", key);
  if (pp.size() == 0)
  {
    throw new NoResultException("No PKI with key " + key);
  }
  if (pp.size() > 1)
  {
    throw new NonUniqueResultException("Configuration is not valid");
  }
  return pp.get(0);
}
origin: com.enioka.jqm/jqm-admin

private static JndiObjectResourceDto getUniqueJndiResource(DbConn cnx, String query_key, Object key)
{
  List<JndiObjectResourceDto> res = getJndiObjectResources(cnx, query_key, key);
  if (res.isEmpty())
  {
    throw new NoResultException("The query returned zero rows when one was expected.");
  }
  if (res.size() > 1)
  {
    throw new NonUniqueResultException("The query returned more than one row when one was expected");
  }
  return res.get(0);
}
origin: com.enioka.jqm/jqm-model

  public static RUser selectlogin(DbConn cnx, String id)
  {
    List<RUser> res = select(cnx, "user_select_by_key", id);
    if (res.isEmpty())
    {
      throw new NoResultException("no result for query by key for key " + id);
    }
    if (res.size() > 1)
    {
      throw new NonUniqueResultException("Inconsistent database! Multiple results for query by key for key " + id);
    }
    return res.get(0);
  }
}
origin: com.enioka.jqm/jqm-model

  public static JndiObjectResource select_alias(DbConn cnx, String alias)
  {
    List<JndiObjectResource> res = select(cnx, "jndi_select_by_key", alias);
    if (res.isEmpty())
    {
      throw new NoResultException("no result for query by key for key " + alias);
    }
    if (res.size() > 1)
    {
      throw new NonUniqueResultException("Inconsistent database! Multiple results for query by key for key " + alias);
    }
    return res.get(0);
  }
}
origin: com.enioka.jqm/jqm-model

  public static Node select_single(DbConn cnx, String query_key, Object... args)
  {
    List<Node> nn = select(cnx, query_key, args);
    if (nn.size() == 0)
    {
      throw new NoResultException("No node with this ID");
    }
    if (nn.size() > 1)
    {
      throw new NonUniqueResultException("COnfiguration is broken: multiple nodes with the same ID");
    }
    return nn.get(0);
  }
}
origin: enioka/jqm

  public static Node select_single(DbConn cnx, String query_key, Object... args)
  {
    List<Node> nn = select(cnx, query_key, args);
    if (nn.size() == 0)
    {
      throw new NoResultException("No node with this ID");
    }
    if (nn.size() > 1)
    {
      throw new NonUniqueResultException("COnfiguration is broken: multiple nodes with the same ID");
    }
    return nn.get(0);
  }
}
origin: enioka/jqm

  public static RUser selectlogin(DbConn cnx, String id)
  {
    List<RUser> res = select(cnx, "user_select_by_key", id);
    if (res.isEmpty())
    {
      throw new NoResultException("no result for query by key for key " + id);
    }
    if (res.size() > 1)
    {
      throw new NonUniqueResultException("Inconsistent database! Multiple results for query by key for key " + id);
    }
    return res.get(0);
  }
}
origin: enioka/jqm

throw new NonUniqueResultException("The query returned more than one row when one was expected");
origin: com.enioka.jqm/jqm-admin

private static GlobalParameterDto getGlobalParameter(DbConn cnx, String query_key, Object key)
{
  ResultSet rs = cnx.runSelect(query_key, key);
  try
  {
    if (!rs.next())
    {
      throw new NoResultException("The query returned zero rows when one was expected.");
    }
    GlobalParameterDto res = mapGlobalParameter(rs);
    if (rs.next())
    {
      throw new NonUniqueResultException("The query returned more than one row when one was expected");
    }
    rs.close();
    return res;
  }
  catch (SQLException e)
  {
    throw new JqmAdminApiInternalException("An error occurred while querying the database", e);
  }
}
origin: com.enioka.jqm/jqm-model

throw new NonUniqueResultException("The query returned more than one row when one was expected");
origin: enioka/jqm

private static GlobalParameterDto getGlobalParameter(DbConn cnx, String query_key, Object key)
{
  ResultSet rs = cnx.runSelect(query_key, key);
  try
  {
    if (!rs.next())
    {
      throw new NoResultException("The query returned zero rows when one was expected.");
    }
    GlobalParameterDto res = mapGlobalParameter(rs);
    if (rs.next())
    {
      throw new NonUniqueResultException("The query returned more than one row when one was expected");
    }
    rs.close();
    return res;
  }
  catch (SQLException e)
  {
    throw new JqmAdminApiInternalException("An error occurred while querying the database", e);
  }
}
origin: enioka/jqm

throw new NonUniqueResultException("query was supposed to return a single row - multiple returned");
origin: com.enioka.jqm/jqm-model

throw new NonUniqueResultException("query was supposed to return a single row - multiple returned");
origin: enioka/jqm

throw new NonUniqueResultException("configuration issue: multiple nodes named " + nodeName);
com.enioka.jqm.jdbcNonUniqueResultException<init>

Popular methods of NonUniqueResultException

    Popular in Java

    • Reactive rest calls using spring rest template
    • getContentResolver (Context)
    • setRequestProperty (URLConnection)
      Sets the general request property. If a property with the key already exists, overwrite its value wi
    • notifyDataSetChanged (ArrayAdapter)
    • IOException (java.io)
      Signals that an I/O exception of some sort has occurred. This class is the general class of exceptio
    • Proxy (java.net)
      This class represents proxy server settings. A created instance of Proxy stores a type and an addres
    • UnknownHostException (java.net)
      Thrown when a hostname can not be resolved.
    • Deque (java.util)
      A linear collection that supports element insertion and removal at both ends. The name deque is shor
    • ExecutorService (java.util.concurrent)
      An Executor that provides methods to manage termination and methods that can produce a Future for tr
    • XPath (javax.xml.xpath)
      XPath provides access to the XPath evaluation environment and expressions. Evaluation of XPath Expr
    Codota Logo
    • Products

      Search for Java codeSearch for JavaScript codeEnterprise
    • IDE Plugins

      IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
    • Company

      About UsContact UsCareers
    • Resources

      FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
    Get Codota for your IDE now