Apologies if I missed something, but does SQLAlchemy (1.2.0?) support the new
Postgres 10 identity keyword
(https://blog.2ndquadrant.com/postgresql-10-identity-columns/)?
--
SQLAlchemy -
The Python SQL Toolkit and Object Relational Mapper
http://www.sqlalchemy.org/
To post example code, plea
FWIW, PostgreSQL supports a "DISTINCT ON" syntax.
--
SQLAlchemy -
The Python SQL Toolkit and Object Relational Mapper
http://www.sqlalchemy.org/
To post example code, please provide an MCVE: Minimal, Complete, and Verifiable
Example. See http://stackoverflow.com/help/mcve for a full descrip
OK, after 2 days of trying and searching creating a post in the google
groups leads to rephrasing the problem. And this often leads to finding the
solution:
I managed to do it this way:
MyTable.query.with_entities(MyTable.columnB).distinct().all()
Problem solved...
Am Sonntag, 8. Oktober 2
Hi,
I have a table with many columns (columnA, columnB, columnC) and I want to
know, how many different entries in columnB are.
I would do such an SQL query:
select distinct columnB from myTable;
I see there is also ``distinct()`` in SQL Alchemy.
However - I am using Class defined ORM like