This project is a web application for managing Classroom instruction and operations. It is built using Flask, SQLAlchemy, and other requirements.txt dependencies.
we want to create sqlite_v2 (which will eventually have data changes from API )
for this we need to extract the schema from sqlite.db (already have code from this in db_schema), I wanted to leave this untouched so I worked on fixing db_init.py
NOTE : “SQLAlchemy 1.4 and later, the execute method was deprecated and removed from the Engine object. So I am using the Connection object to execute raw SQL queries.”
1) Ran new db_init.py
2) Observe new table , with specified tables. This script is easy because we can customize which tables to migrate, and which db to migrate from. Eventually I may have a global variable called "sql version" , so the file which connects to rds can utilize the correct version of sql.db (sql_v2.db versus sql_v3.db versus sql_v4.db , etc.)
NOTE : “SQLAlchemy 1.4 and later, the execute method was deprecated and removed from the Engine object. So I am using the Connection object to execute raw SQL queries.”
1) Ran new db_init.py
2) Observe new table , with specified tables. This script is easy because we can customize which tables to migrate, and which db to migrate from. Eventually I may have a global variable called "sql version" , so the file which connects to rds can utilize the correct version of sql.db (sql_v2.db versus sql_v3.db versus sql_v4.db , etc.)