Skip to content

avikeid2007/PyLearning

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

1. Install dependencies:
   pip install sqlalchemy alembic pyodbc

2. Initialize Alembic:
   alembic init alembic

3. Update alembic.ini with your connection string:
   sqlalchemy.url = mssql+pyodbc://localhost/TestDB?driver=ODBC+Driver+17+for+SQL+Server&trusted_connection=yes

4. Edit alembic/env.py:
   from models import Base
   target_metadata = Base.metadata

5. Generate migration:
   alembic revision --autogenerate -m "initial"

6. Apply migration:
   alembic upgrade head

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors