anymodel.storages.sqlalchemy¶
SQLAlchemy-based storage implementation.
This module provides a storage backend that persists entities to SQL databases using SQLAlchemy, with support for automatic migrations.
Classes¶
- class anymodel.storages.sqlalchemy.SqlAlchemyStorage(url, **kwargs)[source]¶
Bases:
StorageStorage backend for SQL databases via SQLAlchemy.
Provides persistence to any SQLAlchemy-supported database with automatic schema migration capabilities.
- insert(tablename, values)[source]¶
Insert a new row into the table, returns the newly generated primary key.