Scripts to split up a PHPMyAdmin dump file into separate .SQL files
Go to file
Steve Dogiakos de451a89f5
Add MIT License to the project
This commit introduces the MIT License to the SQL Dump Splitter project. By including the MIT License, we clearly define the terms under which the project can be freely used, modified, and shared. The license fosters open collaboration and contribution while providing legal clarity and protection for both the contributors and users of the software.
2023-12-30 15:10:46 -07:00
LICENSE Add MIT License to the project 2023-12-30 15:10:46 -07:00
README.md Update README to Include Windows Batch File Details 2023-12-30 14:51:58 -07:00
split_sql_dump.bat Add Windows Batch Script for SQL Dump Splitting 2023-12-30 14:46:25 -07:00
split_sql_dump.py Add SQL dump splitter script 2023-12-30 14:35:12 -07:00

README.md

SQL Dump Splitter

Overview

This project offers tools to split a large SQL dump file into individual files for each database. It includes both a Python script and a Windows batch file to accommodate different user preferences and environments. The tools are designed to efficiently process SQL dumps, identify different databases, and create separate SQL files for each database.

Features

  • Multiple Script Options: Python script for versatility and a Windows batch file for ease of use in Windows environments.
  • Database Identification: Automatically detects different databases within a SQL dump.
  • File Creation: Generates separate SQL files for each database.
  • User-Friendly: Easy to use, catering to both Python and non-Python users.

Getting Started

Prerequisites

  • Python 3.x (for the Python script)
  • Windows OS (for the batch file)

Installation

No additional installation is required for running these scripts, as they use standard libraries and Windows commands.

Usage

Using the Python Script

  1. Place the SQL dump file in the same directory as the script or specify the file path.
  2. Run the script using Python:
    python sql_dump_splitter.py
    

Using the Batch File Ensure the SQL dump file is in the same directory as the batch file.

Simply double-click the batch file or run it in a command prompt:

sql_dump_splitter.bat

Both scripts will create separate SQL files for each database in the dump.

Contributing

Contributions to the SQL Dump Splitter are welcome! Feel free to fork the repository and submit pull requests.