cocoon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From blorit...@apache.org
Subject cvs commit: xml-cocoon2/src/org/apache/cocoon/acting DatabaseAddAction.java
Date Thu, 25 Oct 2001 18:00:11 GMT
bloritsch    01/10/25 11:00:11

  Modified:    src/org/apache/cocoon/acting DatabaseAddAction.java
  Log:
  Optimize critical path
  
  Revision  Changes    Path
  1.14      +3 -2      xml-cocoon2/src/org/apache/cocoon/acting/DatabaseAddAction.java
  
  Index: DatabaseAddAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/org/apache/cocoon/acting/DatabaseAddAction.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -r1.13 -r1.14
  --- DatabaseAddAction.java	2001/10/11 07:28:15	1.13
  +++ DatabaseAddAction.java	2001/10/25 18:00:11	1.14
  @@ -33,7 +33,7 @@
    *
    * @author <a href="mailto:bloritsch@apache.org">Berin Loritsch</a>
    * @author <a href="mailto:balld@apache.org">Donald Ball</a>
  - * @version CVS $Revision: 1.13 $ $Date: 2001/10/11 07:28:15 $
  + * @version CVS $Revision: 1.14 $ $Date: 2001/10/25 18:00:11 $
    */
   public class DatabaseAddAction extends AbstractDatabaseAction implements ThreadSafe {
       protected static final Map addStatements = new HashMap();
  @@ -221,7 +221,8 @@
        */
       int setKey(Configuration table, Configuration key, Connection conn, PreparedStatement
statement, int currentIndex, Request request, String param, Map results) throws ConfigurationException,
SQLException,Exception {
         String mode = key.getAttribute("mode","automatic");
  -      String keyname = "key:"+table.getAttribute("name")+':'+key.getAttribute("dbcol");
  +      String keyname = new StringBuffer("key:").append(table.getAttribute("name"))
  +                           .append(':').append(key.getAttribute("dbcol")).toString();
         if ("manual".equals(mode)) {
           /** Set the key value using SELECT MAX(keyname)+1 **/
           String selectQuery = this.getSelectQuery(key);
  
  
  

----------------------------------------------------------------------
In case of troubles, e-mail:     webmaster@xml.apache.org
To unsubscribe, e-mail:          cocoon-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: cocoon-cvs-help@xml.apache.org


Mime
View raw message