DBISshit! - the python app that mimics a database
DBISshit! is a Python 2.7 targeted database tool which
has inherited the full functionality of a DBMS while being none.
Features:
- works in-memory
- loads the DB into memory
- commits changes to memory
- HDD-writeback: on exit option 'y', command 'writeback' and command 'stop' (commit & wb)
- integrated interactive help
- create new DBs: ./dbisshit.py new myfile
- edit DBs:
- add entries either as a line or by values (no ID doubling possible)
- change lines either by ID or linenr
- change values either by ID or linenr
- remove entries either by ID or linenr
- display entries either by ID or linenr
- sort database by any header value
- show full database
- merge DBs with (partly) identical headers: ./dbisshit.py merge file1.dbis file2.dbis
- also: ./dbisshit.py merge file1.dbis.gz file2.dbis.gz
- or: ./dbisshit.py merge file1.dbis.gz file2.dbis
- or: ./dbisshit.py merge file1.dbis file2.dbis.gz
- DB files are human readable
- generate reports (integrated in sortdb)
- permanent changelog file (saved as filename.dbis.log)
- autosave every 15 instructions
- backup every 30 instructions
- DB-file lock by making file read-only after import (rw again at exit)
- convert DBIS-Format files to XML or HTML tables (external function, export possible)
- if no changes were made writeback and write to log is skipped at exit
- check for correct file ending before importing db
- search for a value in any row, create a report and a subset .dbis file of that search
- although colons are used as a split symbol, the usage of colons is supported
- colons are automatically replaced with &dpp;
- at displaying &dpp; is reverted back to colons (within htow)
- get total item count of one row (getcount)
- caching of requests (only getcount)
- aliases gc (getcount), add (addln), ls (showdb)
- gc, search, sort and changeln/changeid: same numbering at row select
- gz compression support
- create, import and merge .gz compressed dbis files
- dbisshit-reader supports compression
Planned:
- non-interactive version for embedded use with e.g. bash scripts (probably as embed() function)
- support for common database formats (decision on which still pending)
- direct code injection from DB-file
Bugs:
- [ALL FIXED]
Files:
- dbisshit.py - The main executable
- dbisshit-reader.py - Standalone reader for DBISshit-Format DBs
- dbistohtml.py - converts a DBIS-Format database into a table embedded in an html file
- dbistoxml.py - converts a DBIS-Format database into a xml file
- LICENSE - project's license (MIT)
- mytest.dbis - example database to test changes
- mytest.dbis.log - logfile for changes on mytest.dbis (automaticly created)
- test*.dbis - files used for testing merge
- test1.dbis - component one
- test2.dbis - component two (larger - but compatible - header)
- test1_test2_merged.dbis - result
- report_mytest.dbis.txt - result of sortdb + report on mytest.dbis
- mytest.dbis.html - result of ./dbistohtml.py mytest.dbis
- mytest.dbis.xml - result of ./dbistoxml.py mytest.dbis
- mytest_search_Vorname_n.* - result of search with value 'n' in col 'Vorname'
- doc.py - documentation (WIP)
- gztest.dbis.gz - with gzip compressed mytest.db (w/o last line)
- gztest.dbis.gz.log - log (removed 1 line in gztest)
- gztest_mytest_merged.dbis (merge test gz/dbis)
Comments:
- file extention is .dbis or .dbis.gz (gziped)
DBISshit! - 'Cause without DBs DBIS is shit! :)