On Wed, 2009-10-21 at 09:24 -0700, David Gardner wrote:
> Using setattr() shouldn't be a problem, however the __dict__ attribute
> also has other things in there like _sa_instance_state that I don't
> believe you
> want to copy to the new item. Try this instead:
>
> for col in object_mapper(upda
Thanks for both ideas. Hmmm when I compile my select( ) statement
it still has the %(param_1) parameter format instead of the :param_1
format. That seems to make the execute complain about syntax later
on. Must be missing something... Anyway, serializer is easier and
zlib compressing helps
On Fri, Oct 23, 2009 at 12:40 PM, Joril wrote:
>
> Hi everyone!
> I'm trying to automatically build a shallow copy of a SA-mapped
> object.. At the moment my function is just:
>
> newobj = src.__class__()
> for prop in class_mapper(src.__class__).iterate_properties:
>setattr(newobj, prop.key,
On Fri, Oct 23, 2009 at 1:47 PM, Michael Bayer wrote:
>
> Much easier to use serializer.
>
>
> I agree with that.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"sqlalchemy" group.
To post to this group, send email
jeff wrote:
>
> I would like to save a number of these in a database so size is
> important (the serialized select() was somewhat large...)
using serializer() ? really? if you do a naive dumps() with plain
pickle, yes the serialize would be huge.
> so I would
> like to get the string represen
On Fri, Oct 23, 2009 at 12:45 PM, jeff wrote:
>
> I would like to save a number of these in a database so size is
> important (the serialized select() was somewhat large...) so I would
> like to get the string representation of the raw SQL directly useable
> by sqlalchemy if possible. As I have
Don Dwiggins writes:
> Hmmm, Could you elaborate a bit about the "self-contained"? I do have
> some cases where I fire off a deferredList with several (independent)
> queries in it. Might that be problematic?
My guess is that your "independent" comment is essentially the same as
my "self-co
I would like to save a number of these in a database so size is
important (the serialized select() was somewhat large...) so I would
like to get the string representation of the raw SQL directly useable
by sqlalchemy if possible. As I have in my examples, the str(select)
doesn't seem directly us
Hi everyone!
I'm trying to automatically build a shallow copy of a SA-mapped
object.. At the moment my function is just:
newobj = src.__class__()
for prop in class_mapper(src.__class__).iterate_properties:
setattr(newobj, prop.key, getattr(src, prop.key))
but I'm having troubles with lazy re
sector119 wrote:
>
> Hi!
>
> Is it possible to easily add tables to FROM clause, now I use
> following code to append additional table names but it look like a
> hack..
>
> at PGCompiler.visit_update() I see self.stack.append({'from': set
> ([update_stmt.table])}) where and how it's used, may be u
sector119 wrote:
>
> It's on trunk.
> Elso can't import orm from sqlalchemy :/
>
> On Oct 23, 6:00 pm, sector119 wrote:
>> Is there something wrong with ARRAY type in SA 0.6? no dialects/
>> /__init__.py has ARRAY at __all__ !?
ARRAY type is only within postgresql. You'd have to import it from
It's on trunk.
Elso can't import orm from sqlalchemy :/
On Oct 23, 6:00 pm, sector119 wrote:
> Is there something wrong with ARRAY type in SA 0.6? no dialects/
> /__init__.py has ARRAY at __all__ !?
--~--~-~--~~~---~--~~
You received this message because you are s
Is there something wrong with ARRAY type in SA 0.6? no dialects/
/__init__.py has ARRAY at __all__ !?
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"sqlalchemy" group.
To post to this group, send email to sqlalchemy
Hi!
Is it possible to easily add tables to FROM clause, now I use
following code to append additional table names but it look like a
hack..
at PGCompiler.visit_update() I see self.stack.append({'from': set
([update_stmt.table])}) where and how it's used, may be using this I
can append some eleme
Thanks a lot, Michael!
On Oct 23, 4:09 am, Michael Bayer wrote:
> On Oct 22, 2009, at 3:26 PM, sector119 wrote:
>
>
>
> > Something strange, Michael.. All bindparams are different. Compliller
> > should not add to SET all params if values() has bindparam args, no?
> > where() have:
> > bindpa
I have tried it, it's great, thanks!
On Fri, Oct 23, 2009 at 3:19 PM, Tefnet Developers - Tomasz Jezierski <
develop...@tefnet.pl> wrote:
>
> Dnia 2009-10-23, Pt o godzinie 15:00 +0800, Stone Puzzle pisze:
> > Is there a way or lib to help us generating python code of all of the
> > tables and r
Dnia 2009-10-23, Pt o godzinie 15:00 +0800, Stone Puzzle pisze:
> Is there a way or lib to help us generating python code of all of the
> tables and relations automatically from a existing database?
>
http://turbogears.org/2.1/docs/main/Utilities/sqlautocode.html
Tomasz Jezierski
Tefnet
http:/
Is there a way or lib to help us generating python* code *of all of the
tables and relations automatically from a existing database?
Thanks.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"sqlalchemy" group.
To post
18 matches
Mail list logo