| От | Thomas Kellerer |
|---|---|
| Тема | Re: How to get RAISE INFO in JDBC |
| Дата | |
| Msg-id | 1c83d660-79ce-efb3-3dd5-fa968d98f9f6@gmx.net обсуждение исходный текст |
| Ответ на | How to get RAISE INFO in JDBC (Ravi Krishna <srkrishna@outlook.com>) |
| Список | pgsql-general |
Ravi Krishna schrieb am 20.03.2020 um 15:48: > How do we get the notification mentioned in RAISE INFO of PL/PGSQL in JDBC. > I can get it in psql, but not in JDBC. > > I am talking about redshift which has the same procedural language like postgres. I can only answer this for Postgres. As Redhisft has its own JDBC driver, I don't know if this applies to that as well: All messages from a RAISE are reported as SQL Warnings on the Statement instance that you used. So you can use Statement.getWarnings() to retrieve the RAISE output. Note, that you need a loop that checks SQLWarning.getNextWarning() to find out if there was more than one RAISE Thomas
В списке pgsql-general по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера