Warning: Can't synchronize with repository "(default)" (Unsupported version control system "svn": No module named svn). Look in the Trac log for more information.

Changes between Version 14 and Version 15 of UsingSqlAlchemy


Ignore:
Timestamp:
08/21/06 11:49:54 (13 years ago)
Author:
alberto
Comment:

Mentioning that SA transactions are automatically comitted like with SO since [1600].

Legend:

Unmodified
Added
Removed
Modified
  • UsingSqlAlchemy

    v14 v15  
    2424rather simply by adding sqlalchemy-knowledgable conditions to the RuleDispatch 
    2525checks in ``formmaker.py``. You will also lose the use of CatWalk/ModelDesigner 
    26 and will have to explicitly call ``objectstore.commit()`` in your controller 
    27 (i.e. transactions are not implicit). 
     26~~and will have to explicitly call ``objectstore.commit()`` in your controller 
     27(i.e. transactions are not implicit).~~ (I believe this isn't true since [1600], transactions are automatically committed by run_with_transaction)  
    2828 
    2929This document initially covered 0.1.0 release and was written on February 13, 2006. It was updated on August 21, 2006 for SQLAlchemy 0.2 and improved TurboGears' support. 
     
    7070in ``tg-admin shell`` by simply ``engine.echo = 1`` in the interpreter. 
    7171 
    72 Be aware that SQLAlchemy has transactions on all the time via the 
     72~~Be aware that SQLAlchemy has transactions on all the time via the 
    7373Unit of Work abstraction and they are **NOT** implicit. This means that you 
    7474need to call ``objectstore.commit()`` to push your changes to the db, even in 
    7575the controller methods. If you're running an ``assign_mapper`` object, you can 
    7676call the object's ``commit()`` directly to commit the object. A UoW rollback is 
    77 ``objectstore.clear()``. 
     77``objectstore.clear()``.~~ (I believe this isn't true since [1600], transactions are automatically committed by run_with_transaction) 
    7878 
    7979You can change a column's name using the ``alias`` parameter of the ``Column``