datacap/configure/publish/publish-cleanDatabase.sql

52 lines
1.6 KiB
MySQL
Raw Normal View History

2023-12-22 10:48:20 +08:00
USE `datacap`;
2024-04-19 15:00:53 +08:00
TRUNCATE TABLE `datacap_source_query`;
2023-12-22 10:48:20 +08:00
TRUNCATE TABLE `datacap_chat`;
TRUNCATE TABLE `datacap_chat_user_relation`;
TRUNCATE TABLE `datacap_dashboard`;
TRUNCATE TABLE `datacap_dashboard_report_relation`;
TRUNCATE TABLE `datacap_dashboard_user_relation`;
TRUNCATE TABLE `datacap_dataset`;
TRUNCATE TABLE `datacap_dataset_column`;
TRUNCATE TABLE `datacap_dataset_column_relation`;
TRUNCATE TABLE `datacap_dataset_source_relation`;
TRUNCATE TABLE `datacap_dataset_user_relation`;
2024-01-29 12:22:14 +08:00
TRUNCATE TABLE `datacap_dataset_history`;
TRUNCATE TABLE `datacap_dataset_history_relation`;
2023-12-22 10:48:20 +08:00
TRUNCATE TABLE `datacap_message`;
TRUNCATE TABLE `datacap_message_chat_relation`;
TRUNCATE TABLE `datacap_message_user_relation`;
TRUNCATE TABLE `datacap_metadata_column`;
TRUNCATE TABLE `datacap_metadata_column_table_relation`;
TRUNCATE TABLE `datacap_metadata_database`;
TRUNCATE TABLE `datacap_metadata_database_source_relation`;
TRUNCATE TABLE `datacap_metadata_table`;
TRUNCATE TABLE `datacap_metadata_table_database_relation`;
TRUNCATE TABLE `datacap_pipeline`;
2024-04-19 15:00:53 +08:00
TRUNCATE TABLE `datacap_pipeline_user_relation`;
2023-12-22 10:48:20 +08:00
TRUNCATE TABLE `datacap_report`;
TRUNCATE TABLE `datacap_report_source_relation`;
TRUNCATE TABLE `datacap_report_user_relation`;
2024-01-29 12:22:14 +08:00
TRUNCATE TABLE `datacap_report_dataset_relation`;
2023-12-22 10:48:20 +08:00
TRUNCATE TABLE `datacap_scheduled_history`;
TRUNCATE TABLE `datacap_scheduled_history_relation`;
2024-01-29 12:22:14 +08:00
TRUNCATE TABLE `datacap_scheduled_history_source_relation`;
2023-12-22 10:48:20 +08:00
2024-04-19 15:00:53 +08:00
TRUNCATE TABLE `datacap_user_log`;
2023-12-22 10:48:20 +08:00
2024-01-29 12:22:14 +08:00
TRUNCATE TABLE `datacap_source`;
2023-12-22 10:48:20 +08:00
2024-04-19 15:00:53 +08:00
TRUNCATE TABLE `datacap_snippet`;
2024-04-12 12:41:53 +08:00
2024-04-19 15:00:53 +08:00
mysqldump -u root -p datacap > $(pwd)/configure/schema/datacap.sql