How to get Database Messages while executing any query from JAVA : Is it possible to get Database console messages using JDBC after a query is being executed?

select * from staff

[![enter image description here][1]][1]


  [1]: https://i.stack.imgur.com/pw5hy.png