Ansible Tower/AWX: Location of job results in PostgreSQL

I'm trying to get STDOUT and STDERR of a specific task from the PostgreSQL database to use it in a commit comment.

I have difficulty with finding the right table. Has anyone tried to get a specific task results, STDOUT and STDERR from Ansible Tower/AWX?

Am I barking at the right tree?


every task has its own output in the column stdout of the table main_jobevent.

prepare awx (text, int) as
select job_id, host_name, modified, playbook, play, role, stdout
  from main_jobevent
 where host_name = ANY (string_to_array($1, ','))
   and changed
 order by modified desc
 limit $2;

execute awx( 'localhost,192.168.1.1', 3 );

this shows the three youngest modifications of the host localhost or 192.168.1.1.