diff --git a/db/routines/vn/procedures/clean.sql b/db/routines/vn/procedures/clean.sql index ed1569935..6552d84cb 100644 --- a/db/routines/vn/procedures/clean.sql +++ b/db/routines/vn/procedures/clean.sql @@ -131,7 +131,8 @@ BEGIN DELETE e FROM entry e - JOIN tEntryToDelete tmp ON tmp.id = e.id; + JOIN tEntryToDelete tmp ON tmp.id = e.id + WHERE e.isBooked = FALSE; -- borrar de route registros menores a 4 aƱos CREATE OR REPLACE TEMPORARY TABLE tRouteToDelete