Обсуждение: [JDBC] Spring Transactional Support
Seeing conflicting information and wanted to confirm that the transactional annotation was supported by sping jdbc. Also wanted to see if anyone had attempted to set session variables in postgres before executing a query.
Hi Robert,
Care to elaborate on the question ?
On 10 October 2017 at 20:36, Robert Price <rprice314@yahoo.com> wrote:
Seeing conflicting information and wanted to confirm that the transactional annotation was supported by sping jdbc. Also wanted to see if anyone had attempted to set session variables in postgres before executing a query.
Well I don't think the driver itself has any issue with this, nor does it care about the annotation. This is all hibernate AFAIK ?
On 11 October 2017 at 23:39, Robert Price <rprice314@yahoo.com> wrote:
Yeah I was thinking of using the @transactional annotation to do transactions in postgres and wanted to verify that postgres supported this annotation. Use case would be to set session variables and then use a table filter that referenced the session variables. Requires multiple queries to be run in the same session/transactionOn Wed, Oct 11, 2017 at 11:35 AM, Dave Cramer<pg@fastcrypt.com> wrote:Hi Robert,Care to elaborate on the question ?On 10 October 2017 at 20:36, Robert Price <rprice314@yahoo.com> wrote:Seeing conflicting information and wanted to confirm that the transactional annotation was supported by sping jdbc. Also wanted to see if anyone had attempted to set session variables in postgres before executing a query.
Spring should still do all the work. It doesn't know what driver is underneath it.
On 12 October 2017 at 10:52, Robert Price <rprice314@yahoo.com> wrote:
Ok thanks will give a shot then. It is a spring boot project and we are using jdbc for db queries so not using hibernate.
From: Dave Cramer <pg@fastcrypt.com>
To: "rprice314@yahoo.com" <rprice314@yahoo.com>; List <pgsql-jdbc@postgresql.org>
Sent: Thursday, October 12, 2017 6:33 AM
Subject: Re: [JDBC] Spring Transactional SupportWell I don't think the driver itself has any issue with this, nor does it care about the annotation. This is all hibernate AFAIK ?On 11 October 2017 at 23:39, Robert Price <rprice314@yahoo.com> wrote:Yeah I was thinking of using the @transactional annotation to do transactions in postgres and wanted to verify that postgres supported this annotation. Use case would be to set session variables and then use a table filter that referenced the session variables. Requires multiple queries to be run in the same session/transactionOn Wed, Oct 11, 2017 at 11:35 AM, Dave Cramer<pg@fastcrypt.com> wrote:Hi Robert,Care to elaborate on the question ?On 10 October 2017 at 20:36, Robert Price <rprice314@yahoo.com> wrote:Seeing conflicting information and wanted to confirm that the transactional annotation was supported by sping jdbc. Also wanted to see if anyone had attempted to set session variables in postgres before executing a query.