Skip to content

Some python abstractions to make simple database operations easier.

Notifications You must be signed in to change notification settings

icey502/py-simple-db-utils

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 

Repository files navigation

py-simple-db-utils

Some python abstractions to make simple database operations easier.

Declare your db dictionary as follows:

{
    'DB_HOST': 'address',
    'DB_PORT': 3306,
    'DB': 'db',
    'DB_USER: 'user',
    'DB_PASS: 'pass'
}

SimpleDictWriter Example Usage:

    writer = SimpleDictWriter(db)
    writer.write_dict("myTable", {'id':1234,'value':'mydata'}, commit=True)

SimpleDictReader Example Usage:

    reader = SimpleDictReader(db)
    reader.read_dict("table_name")

Disclaimer: This is currently a work in progress, and it only supports MySQL. Postgres support is possible with minor changes.

About

Some python abstractions to make simple database operations easier.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages