01: package com.teamkonzept.webman.mainint.db.queries.presentation;
02:
03: import java.sql.Connection;
04: import com.teamkonzept.db.*;
05:
06: public class UpdateDocumentReference extends TKPrepQuery {
07:
08: public final static boolean PREPARED = true;
09:
10: public final static String[] ORDER = {
11: "PRESENTATION_COMPONENT_IDX", "PRESENTATION_ID" };
12:
13: public final static Object[][] TYPES = null;
14:
15: public final static boolean[] RELEVANTS = { true };
16:
17: public final static String SQLSTRING = (new StringBuffer(
18: "UPDATE DOCUMENT_REFERENCE ")
19: .append(
20: "SET SRC_PRESENTATION_COMPONENT_IDX = SRC_PRESENTATION_COMPONENT_IDX - 1 ")
21: .append("WHERE ")
22: .append(
23: "SRC_PRESENTATION_COMPONENT_IDX > ? AND SRC_SITE_NODE_ID IN ")
24: .append("(SELECT SITE_NODE_ID FROM SITE_DOCUMENT WHERE PRESENTATION_ID = ?)"))
25: .toString();
26:
27: // .append("SRC_PRESENTATION_COMPONENT_IDX > ? AND PRESENTATION_ID = ?")).toString();
28:
29: public void initQuery(Connection con) {
30: super.initQuery(con, PREPARED, ORDER, TYPES, RELEVANTS,
31: SQLSTRING);
32: }
33:
34: }
|