Skip to content

v4.1.0 - Type-Safe SQLAlchemy Integration

Choose a tag to compare

@nhumrich nhumrich released this 17 Oct 19:18
· 49 commits to main since this release

What's New

This release improves type checker compatibility when using SQLAlchemy columns with the t-sql query builder.

New Feature: SAColumn Wrapper

Added a new SAColumn() wrapper function that provides proper IDE completions and type checking for SQLAlchemy columns:

from sqlalchemy import Integer, String
from tsql.query_builder import Table, SAColumn

class Users(Table, metadata=metadata):
    id = SAColumn(Integer, primary_key=True)
    name = SAColumn(String(100))

# Type checkers now recognize column methods!
query = Users.select().where(Users.name.like('%john%'))  # ✅