Batching

classic Classic list List threaded Threaded
2 messages Options
PK
Reply | Threaded
Open this post in threaded view
|

Batching

PK
We are in process of moving one of our existing application from IBTAIS to MYBATIS.

I'm not sure if i'm missing out on something but in IBATIS developer could control execution of batch by calling startBatch/executeBatch on sqlmapsession but with MYBATIS we need to specify at the time of opening a session if we want to be in batch or not. 

JDBC does not allow select queries to be in batch and we need a way to run a select query as a part of an ongoing transaction that could be in BATCH, just wondering of there is a way to accomplish the same. 

Thanks!




--
You received this message because you are subscribed to the Google Groups "mybatis-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/mybatis-user/2aebb870-0f71-4a2d-bab1-370cc82111bf%40googlegroups.com.
Reply | Threaded
Open this post in threaded view
|

Re: Batching

Iwao AVE!
Hello,

I'm sorry for a super late reply.
Have you already gotten your answer?

It should be possible to execute SELECT in a session with BATCH executor, but it will implicitly 'flush' the batched statements.
If you have any difficulty, please post the details with relevant code (a small repro project is the best).

Regards,
Iwao

On Fri, Nov 1, 2019 at 4:06 AM PK <[hidden email]> wrote:
We are in process of moving one of our existing application from IBTAIS to MYBATIS.

I'm not sure if i'm missing out on something but in IBATIS developer could control execution of batch by calling startBatch/executeBatch on sqlmapsession but with MYBATIS we need to specify at the time of opening a session if we want to be in batch or not. 

JDBC does not allow select queries to be in batch and we need a way to run a select query as a part of an ongoing transaction that could be in BATCH, just wondering of there is a way to accomplish the same. 

Thanks!




--
You received this message because you are subscribed to the Google Groups "mybatis-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/mybatis-user/2aebb870-0f71-4a2d-bab1-370cc82111bf%40googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "mybatis-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/mybatis-user/CA%2Buep2TEGF9TkGMTC5PUHGUqCd08QpGJJEyyM6ng_q2EHFrwWw%40mail.gmail.com.