Hi All,
I just wanted to quickly reach out to the group for ideas as to why I
cannot get this to work:
@transaction.commit_manually
def some_view(request):
# some view logic goes here
sid = transaction.savepoint()
le = models.LogEntry()
le.message = 'A test log message'
le.s
On Sun, Jun 7, 2009 at 7:44 PM, ChrisStoyles wrote:
>
> Hi All,
>
> I just wanted to quickly reach out to the group for ideas as to why I
> cannot get this to work:
>
> @transaction.commit_manually
> def some_view(request):
># some view logic goes here
>
>sid = transaction.savepoint()
>
Hi Karen,
Yes it does look as though I am using them backwards. I am at a bit of a
loss as to how to get around this problem, though it is Monday morning and
my brain isn't fully into gear yet. Can anyone think of a way for me to
bypass the transaction management? I believe that even if I execute
Hi Chris,
please explain in more depth what you want to do. If you
do rollback, all changes won't be written to the database. Even
all savepoints won't be stored.
Why do you want to rollback? If you want your changes
to get saved, you need to call transaction.commit() at the end.
ChrisStoyles s
Hi Thomas,
The reason I want to be able to rollback (but still commit by log entries)
is because it is sometimes valid for this particular view to throw an
exception and fail. If this happens, I need to rollback any model objects
that have been created and saved up to the point at which the view f
Chris Stoyles schrieb:
> Hi Thomas,
>
> The reason I want to be able to rollback (but still commit by log entries)
> is because it is sometimes valid for this particular view to throw an
> exception and fail. If this happens, I need to rollback any model objects
> that have been created and sav
On Mon, Jun 8, 2009 at 5:39 AM, Chris Stoyles wrote:
> Hi Thomas,
>
> The reason I want to be able to rollback (but still commit by log entries)
> is because it is sometimes valid for this particular view to throw an
> exception and fail. If this happens, I need to rollback any model objects
> th
The only log entries I want committed are the ones that tell me why a
roll-back occurred. What you've said below sounds like a good enough
solution, thanks for all your input.
Cheers,
Chris
On Mon, Jun 8, 2009 at 11:38 PM, Karen Tracey wrote:
> On Mon, Jun 8, 2009 at 5:39 AM, Chris Stoyles wro
8 matches
Mail list logo