snippets:python:db
This is an old revision of the document!
Table of Contents
Snippets: Python: Datenbanken
pickledb
Beispiel
Das Beispiel von der pickledb-Webseite:
from pickledb import PickleDB # Bind to a JSON file; no I/O yet db = PickleDB("data.json") db.load() db.set("username", "alice") db.set("theme", { "color": "blue", "font": "sans-serif" }) print(db.get("username")) # → "alice" db.save() # atomically write to disk
snippets/python/db.1775060091.txt.gz · Last modified: by malte70
