> For the complete documentation index, see [llms.txt](https://docs.tibero.com/prosync/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.tibero.com/prosync/administration/apply/key-features/history/dml-history.md).

# DML History

&#x20;APPLY 프로세스에서 DML 반영 시 MAP 파라미터로 지정한 History 테이블에 반영된 history 를 남기는 기능이다.&#x20;

&#x20;해당 기능을 사용하기 위해서는 기존 ProSync 동기화를 진행하는 인스턴스 이외에 DML History 기능 작동을 위한 인스턴스가 추가로 하나 더 필요하다.

{% hint style="info" %}
**참고**

다음의 타입들에 대해선 이 기능을 제공하지 않는다.&#x20;

아래의 타입이 있는 테이블의 경우에는 컬럼의 값이 NULL로 기록된다.

* LONG
* BLOB
* CLOB
  {% endhint %}

&#x20;APPLY 프로세스의 config 파일인 \[*inst\_id*]\_apply1.cfg 파일에 다음의 파라미터를 설정해야 한다.

<table><thead><tr><th width="188">Parameter</th><th>설명</th></tr></thead><tbody><tr><td>RECORD_HISTORY</td><td><p>해당  인스턴스에서 DML history 기능을 사용 할 지에 대한 여부를 결정한다. (Y|N)</p><ul><li> Y : MAP RULE 로 지정된 history 테이블에 row by row로 DML이 남게 된다.</li><li>N : MAP RULE 로 지정된 history 테이블에 row by row로 DML이 남지 않는다. (기본값)</li></ul><p>해당 파라미터를 Y 로 설정할 경우, MAP 파라미터를 history 를 남길 테이블로 설정해 주어야 하며, DDL 파라미터의 경우 exclude all 로 설정해 주어야 한다.</p></td></tr><tr><td>LEADING_PRS_USER</td><td><p>DML history 기능에 의해서 history를 기록할 선행되는 PRS_USER를 설정하는 파라미터이다.<br></p><p> 선행되는 인스턴스에 동기화가 이루어져야 DML history가 남게 된다. 3초씩 10번 총 30초 동안 바라보며, 그 안에 동기화가 이루어지지 않을 경우 history는 남지 않는다.</p></td></tr></tbody></table>

추가적으로 동기화 대상 테이블에 추가적인 column들이 필요하다.

<table><thead><tr><th width="127">column</th><th>설명</th></tr></thead><tbody><tr><td>OLD_{컬럼 명}</td><td>해당 column의 경우 UPDATE, DELETE 같은 column의 값이 변경 될 때의 값이 남게 된다. 따라서 기존 컬럼과 똑같은 타입으로 설정해 주어야 한다.</td></tr><tr><td>HIST_NO</td><td>NUMBER 이며, 순차 채번을 위한 column이다.<br>Target DB SYS User 에 SQ_{HISTORY_TABLE} 의 이름을 가진 sequence의 생성이 필요하다. 이 때 Sequence table 은 MIN 1 MAX 99999999 을 가지며, cycle 로 순환되어야 한다.</td></tr><tr><td>IUD_FLAG</td><td>VARCHAR(6) 이며, History 가 남을 DML 의 유형을 뜻하는 column이다. INSERT / UPDATE / DELETE가 남는다.</td></tr><tr><td>IUD_TIME</td><td>TIMESTAMP 이며, DML 이 수행 되어 history 가 남은 시간을 뜻한다.</td></tr></tbody></table>

###


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.tibero.com/prosync/administration/apply/key-features/history/dml-history.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
