Delete history using API or SQL hi_details hi_actinst hi_varinst

good morning

Normally when I have many instances in my cockpit I stop them all through postman, however the history still remains and I currently have 100gb of history alone.

How can I delete them by select or api?
I’m using camunda 7.18 version tomcat.

I need to clean these tables:
hi_details
hi_actinst
hi_varinst

Hi @pedrosantos4,

For cleanup history it is better to use Batch. for complete info read this link.

But pay attention to HistoryLevel. Cascading cleanup will be worked according to your history level.