Code

Clean database before fill
authorjanw <janw@594d385d-05f5-0310-b6e9-bd551577e9d8>
Tue, 11 Mar 2008 10:46:32 +0000 (10:46 +0000)
committerjanw <janw@594d385d-05f5-0310-b6e9-bd551577e9d8>
Tue, 11 Mar 2008 10:46:32 +0000 (10:46 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@9668 594d385d-05f5-0310-b6e9-bd551577e9d8

gosa-si/gosa-si-server

index 56b376be716e08c35855bbabf52bd5018f92e056..e99285b80f8f4ef3eec607ed78bd86e73b7e4375 100755 (executable)
@@ -1446,7 +1446,10 @@ sub create_fai_release_db {
                                }
                        }
                        daemon_log("Inserting entries to DB",6);
-                       $fai_server_db->exec_statementlist(\@sql_list);
+                       if(@sql_list) {
+                               unshift @sql_list, "DELETE FROM $table_name";
+                               $fai_server_db->exec_statementlist(\@sql_list);
+                       }
                        daemon_log("Done with inserting",6);
                }
                daemon_log("Done with creating fai_release_db",4);