It seems like passing literal_binds=True to the call to
sql_compiler.process in get_column_default_string will work, so long as
SQLAlchemy can convert the values to literal binds. Which, in the example
given, isn't the case.
--
You received this message because you are subscribed to the
I have a Person class and a Names class, which have a one-to-many
relationship ( a person can have many names ).
After doing a query like this:
p = session.query(Person).filter(Person.birthday 1992-01-01).one()
I'd like to further perform a query on the returned object p to select only
its
On Wed, Jun 18, 2014 at 8:40 AM, Bao Niu niuba...@gmail.com wrote:
I have a Person class and a Names class, which have a one-to-many
relationship ( a person can have many names ).
After doing a query like this:
p = session.query(Person).filter(Person.birthday 1992-01-01).one()
I'd like
Thank you very much Simon! I skipped those parts without realizing how
useful they are. Thanks a lot for point me the right direction!
On Wed, Jun 18, 2014 at 3:57 AM, Simon King si...@simonking.org.uk wrote:
On Wed, Jun 18, 2014 at 8:40 AM, Bao Niu niuba...@gmail.com wrote:
I have a Person
On 6/18/14, 2:06 AM, rpkelly wrote:
It seems like passing literal_binds=True to the call to
sql_compiler.process in get_column_default_string will work, so long
as SQLAlchemy can convert the values to literal binds. Which, in the
example given, isn't the case.
the long standing practice for
On Wed, Jun 18, 2014 at 11:15 AM, Mike Bayer mike...@zzzcomputing.com wrote:
On 6/18/14, 2:06 AM, rpkelly wrote:
It seems like passing literal_binds=True to the call to
sql_compiler.process in get_column_default_string will work, so long
as SQLAlchemy can convert the values to literal binds.
On 6/18/14, 12:03 PM, Ryan Kelly wrote:
On Wed, Jun 18, 2014 at 11:15 AM, Mike Bayer mike...@zzzcomputing.com wrote:
On 6/18/14, 2:06 AM, rpkelly wrote:
It seems like passing literal_binds=True to the call to
sql_compiler.process in get_column_default_string will work, so long
as SQLAlchemy
Hey all,
First and foremost, thank you for this wonderful library! This is my first
post to the list and I am very grateful for those who have taken the time
to make sqlalchemy.
I am using SQLalchemy as a backend for an object-oriented language I am
developing. The way it works is that it
Le mercredi 18 juin 2014 22:03:33 UTC+3, Michael Bayer a écrit :
if you can show the SQL you expect that would help. it seems in your SO
question you want a subquery, you'd have to define that:
class Holder(..):
some_prop = column_property(select([func.max(1 * col1 / col2)]))
On 6/18/14, 4:50 PM, Mike Solomon wrote:
Le mercredi 18 juin 2014 22:03:33 UTC+3, Michael Bayer a écrit :
if you can show the SQL you expect that would help. it seems in
your SO question you want a subquery, you'd have to define that:
class Holder(..):
some_prop =
Bumping this, is there a way to do a replacement with_polymorphic instead
of an addition?
Michael
On Tuesday, April 8, 2014 3:59:34 PM UTC-4, Michael Weylandt wrote:
On Monday, April 7, 2014 5:11:48 PM UTC-4, Michael Bayer wrote:
On Apr 7, 2014, at 2:46 PM, Michael Weylandt
My use case is a simple CRUD app which has a history table (patterned on
the example in the SQLAlchemy docs) and a current table.
I want to write a simple context manager so that
f = db.session.query(Foo).all()
gives current values while:
with app.as_of(date(2014, 05, 31)):
f =
Hi,
I am trying to convert the following SQL to SQLAlchemy:
SELECT teams.department, teams.team,
IF(employee_managers.team_id IS NOT NULL, employee_managers.manager,
teams.default_manager) AS manager
FROM teams
LEFT JOIN employee_managers ON employee_managers.team_id = teams.id
WHERE
Look at
sqlalchemy.sql.func: http://docs.sqlalchemy.org/en/rel_0_9/core/functions.html
On Wednesday, June 18, 2014 8:31:04 PM UTC-4, Vineet Goel wrote:
Hi,
I am trying to convert the following SQL to SQLAlchemy:
SELECT teams.department, teams.team,
IF(employee_managers.team_id IS
On 6/18/14, 8:31 PM, Vineet Goel wrote:
Hi,
I am trying to convert the following SQL to SQLAlchemy:
|SELECT teams.department, teams.team,
IF(employee_managers.team_id IS NOT NULL, employee_managers.manager,
teams.default_manager) AS manager
FROM teams
LEFT JOIN employee_managers
15 matches
Mail list logo