Skip to main content

A tiny database system based on python dictionary.

Project description

# Minidb Python Third-Party Database

Minidb is a Python third-party database that provides a simple and easy-to-use interface for creating, appending and managing databases. It allows for database creation and manipulation without having to use any complex SQL commands.

## Installation

To install Minidb, you can use pip by running the following command:

` pip install minidatabase `

## Usage

To start using minidb, you must first import the library by using the following command:

` python from minidatabase import minidb `

### Creating a Database

To create a local database, you can use the connect method, which takes a single parameter, the path to the database. For example:

` python db = minidb.connect('example.minidb') `

To create a WebMDB server database, you can use the web_connect method, which takes three parameters: password, server_address and port. You can start the server using the minidb -w command on the command line. You can then create a database using the minidb -c example.minidb command.

### Database Operations

After creating a cursor for the database, you can start using the various database operations. Here are some important ones:

#### Append Method

The append method is used to add data to the database. It takes two parameters, tag and value, and is used to create a new tag and assign it a value. For example:

` python db.append('name', 'John') `

#### Delete Method

The delete method is used to delete an entry from the database by tag name. For example:

` python db.delete('name') `

#### Search Method

The search method is used to search the database for a keyword. It returns a list of tags with matching keywords. For example:

` python db.search('age') `

#### Search_value Method

The search_value method is used to search the database for a specific value. It returns a list of tags with matching values. For example:

` python db.search_value('John') `

#### Search_tag Method

The search_tag method is used to search the database for a specific tag. It returns a list of tags with matching tag names. For example:

` python db.search_tag('name') `

#### Clean Method

The clean method is used to clear the database. For example:

` python db.clean() `

#### List Method

The list method is used to list all the entries in the database. For example:

` python db.list() `

#### Commit Method

The commit method is used to save the changes made to the database. For example:

` python db.commit() `

#### Close Method

The close method is used to close the database cursor. For example:

` python db.close() `

## Contributions

Minidb welcomes and appreciates any contributions. If you find any bugs or have any suggestions for improvement, feel free to create a pull request or an issue in the repository.

## License

This project is licensed under the MIT License - see the LICENSE file for details.

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

minidatabase-1.6.1.tar.gz (17.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

minidatabase-1.6.1-py3-none-any.whl (18.6 kB view details)

Uploaded Python 3

File details

Details for the file minidatabase-1.6.1.tar.gz.

File metadata

  • Download URL: minidatabase-1.6.1.tar.gz
  • Upload date:
  • Size: 17.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.0

File hashes

Hashes for minidatabase-1.6.1.tar.gz
Algorithm Hash digest
SHA256 1316407b3922a6a9e98f34b0a4017db26ec4bb01e609ee37887a8c963da53374
MD5 83b38a7c7e6b93816a161fb279917379
BLAKE2b-256 1fb176a5e9a80caf258facdba5953433b7c94a6cc4add7dd71758a1273aa3176

See more details on using hashes here.

File details

Details for the file minidatabase-1.6.1-py3-none-any.whl.

File metadata

  • Download URL: minidatabase-1.6.1-py3-none-any.whl
  • Upload date:
  • Size: 18.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.0

File hashes

Hashes for minidatabase-1.6.1-py3-none-any.whl
Algorithm Hash digest
SHA256 0d3a39a062ac4a505d800ae809d183f0a104d5ebe32034504a22f69a76606257
MD5 ae2a25b60cde3aa4a3fdaf2904bf0f7a
BLAKE2b-256 ecd2540db0879c37ef8fac161e8759c5ee450f47bff8d81382999902860e5671

See more details on using hashes here.

Supported by

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