Skip to main content

Easy to use database module

Project description

DankDB - Simple Database

This simple, yet useful module allows the user to create a database for small scale projects; the user can easily add values to the database while simultaneously retrieving values.

Features:

• create_table - Takes in a table name and multiple column names then creates a table. • insert_row - Takes in a row of values and adds them into the table. • delete_rows - Removes all rows from table. • fetch_table - Retrieves all values within the table. • export_csv - Export table into a csv file with given table name. • read_csv - Prints out all values in table with given table name. • close - Closes connection to database.

How to install

pip install dankdb

How to use

Example code

from dankdb import Database

db = Database()
db.create_table('example', 'column1 TEXT', 'column2 TEXT', 'column3 TEXT')
db.insert_row('value1', 'value2', 'value3')
db.insert_row('value4', 'value5', 'value6')

print(db.fetch_table())

db.close()

Feature request

If there is a feature that you would like implemented, open an issue, and I will work on it.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

dankdb-0.0.3.tar.gz (2.7 kB view hashes)

Uploaded Source

Built Distribution

dankdb-0.0.3-py3-none-any.whl (3.9 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page