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 GNU GENERAL PUBLIC 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.7.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.7-py3-none-any.whl (18.6 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: minidatabase-1.7.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.7.tar.gz
Algorithm Hash digest
SHA256 4c892840df089528f577509973dac88e42b469a87f64bc7a4993f55c75fe4df4
MD5 4bef868a3f47d9ea376d25abd3f9181f
BLAKE2b-256 6d7b9d64fb4316be9e741abbb7aab50f9283bfbd24230a8e753ae05707a5211c

See more details on using hashes here.

File details

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

File metadata

  • Download URL: minidatabase-1.7-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.7-py3-none-any.whl
Algorithm Hash digest
SHA256 20d8fb44415ed7d9b304606ac9211c93ae729d10d466120f05b5326eafe084bb
MD5 79232803beeeb6b20491b52696751449
BLAKE2b-256 1ca92753c47aa894592e71928a235a31910486e6439408fa2416f8b6248e0692

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