KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > teamkonzept > webman > mainint > db > queries > content > ContInsert


1 /*
2  * $Header: /cvsroot/webman-cms/source/webman/com/teamkonzept/webman/mainint/db/queries/content/ContInsert.java,v 1.2 2000/12/13 11:25:51 marwan Exp $
3  *
4  */

5 package com.teamkonzept.webman.mainint.db.queries.content;
6
7 import java.sql.*;
8
9 import com.teamkonzept.db.*;
10
11
12 public class ContInsert extends TKPrepQuery{
13
14     public final static boolean isPrepared = true;
15     
16     public final static String JavaDoc[] paramOrder = null;
17     public final static Object JavaDoc[][] paramTypes = null;
18         
19     public final static boolean[] setRelevants = null;
20         
21     public final static String JavaDoc sqlString =
22     /*
23     " INSERT INTO CONTENT (CONTENT_ID) SELECT "+ DBStringFactory.nvl() +"(max(CONTENT_ID) +1,0) FROM CONTENT ";
24     */

25         " INSERT INTO " +
26         " CONTENT " +
27         " (CONTENT_ID)" +
28         " SELECT " + DBStringFactory.nvl() + "(max(CONTENT_ID) + 1,0) FROM CONTENT " ;
29         
30         
31
32         
33
34     public void initQuery(Connection con) {
35         super.initQuery(
36             con,
37             isPrepared,
38             paramOrder,
39             paramTypes,
40             setRelevants,
41             sqlString );
42     }
43 }
44
Popular Tags