[sqlalchemy] What is scalar-holding attribute?

2014-02-10 Thread Bao Niu
Could someone help give a simple definition of scalar-holding attribute? In documentation for many to one relationship this term occurred, I tried Google the term but didn't find a definition. Thx. -- You received this message because you are subscribed to the Google Groups sqlalchemy group. To

Re: [sqlalchemy] What is the point to re-define each and every column in __init__ in a class?

2014-02-10 Thread Simon King
On Mon, Feb 10, 2014 at 7:13 AM, Bao Niu niuba...@gmail.com wrote: I'm new to sqlalchemy. I tried to search this question but didn't come up with accurate search terms. So I come here for some help from real people instead of search engine. For the following code: class Places(Base):

[sqlalchemy] problems with mysql reflect

2014-02-10 Thread robert rottermann
Hi there, I have a mysql database that I use on several linux boxes. No I get the following error on on of them: Traceback (most recent call last): File ../bin/zopepy, line 317, in module execfile(__file__) File t.py, line 38, in module BaseA.metadata.reflect(local_engine_a) File

Re: [sqlalchemy] What is scalar-holding attribute?

2014-02-10 Thread Michael Bayer
a scalar is a value that is just one thing, as opposed to a collection. e.g.: x = 5 # — scalar x = [1, 2, 3] # — not a scalar x = MyObject() # — scalar object (SQLA distinguishes here between object and non…depending on what doc you’re looking at) x = set([MyObject(), MyObject()]) # —

Re: [sqlalchemy] problems with mysql reflect

2014-02-10 Thread Michael Bayer
so this code runs fine on many machines, just one machine is doing this? have there been modifications made to the SQLAlchemy library on that one machine? I’m not able to reproduce this case. There’s a path where table.dialect_kwargs gets populated and within the scope of MySQL reflection,

[sqlalchemy] declarative polymorphic inheritance abstraction problem

2014-02-10 Thread Chris Withers
Hi All, I'm trying to be efficient with my code, but it seems to tripping SQLAlchemy up. So, basically I want to have a schema with two tables, content and project, to represent two three types of object: - article has a set of fields as found in the 'content' table - project has fields

Re: [sqlalchemy] declarative polymorphic inheritance abstraction problem

2014-02-10 Thread Michael Bayer
On Feb 10, 2014, at 2:36 PM, Chris Withers ch...@simplistix.co.uk wrote: Hi All, I'm trying to be efficient with my code, but it seems to tripping SQLAlchemy up. So, basically I want to have a schema with two tables, content and project, to represent two three types of object: if you