The Go-Dumper is a utility designed to facilitate the extraction and dumping of data from a database into CSV files.
Currently, the Go-Dumper supports dumping data from PostgreSQL databases to CSV files.
- Efficient data extraction
- Chunking to reduce memory usage
- Customizable configuration
- Easy to use
To install the Go-Dumper, follow these steps:
- Clone the repository:
git clone https://github.com/realhugn/go-dump.git
- Navigate to the project directory:
cd go-dump
- Build the tool:
go build
To use the Go-Dumper, run the following command:
./go-dump --config /path/to/config.yaml
Replace /path/to/config.yaml
with the path to your configuration file.
Customize the tool by setting the following parameters in a config.yaml
file:
chunk_size: 100000
db_user: changeme
db_password: changeme
db_host: changeme
db_port: changeme
db_name: changeme
tables:
- name: changeme
columns: [] # If not specified, then select all columns
output_dir: changeme
- name: changeme
columns: [] # If not specified, then select all columns
output_dir: changeme
concurrently: true # If true, data will be dumped concurrently. Else, synchronously.
Adjust these values according to your database configuration and requirements.
This project is licensed under the MIT License