{"name":"fake2db: Generate Custom Test Databases with Fake Data","description":"fake2db is a powerful Python utility designed to create custom test databases populated with fake, yet valid, data. It supports a wide array of popular database systems, including SQLite, MySQL, PostgreSQL, MongoDB, Redis, and CouchDB. This tool is ideal for developers and testers needing quick, realistic data for testing and development environments.","github":"https://github.com/emirozer/fake2db","url":"https://osrepos.com/repo/emirozer-fake2db","source":"osrepos.com","sourceDescription":"This repository profile is provided by osrepos.com, an open source repository discovery platform.","repositoryProfile":"https://osrepos.com/repo/emirozer-fake2db","generatedFor":"open source discovery and AI-assisted research","markdown":"https://osrepos.com/repo/emirozer-fake2db.md","json":"https://osrepos.com/repo/emirozer-fake2db.json","topics":["Python","Database","Fake Data","Testing","Development","Faker","Data Generation"],"keywords":["Python","Database","Fake Data","Testing","Development","Faker","Data Generation"],"stars":null,"summary":"fake2db is a powerful Python utility designed to create custom test databases populated with fake, yet valid, data. It supports a wide array of popular database systems, including SQLite, MySQL, PostgreSQL, MongoDB, Redis, and CouchDB. This tool is ideal for developers and testers needing quick, realistic data for testing and development environments.","content":"## Introduction\n\n`fake2db` is a powerful Python utility that simplifies the process of generating custom test databases populated with fake, yet valid, data. It's an invaluable tool for developers and testers who need to quickly set up realistic data environments without manual input. The tool supports a wide array of popular database systems, including SQLite, MySQL, PostgreSQL, MongoDB, Redis, and CouchDB, making it versatile for various project needs.\n\n## Installation\n\nInstallation is straightforward using pip:\n\nbash\npip install fake2db\n\n\nFor specific database support, additional packages are required:\n\n*   **PostgreSQL:**\n    bash\npip install psycopg2\n    \n    You might need `pg_config` on your system. For Mac, `brew install postgresql`. For CentOS, `sudo yum install postgresql-devel`.\n\n*   **MongoDB:**\n    bash\npip install pymongo\n    \n\n*   **Redis:**\n    bash\npip install redis\n    \n\n*   **MySQL:**\n    Requires MySQL Connector/Python, available at [http://dev.mysql.com/downloads/connector/python/](http://dev.mysql.com/downloads/connector/python/){:target=\"_blank\"}.\n\n*   **CouchDB:**\n    bash\npip install couchdb\n    \n\n## Examples\n\n`fake2db` offers flexible command-line arguments for generating data.\n\n*   **Basic SQLite database with 200 rows:**\n    bash\nfake2db --rows 200 --db sqlite\n    \n\n*   **PostgreSQL database with 1500 rows and a custom name:**\n    bash\nfake2db --rows 1500 --db postgresql --name test_database_postgre\n    \n\n*   **PostgreSQL with host, password, and user:**\n    bash\nfake2db --db postgresql --rows 2500 --host container.local --password password --user docker\n    \n\n*   **Custom database generation with specific columns (e.g., name, date, country):**\n    bash\nfake2db.py --rows 250 --db mysql --username mysql --password somepassword --custom name date country\n    \n\n*   **Generating data with a specific locale and seed for reproducibility:**\n    bash\nfake2db --rows 200 --db sqlite --locale cs_CZ --seed 1337\n    \n\n## Why Use It\n\n`fake2db` addresses a common challenge in software development: the need for realistic, yet disposable, data for testing, prototyping, and demonstration purposes. Instead of manually creating data or relying on sensitive production data, `fake2db` allows developers to quickly spin up databases with diverse, fake content. This ensures robust testing, accelerates development cycles, and maintains data privacy. Its support for multiple database types makes it a versatile asset in any developer's toolkit.\n\n## Links\n\n*   GitHub Repository: [https://github.com/emirozer/fake2db](https://github.com/emirozer/fake2db){:target=\"_blank\"}","metrics":{"detailViews":0,"githubClicks":0},"dates":{"published":null,"modified":"2026-08-02T15:26:25.000Z"}}