to catch this exception and
then retry the transaction?
Thanks in advance!
--
Jonathan LaCour
http://cleverdevil.org
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
sqlalchemy group.
To post to this group, send email
as pretty as I'd like, but
it works :)
--
Jonathan LaCour
http://cleverdevil.org
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
sqlalchemy group.
To post to this group, send email to sqlalchemy@googlegroups.com
Extension API reference: http://tinyurl.com/8wfkgl
Applying Mapper Extensions: http://tinyurl.com/7a3b5c
Good luck.
--
Jonathan LaCour
http://cleverdevil.org
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
sqlalchemy
tables. I've linked to (and quoted from) the relevant documentation
over on the elixir list, where the original poster initially raised
the question.
Sorry for the noise.
--
Jonathan LaCour
http://cleverdevil.org
--~--~-~--~~~---~--~~
You received this message
this :)
--
Jonathan LaCour
http://cleverdevil.org
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
sqlalchemy group.
To post to this group, send email to sqlalchemy@googlegroups.com
To unsubscribe from this group, send email
`.
--
Jonathan LaCour
http://cleverdevil.org
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
sqlalchemy group.
To post to this group, send email to sqlalchemy@googlegroups.com
To unsubscribe from this group, send email
further questions, don't hesitate
to ask over on the Elixir mailing list. I'll do my best to answer
followups over there!
--
Jonathan LaCour
http://cleverdevil.org
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
who are using file/memcached-based caching strategies.
You bet. If this is indeed the problem, then we need to file a
ticket and fix it. I was arguing against monkeypatching the Entity
class with the custom __getstate__ and __setstate__, but didn't make
that clear.
--
Jonathan LaCour
http
Jonathan LaCour wrote:
Michael Bayer wrote:
I think if Elixir doesn't support mapped entities being pickled,
or requires end-user __getstate__/__setstate__ (i think the
latter is the more reasonable requirement), it should be
explicit about this. pickling/unpickling is a basic necessity
:
query.options(defer(column))
Does this seem desirable to anyone else, or am I just crazy :)
--
Jonathan LaCour
http://cleverdevil.org
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
sqlalchemy group.
To post
be extended somehow
to be a bit more like `defer` but they are in a way inherently
different.
Thanks, let me know what you decide.
--
Jonathan LaCour
http://cleverdevil.org
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
that
goes...
--
Jonathan LaCour
http://cleverdevil.org
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
sqlalchemy group.
To post to this group, send email to sqlalchemy@googlegroups.com
To unsubscribe from this group, send
like.
FYI, I think this should go in the advanced tutorial I referred to
this morning on the Elixir list...
--
Jonathan LaCour
http://cleverdevil.org
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
sqlalchemy group
Jonathan LaCour wrote:
I am attempting to model a doubly-linked list, as follows:
... seems to do the trick. I had tried using backref's earlier,
but it was failing because I was specifying a remote_side
keyword argument to the backref(), which was making it blow up
with cycle detection
?
--
Jonathan LaCour
http://cleverdevil.org
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
sqlalchemy group.
To post to this group, send email to sqlalchemy@googlegroups.com
To unsubscribe from this group, send email
Jonathan LaCour wrote:
I am attempting to model a doubly-linked list, as follows:
Replying to myself:
task_table = Table('task', metadata,
Column('id', Integer, primary_key=True),
Column('name', Unicode),
Column('next_task_id', Integer, ForeignKey('task.id')),
Column
to maintain the previous anyway, since it can be
implied from the next a heck of a lot easier.
The simplest solution is usually the best, and this one definitely
wasn't very simple! On to other ideas...
--
Jonathan LaCour
http://cleverdevil.org
.
Should I just go ahead an use text() rather than bother with
attempting to construct this using an SQLAlchemy expression?
(Yes, I know that this is gross...)
--
Jonathan LaCour
http://cleverdevil.org
--~--~-~--~~~---~--~~
You received this message because you
UNION SELECT ?
AS value), ?, ?, ?, ?, ?, ?, ?, ?)
2008-01-08 17:41:21,833 INFO sqlalchemy.engine.base.Engine.0x..50
[100, '100.0', 'Item One', None, None, None, None, 1, None, None]
--
Jonathan LaCour
http://cleverdevil.org
--~--~-~--~~~---~--~~
You received
curious if this is possible...
--
Jonathan LaCour
http://cleverdevil.org
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
sqlalchemy group.
To post to this group, send email to sqlalchemy@googlegroups.com
To unsubscribe
:)
Excellent :) Yes, Ben and I talked about it, and I am really glad to see
that there is a nice way to deal with this now! Thanks!
--
Jonathan LaCour
http://cleverdevil.org
--~--~-~--~~~---~--~~
You received this message because you are subscribed
: EXT_CONTINUE = EXT_PASS = object()
EXT_STOP = object()
EXT_STOP is just a feel-good value. the general rule of halt on any
return value but EXT_CONTINUE is unchanged.
Perfect. This now makes total sense, thanks for doing this!
--
Jonathan LaCour
http://cleverdevil.org
of the API couldn't be smoothed out
a bit :)
--
Jonathan LaCour
http://cleverdevil.org
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
sqlalchemy group.
To post to this group, send email to sqlalchemy@googlegroups.com
the next activity...otherwise
someone's upgrade might silently fail.
Fair enough, I suppose. I think I can get over it, for the most part.
It might just be an issue of cognitive dissonance because of the naming
convention or how its described in the documentation.
--
Jonathan LaCour
http
finally:
metadata.drop_all()
#-#
It appears to me that MySQL doesn't like it when you don't specify a
FROM in the subselect, whereas PostgreSQL and SQLite don't care.
--
Jonathan LaCour
http://cleverdevil.org
Jonathan LaCour wrote:
It appears to me that MySQL doesn't like it when you don't specify a
FROM in the subselect, whereas PostgreSQL and SQLite don't care.
Responding to myself, I have solved the problem. As it turns out, you
can force SQLAlchemy to generate a FROM for the subselect
Murphy's law strikes again. As soon as I sent the email, I finally
noticed that I wasn't passing my table into my outputs_mapper after
staring at it for an hour...
Sorry for the spam!
--
Jonathan LaCour
http://cleverdevil.org
--~--~-~--~~~---~--~~
You received
way to approach using `SELECT ... FOR UPDATE`?
We were thinking about the possibility of creating a MapperExtension
to make this happen, but aren't really sure about how to go about
implementing that, and any direction would be useful.
Thanks!
--
Jonathan LaCour
http://cleverdevil.org
of MetaData.
I see your point. I don't care what you do with DynamicMetaData, as
long as I can do this one day:
metadata = MetaData()
engine = create_engine(...)
metadata.connect(engine)
... preferably soon ;)
--
Jonathan LaCour
http://cleverdevil.org
the threadlocal insanity :)
What do you think?
--
Jonathan LaCour
http://cleverdevil.org
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
sqlalchemy group.
To post to this group, send email to sqlalchemy@googlegroups.com
to your metadata. The fact that its threadlocal is easy to miss,
and I don't see why it has any threadlocal behavior at all.
Am I missing something? Wouldn't it be better to two separate MetaData
types, one for dynamically binding your engine, and another for
threadlocal metadata?
--
Jonathan LaCour
will
probably give a reasonable idea of how Elixir is different from both
ActiveMapper and TurboEntity.
--
Jonathan LaCour
http://cleverdevil.org
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
sqlalchemy group.
To post
techniques are bugs that should be fixed!
With ActiveMapper, the approach that I took had some issues and
overcoming them required more time than I had to give. With Elixir,
having a team of people committed to helping out makes all the
difference in the world.
--
Jonathan LaCour
http
to be posting a quick tutorial
on creating your *own* DSL statements for your model objects.
--
Jonathan LaCour
http://cleverdevil.org
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
sqlalchemy group.
To post to this group
Today, we are pleased to announce the release of Elixir
(http://elixir.ematia.de), a declarative mapper for SQLAlchemy. Elixir
is the successor to ActiveMapper and TurboEntity, and is a collaboration
between Daniel Haus, Jonathan LaCour and Gaƫtan de Menten. Elixir's
website provides
to handle. Listen to Mike, and move
over to full-fledged SQLAlchemy.
--
Jonathan LaCour
http://cleverdevil.org
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
sqlalchemy group.
To post to this group, send email
folder :)
Either way, my advice still applies. It would be great if you could
illustrate with your example the current SQL that is being generated,
along with some improved SQL that would be faster.
--
Jonathan LaCour
http://cleverdevil.org
!
--
Jonathan LaCour
http://cleverdevil.org
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
sqlalchemy group.
To post to this group, send email to sqlalchemy@googlegroups.com
To unsubscribe from this group, send email
design patterns.
Best of luck!
--
Jonathan LaCour
http://cleverdevil.org
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
sqlalchemy group.
To post to this group, send email to sqlalchemy@googlegroups.com
, because I really don't
think that they make any sense at all.
Good luck -
--
Jonathan LaCour
http://cleverdevil.org
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
sqlalchemy group.
To post to this group, send email
40 matches
Mail list logo