cayenne-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Gentry <blackn...@gmail.com>
Subject Re: Truncating a table
Date Thu, 21 Dec 2017 12:13:51 GMT
Hi Maik,

Raw SQL would certainly be the most efficient way.  Even if you didn't use
raw SQL, though, how were you planning on dealing with Cayenne's caches?  I
think this issue would, regardless of how you truncated the table.  There
are various options, I'm just trying to get a feel for your use can and
thoughts.

Thanks,

mrg


On Thu, Dec 21, 2017 at 5:10 AM, Musall, Maik <maik@selbstdenker.ag> wrote:

> Hi,
>
> I have a lookup table with >400k rows that I want to periodically refill
> from external sources. Since it also contains precomputed values that are
> not part of the external source, my plan is to read the external data and
> batch-insert it all into the table.
>
> How can I truncate the entire table to prepare it for new inserts? The
> only thing that comes to mind is raw SQL, but that would obviously leave
> stale data in Cayenne's various caches.
>
> Thanks
> Maik
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message