summaryrefslogtreecommitdiff
path: root/examples
Commit message (Collapse)AuthorAgeFilesLines
...
* - [feature] New declarative reflection exampleMike Bayer2012-01-282-0/+114
| | | | | | added, illustrates how best to mix table reflection with declarative as well as uses some new features from [ticket:2356].
* modernize adjacency list example, use declarativeMike Bayer2012-01-281-61/+48
|
* fix a usage issue hereMike Bayer2012-01-281-0/+3
|
* - [bug] Fixed large_collection.py to close theMike Bayer2012-01-221-1/+2
| | | | session before dropping tables. [ticket:2346]
* - [feature] Simplified the versioning exampleMike Bayer2012-01-223-43/+28
| | | | | | a bit to use a declarative mixin as well as an event listener, instead of a metaclass + SessionExtension. [ticket:2313]
* - Fixed bug in history_meta.py example whereMike Bayer2011-10-172-1/+7
| | | | | | the "unique" flag was not removed from a single-table-inheritance subclass which generates columns to put up onto the base.
* - Adjusted dictlike-polymorphic.py exampleMike Bayer2011-09-261-8/+9
| | | | | to apply the CAST such that it works on PG, other databases. [ticket:2266]
* - Fixed the attribute shard example to checkMike Bayer2011-06-261-11/+13
| | | | | for bind param callable correctly in 0.7 style.
* - Repaired the examples/versioning test runnerMike Bayer2011-06-164-7/+104
| | | | | | | | | | | to not rely upon SQLAlchemy test libs, nosetests must be run from within examples/versioning to get around setup.cfg breaking it. - Tweak to examples/versioning to pick the correct foreign key in a multi-level inheritance situation.
* update for new table modelMike Bayer2011-06-061-6/+21
|
* update docs for generic associationsMike Bayer2011-04-281-3/+10
|
* - removed the ancient "polymorphic association"Mike Bayer2011-04-278-491/+378
| | | | | | | examples and replaced with an updated set of examples that use declarative mixins, "generic_associations". Each presents an alternative table layout.
* - remove test.sql._base, test.engine._base, test.orm._base, move those ↵Mike Bayer2011-03-271-1/+1
| | | | | | | classes to a new test.lib.fixtures module - move testing.TestBase to test.lib.fixtures - massive search and replace
* - The horizontal_shard ShardedSession class accepts the commonMike Bayer2011-03-161-2/+2
| | | | | | | | Session argument "query_cls" as a constructor argument, to enable further subclassing of ShardedQuery. [ticket:2090] - The Beaker caching example allows a "query_cls" argument to the query_callable() function. [ticket:2090]
* - Updated the association, association proxy examplesMike Bayer2011-03-134-187/+255
| | | | | | to use declarative, added a new example dict_of_sets_with_default.py, a "pushing the envelope" example of association proxy.
* - Beaker example now takes into account 'limit'Mike Bayer2011-02-131-2/+5
| | | | | | and 'offset', bind params within embedded FROM clauses (like when you use union() or from_self()) when generating a cache key.
* add example usage for shard_id in context feature [ticket:2031]Mike Bayer2011-01-231-2/+15
|
* - rename hybrid.property_, hybrid.method to hybrid_property, hybrid_method. ↵Mike Bayer2011-01-121-35/+29
| | | | | | | more typing on the import but this is just clearer. - adapt dictlike-polymorphic.py to use hybrid.
* - whitespace removal bonanzaMike Bayer2011-01-0228-288/+288
|
* - removes the "on_" prefix.Mike Bayer2010-12-301-4/+4
|
* - mutable examples now move into sqlalchemy.ext.mutableMike Bayer2010-12-293-361/+0
| | | | | | | | | | | - streamline interfaces, get Mutable/MutableComposite to be as minimal in usage as possible - docs for mutable, warnings regrarding mapper events being global - move MutableType/mutable=True outwards, move orm tests to its own module, note in all documentation - still need more events/tests for correct pickling support of composites, mutables. in the case of composites its needed even without mutation. see [ticket:2009]
* - restore mapper.get_property() to use the _props dict. at the momentMike Bayer2010-12-282-2/+147
| | | | | | | | | | | | | | synonyms for relationships might just be taken out altogether, since they aren't documented and are of little use. a plain proxying descriptor, combined with attribute-based usage with Query (as opposted to naming it by string) can do the same thing more simply. - add event support to composites, change the model around so that the composite is generated at the point of load. - add a recipe for tracking mutations on composites. will probably make both of these mutations examples into extensions since they're intricate, should have a lot of test coverage, and what they need to do is fairly straightforward. Will use metaclasses so that no extra userland step is needed beyond usage of the type.
* - link to the events we useMike Bayer2010-12-261-0/+4
|
* - docs for mutable events exampleMike Bayer2010-12-261-2/+28
|
* - add a new "on mapper configured" event - handy !Mike Bayer2010-12-252-28/+62
|
* - restore declarative support for "composite"Mike Bayer2010-12-232-0/+152
| | | | - add an example of mutable scalars with events
* - fix beaker caching example to use new ".callable" param on bindMike Bayer2010-12-221-9/+14
|
* - merge versioning example fix from 0.6Mike Bayer2010-12-202-12/+73
|
* - gently push users towards entity name for simple casesMike Bayer2010-12-071-3/+13
|
* new calling style: event.listen(target, identifier, fn)Mike Bayer2010-12-011-4/+4
|
* - NullPool is now used by default for SQLite file-Mike Bayer2010-11-281-2/+5
| | | | | | based databases. :memory: databases will continue to select SingletonThreadPool by default. [ticket:1921]
* - merge mapper simpler compile branch, [ticket:1966]Mike Bayer2010-11-261-1/+1
|\
| * [ticket:1966] implementationMike Bayer2010-11-151-1/+1
| |
* | - merge hybrid attributes branch, [ticket:1903]Mike Bayer2010-11-202-178/+0
|\ \
| * \ merge tipMike Bayer2010-11-1410-94/+97
| |\ \ | | |/
| * | merge tipMike Bayer2010-09-142-4/+21
| |\ \
| * \ \ merge latest tipMike Bayer2010-09-031-0/+8
| |\ \ \
| * \ \ \ merge tipMike Bayer2010-08-271-0/+8
| |\ \ \ \
| * \ \ \ \ merge from tipMike Bayer2010-08-242-2/+25
| |\ \ \ \ \
| * \ \ \ \ \ merge tipMike Bayer2010-08-149-179/+246
| |\ \ \ \ \ \
| * | | | | | | - add hybrid extensionMike Bayer2010-08-062-134/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - mapper begins to lose awareness of SynonynmProperty, ComparableProperty
* | | | | | | | - merge tipMike Bayer2010-11-066-52/+54
|\ \ \ \ \ \ \ \ | | |_|_|_|_|_|/ | |/| | | | | |
| * | | | | | | - remove remaining create_session() calls from examples, replace with SessionMike Bayer2010-10-246-52/+54
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - replace all flush()/expunge_all() with commit()
* | | | | | | | - add instrumentation eventsMike Bayer2010-10-021-33/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - simplify listen_for_events example with new system - add "propagate", "retval", "raw" flags to attribute events. this solves the "return value" issue as well as the "subclass" issue. - begin thinking about event removal. Each listen() method will have a corresponding remove(). Custom listen() methods will have to package all the info onto the event function that is needed to remove its state.
* | | | | | | | merge tipMike Bayer2010-10-024-42/+43
|\ \ \ \ \ \ \ \ | |/ / / / / / /
| * | | | | | | - optimized_al doesn't need mapper extensionMike Bayer2010-09-244-42/+43
| | |_|_|_|_|/ | |/| | | | | | | | | | | | | | | | | | | - convert to non-bound metadata, Session, session.commit()
* | | | | | | - reorganizationMike Bayer2010-09-141-1/+2
|/ / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - attrbutes.py splits into attribtes.py and instrumentation.py - all the various Event subclasses go into events.py modules - some ideas for orm events - move *Extension out to deprecated_interfaces
* | | | | | - the versioning example works correctly nowMike Bayer2010-09-052-5/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | if versioning on a col that was formerly NULL.
* | | | | | - mapper _get_col_to_prop private method usedMike Bayer2010-09-051-2/+4
| |_|_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | by the versioning example is deprecated; now use mapper.get_property_by_column() which will remain the public method for this. - turned TODO in the history example into an assertion with a descriptive reason
* | | | | - a large hill to climb. Added declarative examples to all theMike Bayer2010-08-302-44/+98
| |_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | "basic relationship" examples, cleaned up the examples and added some more explicitness. Also renamed "treenodes" to "nodes" and added self-referential declarative example. - Added info/examples on how to join tables directly when querying with joined table inheritance. - Starting to talk about hybrids in the main mapper docs some more. introducoed the idea that synonyms are on their way out. - SQL expressions as mapped attributes also gets better verbiage, alternative approaches to them, including hybrids. - modernized the hybrid example. - object_session() as a standalone function wasn't documented ?!