com.github.codemonstur:filldb

A tool for filling a mariadb database with test data

License

License

GroupId

GroupId

com.github.codemonstur
ArtifactId

ArtifactId

filldb
Last Version

Last Version

0.2.1
Release Date

Release Date

Type

Type

jar
Description

Description

com.github.codemonstur:filldb
A tool for filling a mariadb database with test data
Project URL

Project URL

https://github.com/codemonstur/filldb
Source Code Management

Source Code Management

https://github.com/codemonstur/filldb

Download filldb

How to add to project

<!-- https://jarcasting.com/artifacts/com.github.codemonstur/filldb/ -->
<dependency>
    <groupId>com.github.codemonstur</groupId>
    <artifactId>filldb</artifactId>
    <version>0.2.1</version>
</dependency>
// https://jarcasting.com/artifacts/com.github.codemonstur/filldb/
implementation 'com.github.codemonstur:filldb:0.2.1'
// https://jarcasting.com/artifacts/com.github.codemonstur/filldb/
implementation ("com.github.codemonstur:filldb:0.2.1")
'com.github.codemonstur:filldb:jar:0.2.1'
<dependency org="com.github.codemonstur" name="filldb" rev="0.2.1">
  <artifact name="filldb" type="jar" />
</dependency>
@Grapes(
@Grab(group='com.github.codemonstur', module='filldb', version='0.2.1')
)
libraryDependencies += "com.github.codemonstur" % "filldb" % "0.2.1"
[com.github.codemonstur/filldb "0.2.1"]

Dependencies

compile (6)

Group / Artifact Type Version
com.github.codemonstur : jcli jar 0.9.5
org.mariadb.jdbc : mariadb-java-client jar 2.5.1
com.github.mifmif : generex jar 1.0.2
com.thedeanda : lorem jar 2.1
com.squareup.okhttp3 : okhttp jar 4.2.2
org.jsoup : jsoup jar 1.12.1

Project Modules

There are no modules declared in this project.

GitHub Release Build Status Maven Central MIT Licence

A tool for filling a Relational database

I looked around and couldn't find a decent database filling tool. So I wrote one.

This tool only works with MariaDB. Extending it to support other databases should not be hard, but I have no need at the moment. Anyone that would like to implement it can help.

Meant to be used from the command line.

Status

Only one real problem left: Dealing with primary keys that span multiple columns (may or may not fail with the current code)

There is a command line switch that allows you to ignore errors so that the insert won't fail completely.

Current features

  • Schema agnostic, point it to a DB and it will figure things out from there
  • Supports text, varchar, bigint, int and bit columns
  • Can generate test data of various field types: street, city, state, country, email, name, first/middle/last name, hex, phone number, timestamp,
  • Can download various lorum ipsums from generators online
  • Can download various cartoons from webcomics

Future features

There are some listed in src/main/docs/ideas.md. More ideas are welcome. As are bugs, comments and anything else really.

Installation

  1. Check out the code git clone https://github.com/codemonstur/filldb.git
  2. Run make install
  3. You can now run the code with java -jar target/filldb.jar
  4. [Optional] Copy the code to /usr/local/bin
  5. [Optional] Create an alias alias filldb='java -jar /usr/local/bin/filldb.jar'

The code requires Java 11.

Versions

Version
0.2.1
0.2.0
0.1.0