Um pacote simples para realizar operações no mongoDB
Project description
Introdução
Essa biblioteca foi criada como uma forma de abstração das operações mais simples de um banco noSQL.
Início
Após fazer a instalação com o pip install fast_nosql_manager é necessário que você importe a classe correspondente ao banco que deseja manipular.
from fast_nosql_manager import MongoRepository
Ao importar a classe você pode instância-la ou usa-la diretamente preenchendo os parâmetros necessários.
db = MongoRepository(
db_str_connection='mongodb://localhost:27017/',
db_name='local'
)
Métodos
create_collection
mongo.create_collection(collection_name='teste')
delete_collection
mongo.delete_collection(collection_name='teste')
create_document
mongo.create_document(
connection_name='teste',
documents=[{'name': 'Oscar'}, {'name': 'Oscar'}]
)
delete_document
mongo.delete_document(collection_name='teste', where={'name': 'Oscar'})
select_all
mongo.select_all(collection_name='teste')
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
File details
Details for the file fast_nosql_manager-0.3.3.tar.gz
.
File metadata
- Download URL: fast_nosql_manager-0.3.3.tar.gz
- Upload date:
- Size: 4.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1d9603ebee876c00d24814850e4015d2fdfb280030facac4c424207ac89ea6b4 |
|
MD5 | 0e87e9a15096a0d45d567090aa70bff4 |
|
BLAKE2b-256 | 073de8f807503e694bfeceb1e40617428badd559139ab9c6b3e6dfd093f9e0c1 |
File details
Details for the file fast_nosql_manager-0.3.3-py3-none-any.whl
.
File metadata
- Download URL: fast_nosql_manager-0.3.3-py3-none-any.whl
- Upload date:
- Size: 5.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | f5ab56db02a42b3fd963217598a2cad0ecd285a9be4c0ea3532e30e7deb6e72c |
|
MD5 | 4bd261f5c81d90f7ce327582a366012a |
|
BLAKE2b-256 | 357707c77893c36e8545b5f433bb4bf81242611fc0a9d80cd0ee79abb6fd10d1 |