Skip to main content

This module is written to launch your programs with any database you want in the shortest time

Project description

ORM-DATABASE-postgres

write example postgres

from orm_database_postgres import PostgreSQL
import asyncio
from pydantic import BaseModel

class users(BaseModel):
    users_rt: str
    password_rt : str
    email: str


postgres = PostgreSQL(host="127.0.0.1",user="postgres",database="wallet",password="123412341234")



async def main():
    data = {"users_rt":"test1","password_rt":"1234","email":"test1@mail.com"}
    data1 = [{"users_rt":"test1","password_rt":"1234","email":"test1@mail.com"},
            {"users_rt":"test2","password_rt":"1234","email":"test2@mail.com"},
            {"users_rt":"test3","password_rt":"1234","email":"test3@mail.com"}]
    await sqlite.start()
    #await sqlite.teble_create_BaseModel("users",users)
    #await sqlite.insert("users",data1)
    #result = await  sqlite.select("users",["users_rt","email"])
    #print(result)
    #await sqlite.delete("users",{"users_rt":"test2"})
    await sqlite.update("users",{"users_rt":"test1"},{"users_rt":"test2"})
asyncio.run(main())

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

orm_database_postgres-0.0.4.tar.gz (4.3 kB view details)

Uploaded Source

Built Distribution

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

orm_database_postgres-0.0.4-py3-none-any.whl (5.3 kB view details)

Uploaded Python 3

File details

Details for the file orm_database_postgres-0.0.4.tar.gz.

File metadata

  • Download URL: orm_database_postgres-0.0.4.tar.gz
  • Upload date:
  • Size: 4.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.12

File hashes

Hashes for orm_database_postgres-0.0.4.tar.gz
Algorithm Hash digest
SHA256 1af9fd192a42792685d90657feeefc99258c6c09d2ebcb276a89be880dc17d1c
MD5 683f174a4c787287cbeb20d1ebcca256
BLAKE2b-256 3ac3d908ec20489c4ffe52f2f480fbb3100d4ed1795094fe2a745e679411d12f

See more details on using hashes here.

File details

Details for the file orm_database_postgres-0.0.4-py3-none-any.whl.

File metadata

File hashes

Hashes for orm_database_postgres-0.0.4-py3-none-any.whl
Algorithm Hash digest
SHA256 130bc2785a4ed7785d9821dd4e9ddf9016b249a8815cc55672ad7aa1604f3847
MD5 364ec58f0c92649320d1d42ace64a441
BLAKE2b-256 b90de819f07484c8b32b275505e402f0e2978f05159e525a3a9e6c45a35ac75f

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