Make Your own personal database liter than others
Project description
BOXDB
This a database managment lib made for python, which works like any Libraries and is very lite
no aditional setup require but there is some procedure to create a project is very easy.
Installation
-
use
pip install boxdb -
Make sure that your
pipversion is updatedpip install --upgrade pip. -
Select the correct package for your environment:
-
Import the package:
import boxdb
Clone the project
git clone https://github.com/kshitij1235/boxdb/tree/main/dist
Install
pip install boxdb
UPDATE
-
get_table() now we can select rows to show
-
add_column() is been tweed so it fills empty spaces by null
-
create_rows() is been updated soliving spacing problem in data file
-
read performace is been improved with new lib update of filemod
Libraries Used
-
Tabulate
-
filemod
Features
-
Very lite and easy to maintain
-
custom encryption are very easy to apply
-
faster in performace
Updates
-
get_table() is updated now it can take selective rows.
-
create_row() bug is solved.
-
minor create_row() bug solved
Things to keep in mind
- you can only acess the database file when your python file and database file are in same directory
How to use it :)
phase 1 (Creating a TABLE)
-
In order to start with boxdb you first need to have a file for table reaction with a
variable with some parameters
-
you can use this code to start with it too
from boxdb import*
#in this variable you make sure too include the the name key aka variable as it will be your table name
# and rest you can put any number of keys values you want its upto you
info={
'name':"plasma",
'description':"makeing heard of cows talking to each other and making things more brigth for the world to take stem"
}
# with the help of this function your table will be created
boxdb.create_project(info)
#with the help of this function you can check the details of your table which you stored
details=boxdb.get_detail("plasma")
print(details)
| functions | description | arguments |
| ----------------- | -------------------|-----------|
| create_project | This function creates basic file system to store data|info(patten given above for variable naming)|
| get_detail| This gives you all the basic details of the table |table_name|
phase 2 (wow you learned to set up boxdb)
Now lets start with row creation and deletion
from boxdb import*
# At start lets create some row !!!!
# you can pass string or even list to create rows its according to your wish
# ill show creating 4 rows 3 with rows and 1 with string
row=["sr no","names of cow","lites fo milk"]
# this fucntion takes table name (in my case its "plasma") and rows you can pass list if you have many rows
# or you can use string if you wanna create one single row
# this is multiple
boxdb.create_row("plasma", rows)
# this is single row
boxdb.create_row("plasma", "update")
#you can always delete a row if you want
# this fucntion takes table name (in my case its "plasma") and rows you can pass list if you have many rows to delete
# or you can pass a sting if you wanna delete a single row
# in this case am deleting a single row but you can always pass a list to
boxdb.remove_row("plasma", "update")
| functions | description | arguments |
| ----------------- | -------------------|-----------|
| create_row | This function helps you create rows in you table|table_name,row(accepts list or string)|
| remove_row| Helps you delete rows if you dont want |table_name,row(accepts list or string)|
Lets learn about creating columns
from boxdb import*
'''
# At start lets create some columns!!!!
# you have to pass list to columns according to the rows
# for example if you have three rows ,you have to pass 3 elements each elements gets added to
# each row
# In short you can add 1 column at a time but a fix for that will be realease soon too '
'''
columns=["1","amanda","28"]
'''
# this function takes table name (in my case its "plasma") and column you have to pass list
# that you created earlier according to row size
'''
# this is multiple
boxdb.add_column("plasma", columns)
#you can always delete a column if you want
# this fucntion takes table name (in my case its "plasma")
# and the number of column
# in this case am delelting a single columns whic h is column number 1
boxdb.remove_column_number"plasma", 1)
| functions | description | arguments |
| ----------------- | -------------------|-----------|
| add_column | This function helps you create columns in you table|table_name,column_data(list)|
| remove_column_number| Helps you delete column if you dont want |table_name,remove_column_number|
Showing table
from boxdb import*
# Displaying table is a kids job , its very easy
# this function helps you to show table
# this function takes a single argument which is table name(in my case its "plasma")
##i understand few freatures should be added to improve the use of show table functions
# and yes it would be release soon
boxdb.get_table("plasma")
'''
now there is another method to do it with selective rows
'''
list_of_rows=["sr_no","number_of_cows"]
doxbd.get_table("plasma",[list_of_rows])
| functions | description | arguments |
| ----------------- | -------------------|-----------|
| get_table| This function helps to visualize the table|table_name|
License
Feedback
If you have any feedback, please reach out to us at email kshitijjathar7@gmail.com
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file boxdb-0.5.tar.gz.
File metadata
- Download URL: boxdb-0.5.tar.gz
- Upload date:
- Size: 7.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.5.0 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.10.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a16fe641a21217bea039b0879e3c70eb1fb01aa67229271286441886ba9c4ead
|
|
| MD5 |
f2d4bfedd6d2d1fd493f3ddd3328c85c
|
|
| BLAKE2b-256 |
8a047241011f2b1a5883ad43c4482ffdbf98e27e4db6e360fa669b5139facf11
|
File details
Details for the file boxdb-0.5-py3-none-any.whl.
File metadata
- Download URL: boxdb-0.5-py3-none-any.whl
- Upload date:
- Size: 7.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.5.0 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.10.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ad1e55ce68e5398bf669bf8095c1ac59e732dc7703b56895e8290182c482a948
|
|
| MD5 |
037cdbe2211d3a37a441310375dcb2ae
|
|
| BLAKE2b-256 |
6b278044120f551ca426c7b5a15635e2585689bdd0ad0f76d8d03284325d2923
|