Scott, it depends on the db driver. MyBatis will pass both statements
to it
On 2 abr, 05:09, scottk <
[hidden email]> wrote:
> Hi,
> Using against Sqlite which does not support truncate table. To do
> truncate I need to execute both of the following:
>
> DELETE FROM <table>
> DELETE FROM sqlite_sequence WHERE name="<table>"
>
> Is it possible to put multiple statements into a mapper such as:
>
> <delete id="truncate">
> DELETE FROM sqlite_sequence WHERE name="item";
> DELETE FROM item;
> </delete>
>
> MyBatis doesn't complain but it only executes the first statement. I
> know I can create two mappers and execute them sequentially, but was
> hoping for a cleaner solution.
>
> Thank
> Scott