sqlmodel icon indicating copy to clipboard operation
sqlmodel copied to clipboard

Can SQLModel be more generic in its implementations? Swappable backends?

Open ashleysommer opened this issue 4 years ago • 2 comments

First Check

  • [X] I added a very descriptive title to this issue.
  • [X] I used the GitHub search to find a similar issue and didn't find it.
  • [X] I searched the SQLModel documentation, with the integrated search.
  • [X] I already searched in Google "How to X in SQLModel" and didn't find any information.
  • [X] I already read and followed all the tutorial in the docs and didn't find an answer.
  • [X] I already checked if it is not related to SQLModel but to Pydantic.
  • [X] I already checked if it is not related to SQLModel but to SQLAlchemy.

Commit to Help

  • [X] I commit to help with one of those options 👆

Description

SQLModel has emerged as the long-awaited missing link that uses type annotations to build generic data models to bridge the gap between data validators (like Pydantic) and ORM layer (like SQLAlchemy).

However at the moment SQLModel is tied directly to Pydantic and SQLAlchemy, and works only with Pydantic and SQLAlchemy.

I wonder if SQLModel can be a more generic bridge, to be used between any modern data validator, and ORM.

Wanted Solution

I'd like a stand-alone version of SQLModel that can be installed without requiring Pydantic and SQLModel to be installed along with it.

Operating System

Linux

Operating System Details

N/A

SQLModel Version

0.0.4

Python Version

3.8

Additional Context

No response

ashleysommer avatar Aug 31 '21 05:08 ashleysommer

Also interested in this, would like to see @jordaneremieff 's Djantic story to continue. Django has a great ORM, and would like it to play well with Pydantic as well.

jykae avatar Apr 24 '23 06:04 jykae

I think this is beyond the scope of this project. Maintaining the support of multiple backends is very heavy burden and it's reasonable to choose the most popular ones and only support them

YuriiMotov avatar Aug 15 '25 09:08 YuriiMotov