[sqlalchemy] Could not locate column in row for column

2014-06-20 Thread Belegnar Dragon
Hello. SQLAlchemy 0.9.4 In this code def unidecode_column_name(inspector, table, column_info): column_info['key'] = unidecode(column_info['name']).replace(u' ', u'_') engine = create_engine(mssql+pyodbc://%s:%s@RTBD % (settings.RT_USER, settings.RT_PWD), echo = True) metadata =

Re: [sqlalchemy] hybrid_properties and literals

2014-06-20 Thread Simon King
On Fri, Jun 20, 2014 at 5:02 AM, AM ams@gmail.com wrote: On 06/19/2014 10:24 AM, Mike Bayer wrote: On 6/19/14, 1:05 PM, AM wrote: What I am storing is things like string versions of lists, tuples and dicts, for e.g.: str([1, 2, 3]) str({'a':1} and so on. ast.literal_eval will only

Re: [sqlalchemy] Could not locate column in row for column

2014-06-20 Thread Mike Bayer
On 6/20/14, 3:59 AM, Belegnar Dragon wrote: Hello. SQLAlchemy 0.9.4 In this code def unidecode_column_name(inspector, table, column_info): column_info['key'] = unidecode(column_info['name']).replace(u' ', u'_') engine = create_engine(mssql+pyodbc://%s:%s@RTBD % (settings.RT_USER,

Re: [sqlalchemy] correlating related deletes

2014-06-20 Thread Jonathan Vanasco
thanks! -- You received this message because you are subscribed to the Google Groups sqlalchemy group. To unsubscribe from this group and stop receiving emails from it, send an email to sqlalchemy+unsubscr...@googlegroups.com. To post to this group, send email to sqlalchemy@googlegroups.com.

Re: [sqlalchemy] Could not locate column in row for column

2014-06-20 Thread Mike Bayer
On 6/20/14, 7:32 AM, Mike Bayer wrote: NoSuchColumnError: Could not locate column in row for column '\\u0417\\u0430\\u043a\\u0430\\u0437\\u044b.\\u041d\\u043e\\u043c\\u0435\\u0440 \\u0437\\u0430\\u043a\\u0430\\u0437\\u0430' The problem is i can't really debug this error because it isn't

Re: [sqlalchemy] Could not locate column in row for column

2014-06-20 Thread Mike Bayer
On 6/20/14, 12:14 PM, Mike Bayer wrote: On 6/20/14, 7:32 AM, Mike Bayer wrote: NoSuchColumnError: Could not locate column in row for column '\\u0417\\u0430\\u043a\\u0430\\u0437\\u044b.\\u041d\\u043e\\u043c\\u0435\\u0440 \\u0437\\u0430\\u043a\\u0430\\u0437\\u0430' The problem is i can't

[sqlalchemy] A question regarding hybrid properties, relationships and schema changes

2014-06-20 Thread Ken Lareau
So in the ongoing improvement of one of our internal databases, we created a new table named 'environments' whose SQLA code looks something like this: class Environment(Base): __tablename__ = 'environments' id = Column(u'environmentID', INTEGER(), primary_key=True) environment =

[sqlalchemy] Re: A question regarding hybrid properties, relationships and schema changes

2014-06-20 Thread Jonathan Vanasco
I think this might work... 1. remove the 'environment' column 2. set up an 'Association Proxy' to map `environment_obj.environment` column as the table's `environment` property -- You received this message because you are subscribed to the Google Groups sqlalchemy group. To unsubscribe from

Re: [sqlalchemy] A question regarding hybrid properties, relationships and schema changes

2014-06-20 Thread Mike Bayer
On 6/20/14, 3:38 PM, Ken Lareau wrote: So in the ongoing improvement of one of our internal databases, we created a new table named 'environments' whose SQLA code looks something like this: class Environment(Base): __tablename__ = 'environments' id = Column(u'environmentID',

Re: [sqlalchemy] A question regarding hybrid properties, relationships and schema changes

2014-06-20 Thread Ken Lareau
On Fri, Jun 20, 2014 at 1:23 PM, Mike Bayer mike...@zzzcomputing.com wrote: On 6/20/14, 3:38 PM, Ken Lareau wrote: So in the ongoing improvement of one of our internal databases, we created a new table named 'environments' whose SQLA code looks something like this: class