Written by

Senior Cloud Architect at InterSystems
Question Eduard Lebedyuk · Apr 25, 2021

messages.log/cconsole.log in SQL?

Do we have messages.log/cconsole.log projection in SQL?

I was sure we do, but unable to find it.

Comments

Robert Cemper · Apr 25, 2021

try:

;
set file=$system.Util.ManagerDirectory()_"messages.log"
open file:("RS"):1 w $T  open 2:99
try { for n=1:1 use file read lin use 2 write lin,! } catch { close 2,file  write n_" lines",! }
;

then use ^SPOOL mapping (OEX) to work on it with SQL

0
Eduard Lebedyuk  May 2, 2021 to Dmitry Maslennikov

I want to get logs in a structured way.

0
Lorenzo Scalese  May 3, 2021 to Eduard Lebedyuk

Hi @Eduard Lebedyuk,

How about a custom class query (that read cconsole\messages.log) to solve your problem. ?
(Robert's solution would be faster to code.)

0
Hao Ma · Aug 23, 2022

I believe new iris release has structured message log. forget since which release.

0