I know how to do a distinct in SQLAlchemy, but I'm trying to take my existing SQLAlchemy distinct query and attach an additional static text column to the output to get the equivalent of
select 'extrainfo' as 'Extra_Info', user_id as 'User_Id'
from (select distinct user_id from some_table) a;
I know how to do what is in the subquery. So far I have considered turning my original distinct query into a subquery then querying on that, but without luck thus far.