]> git.sur5r.net Git - bacula/bacula/blobdiff - bacula/src/cats/drop_mysql_tables.in
Properly save RecyclePoolId
[bacula/bacula] / bacula / src / cats / drop_mysql_tables.in
index f828ef0af08cb702be6c73d0feacd9dce26ad829..e291759cbde6bb78708a1a4baae027e3ba363eef 100644 (file)
@@ -3,9 +3,10 @@
 # shell script to delete Bacula tables for MySQL
 
 bindir=@SQL_BINDIR@
+db_name=@db_name@
 
 if $bindir/mysql $* <<END-OF-DATA
-USE bacula;
+USE ${db_name};
 DROP TABLE IF EXISTS Filename;
 DROP TABLE IF EXISTS Path;
 DROP TABLE IF EXISTS LongName;
@@ -28,11 +29,13 @@ DROP TABLE IF EXISTS UnsavedFiles;
 DROP TABLE IF EXISTS CDImages;
 DROP TABLE IF EXISTS Status;
 DROP TABLE IF EXISTS MAC;
+DROP TABLE IF EXISTS Log;
 DROP TABLE IF EXISTS Location;
+DROP TABLE IF EXISTS LocationLog;
 END-OF-DATA
 then
-   echo "Deletion of Bacula MySQL tables succeeded."
+   echo "Deletion of ${db_name} MySQL tables succeeded."
 else
-   echo "Deletion of Bacula MySQL tables failed."
+   echo "Deletion of ${db_name} MySQL tables failed."
 fi
 exit 0