From: Eric Bollengier Date: Thu, 30 Jul 2009 08:17:38 +0000 (+0200) Subject: purge basefiles at the same time than files X-Git-Tag: Release-5.0.0~361 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=05cfd51205c2a7cbaa08f26fea0191f55adb90ed;p=bacula%2Fbacula purge basefiles at the same time than files --- diff --git a/bacula/src/dird/ua_purge.c b/bacula/src/dird/ua_purge.c index ec09f36cdd..f31b577af8 100644 --- a/bacula/src/dird/ua_purge.c +++ b/bacula/src/dird/ua_purge.c @@ -283,6 +283,10 @@ void purge_files_from_jobs(UAContext *ua, char *jobs) db_sql_query(ua->db, query.c_str(), NULL, (void *)NULL); Dmsg1(050, "Delete File sql=%s\n", query.c_str()); + Mmsg(query, "DELETE FROM BaseFiles WHERE JobId IN (%s)", jobs); + db_sql_query(ua->db, query.c_str(), NULL, (void *)NULL); + Dmsg1(050, "Delete BaseFiles sql=%s\n", query.c_str()); + /* * Now mark Job as having files purged. This is necessary to * avoid having too many Jobs to process in future prunings. If