Please be aware that the SAP SQL Anywhere Forum will be shut down on August 29th, 2024 when all it's content will be migrated to the SAP Community.

Hi, I have a requirement where I need to read the database log file real time to perform some post processing based on DML and DCL commands, without using any triggers. Is there anyway I can do it. I figured a way to translate the log into readable SQL using dbtran command, but it does not run when ASA server is running, because the log file is locked by the OS. The only way I can extract the sql is when I stop the ASA server. This approach is not acceptable. Is there any other way this can be achieved.

asked 28 Nov '12, 14:15

SWINGER's gravatar image

SWINGER
29234
accept rate: 0%


You can run dbtran against the active log; use the first syntax described here: http://dcx.sybase.com/index.html#1201/en/dbadmin/dbtran.html

permanent link

answered 28 Nov '12, 14:44

Breck%20Carter's gravatar image

Breck Carter
32.5k5417271050
accept rate: 20%

...and you can also use the according DBTools DBTranslateLog() API to do so, in case you prefer to translate the log from within a general programming language such as C/C++.

FWIW, I can't tell how "real-time" this is, e.g. w.r.t. uncommitted transactions...

(28 Nov '12, 18:32) Volker Barth
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×40

question asked: 28 Nov '12, 14:15

question was seen: 2,124 times

last updated: 28 Nov '12, 18:32