Skip to main content

A small example package

Project description

dynamoquick

Under construction! Not ready for use yet! Currently experimenting and planning!

Developed by Zuhair (c) 2022

Examples of How To Use (1.0 Version)

Methods Available:

check_exist(client,tablename) create_table1(dynamodb,tablename,hashname,hashtype,sortname,sorttype,readcapacity,writecapacity) create_table2(dynamodb,tablename,hashname,hashtype,readcapacity,writecapacity) load_table(dynamodb,tablename,files) delete_table(dynamodb,tablename) view_table_specific(dynamodb,tablename,key,value,projection,page) update_item(dynamodb,tablename,hashname,hashvalue,updatename,updatevalue,sortname=None,sortvalue=None) delete_item(dynamodb,tablename,hashname,hashvalue,sortname=None,sortvalue=None) filter_details1(dynamodb,tablename,queriesname,queriesvalues,client) filter_details2(dynamodb,tablename,queriesnames,queriesvalues,client)

Importing in other program:

from dynamoquick import *

Sample Demo

from dynamoquick import *
import boto3

dynamodb=boto3.resource("dynamodb",endpoint_url="http://localhost:8000",region_name='us-west-2',aws_access_key_id="fakeid",aws_secret_access_key="fakekey")
client=boto3.client('dynamodb',endpoint_url='http://localhost:8000',region_name='us-west-2',aws_access_key_id='fakeid',aws_secret_access_key='fakekey')

if __name__=="__main__":
        tablename=input("TableName:")
        if not check_exist(client,tablename):
            hashname=input("Hashname:")
            hashtype=input("Hashtype:")
            readcapacity=input("Readcapacity:")
            writecapacity=input("Writecapacity:")
            res=input("Do you have sortkey:")
            if res=="yes":
                sortname=input("Sortname:")
                sorttype=input("Sorttype:")
                create_table1(dynamodb,tablename,hashname,hashtype,sortname,sorttype,readcapacity,writecapacity)
            else:
                print("No Sort Key")
                create_table2(dynamodb,tablename,hashname,hashtype,readcapacity,writecapacity)
            print('Table Created Successfully')
        else:
            print('Table with name %s already existed!' % tablename)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

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

dynamoquick-1.0.0-py3-none-any.whl (5.1 kB view details)

Uploaded Python 3

File details

Details for the file dynamoquick-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: dynamoquick-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 5.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/33.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.63.0 importlib-metadata/4.11.2 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.0

File hashes

Hashes for dynamoquick-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 a1b62059442458f097714393e6956e74cb293b0f60525b5432be992b021353a5
MD5 eccff8f1c23c4a88f8e1f0e2149b5ce9
BLAKE2b-256 bca46a0a4409e9bb31cdf6d8fba7223fa808deca319bcf3a445b1d44fe636f8e

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