액션 노드들 로직 구현

This commit is contained in:
kjs
2025-10-02 17:51:15 +09:00
parent 37e018b33c
commit 258bd80201
13 changed files with 4504 additions and 525 deletions

View File

@@ -103,15 +103,34 @@ export class OracleConnector implements DatabaseConnector {
try {
const startTime = Date.now();
// 쿼리 타입 확인 (DML인지 SELECT인지)
// 쿼리 타입 확인
const isDML = /^\s*(INSERT|UPDATE|DELETE|MERGE)/i.test(query);
const isCOMMIT = /^\s*COMMIT/i.test(query);
const isROLLBACK = /^\s*ROLLBACK/i.test(query);
// 🔥 COMMIT/ROLLBACK 명령은 직접 실행
if (isCOMMIT || isROLLBACK) {
if (isCOMMIT) {
await this.connection!.commit();
console.log("✅ Oracle COMMIT 실행됨");
} else {
await this.connection!.rollback();
console.log("⚠️ Oracle ROLLBACK 실행됨");
}
return {
rows: [],
rowCount: 0,
fields: [],
affectedRows: 0,
};
}
// Oracle XE 21c 쿼리 실행 옵션
const options: any = {
outFormat: (oracledb as any).OUT_FORMAT_OBJECT, // OBJECT format
maxRows: 10000, // XE 제한 고려
fetchArraySize: 100,
autoCommit: isDML, // ✅ DML 쿼리는 자동 커밋
autoCommit: false, // 🔥 수동으로 COMMIT 제어하도록 변경
};
console.log("Oracle 쿼리 실행:", {