(instance)?
My objective is that I would want to have full access to access and modify
the instance in the session of the receiving thread.
Thank you,
Michael
On Tue, Feb 16, 2016 at 11:26 AM, Mike Bayer <clas...@zzzcomputing.com>
wrote:
> answered
>
>
>
> On 02/16/2016 09:08 AM
I would like to write code which can correctly merge objects of type X or
any subclass of type X into the session. I have been doing
session.merge(X(id=??)), which works fine for merging type X, but if the
object ID references an instance of any subclass of X, the merge results in
the
Hopefully this should be pretty straightforward. I'm running the following
example which fails under Jython 2.7.0 with postgresql-9.4-1203.jdbc42.jar
using sqlalchemy 1.0.8 with PostgreSQL 9.3.9 on Ubuntu 14.04. Any help
would be much appreciated.
Example and stack trace below:
from sqlalchemy
It could be due to this:
http://sourceforge.net/p/jython/mailman/message/34131065/
On Tue, Oct 6, 2015 at 11:35 AM, Michael Naber <mickey...@gmail.com> wrote:
> Hopefully this should be pretty straightforward. I'm running the following
> example which fails under Jython 2.7.0 with po
*I have a many to many relationship between musician and genre indicating
that a particular musician performs in the style of a particular genre:
Musician -- musician_genre -- Genre
Musician and Genre are both versioned using VersionedMeta so it is easy for
me to display a history of the
I am trying to efficiently update all things that foreign key to a
particular record so that they instead foreign key to a different record. I
provided an example that illustrates the problem I am trying to solve.
Please see my question at the bottom of the code.
Thanks for your help,
Michael
On Tue, Nov 1, 2011 at 11:00 AM, Michael Bayer mike...@zzzcomputing.comwrote:
On Nov 1, 2011, at 6:48 AM, Michael Naber wrote:
Quick question: Why am I allowed to persist an address with no
person_id? Shouldn't the delete-orphan prohibit this?
This was the behavior up until 0.7, when
Quick question: Why am I allowed to persist an address with no
person_id? Shouldn't the delete-orphan prohibit this?
Thanks,
Michael
from sqlalchemy import Column, Integer, String, ForeignKey, create_engine
from sqlalchemy.ext.declarative import declarative_base
from sqlalchemy.orm import
, Michael Naber wrote:
Last line is invalid t-sql. The ‘==’ should just be ‘=’. I get the problem
when using mssql but not with sqlite. Saw the bug on sqa version 0.6.6,
upgraded to 0.7b2 and still having issue. Please let me know if you need
more info and I'll be happy to provide
Last line is invalid t-sql. The ‘==’ should just be ‘=’. I get the problem
when using mssql but not with sqlite. Saw the bug on sqa version 0.6.6,
upgraded to 0.7b2 and still having issue. Please let me know if you need
more info and I'll be happy to provide.
Thanks,
Michael
Traceback (most
If I'm creating a relationship to a class MyRelatedClass using
declarative syntax, and I need to assign a column from MyRelatedClass
to the foreign_keys argument, it seems I have to say
foreign_keys=[MyRelatedClass.__mapper__.c.relate_id]. Is there any way
to just do something in the declarative
(20))
here a_id column of b_table is foreignkey related to the id column of
a_table
On Feb 11, 9:20 am, Michael Naber mickey...@gmail.com wrote:
If I'm creating a relationship to a class MyRelatedClass using
declarative syntax, and I need to assign a column from MyRelatedClass
= Column(Integer,
ForeignKey('department.id'))
parent_department = relationship(Department,
backref=backref(subdepartments),
remote_side=id)
Thanks,
Michael Naber
--
You received this message because you are subscribed to the Google Groups
sqlalchemy group
appreciate any insight.
Thanks,
Michael Naber
from sqlalchemy.orm import scoped_session, sessionmaker, relationship,
backref
from sqlalchemy.ext.declarative import declarative_base
from sqlalchemy import create_engine, Column, Integer, String,
ForeignKey, Text, Date
Session = scoped_session
14 matches
Mail list logo