I've searched all over the internet and a handful of AI bots for what seems to me to be an extremely basic function, to no avail. What is the SQLAlchemy command to check the server database version?
I know I can execute a raw SQL query, but the exact syntax varies between SQL variants. Two examples to whit:
- Postgres:
SELECT version() - SQLite:
SELECT get_version()
Desired response:
PostgreSQL 15.7 on x86_64-pc-linux-gnu, compiled by gcc (GCC) 7.3.1 20180712 (Red Hat 7.3.1-12), 64-bit
...or...
PostgreSQL 15.7
I have searched all over the SQLAlchemy 1.4 and 2.0 docs but can't find it. Surely there's a way?