summaryrefslogtreecommitdiff
path: root/doc/build/orm/examples.rst
blob: 03d69cf4cbefcd872a1b22a888d463edecdbf138 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
.. _examples_toplevel:

Examples
========

The SQLAlchemy distribution includes a variety of code examples illustrating a select set of patterns, some typical and some not so typical.   All are runnable and can be found in the ``/examples`` directory of the distribution.   Each example contains a README in its ``__init__.py`` file, each of which are listed below.

Additional SQLAlchemy examples, some user contributed, are available on the wiki at `<http://www.sqlalchemy.org/trac/wiki/UsageRecipes>`_.

.. _examples_adjacencylist:

Adjacency List
--------------

Location: /examples/adjacency_list/

.. automodule:: adjacency_list

.. _examples_associations:

Associations
------------

Location: /examples/association/

.. automodule:: association


.. _examples_instrumentation:

Attribute Instrumentation
-------------------------

Location: /examples/custom_attributes/

.. automodule:: custom_attributes

.. _examples_caching:

Dogpile Caching
---------------

Location: /examples/dogpile_caching/

.. automodule:: dogpile_caching

Directed Graphs
---------------

Location: /examples/graphs/

.. automodule:: graphs

Dynamic Relations as Dictionaries
----------------------------------

Location: /examples/dynamic_dict/

.. automodule:: dynamic_dict

.. _examples_generic_associations:

Generic Associations
--------------------

Location: /examples/generic_associations

.. automodule:: generic_associations

.. _examples_sharding:

Horizontal Sharding
-------------------

Location: /examples/sharding

.. automodule:: sharding

Inheritance Mappings
--------------------

Location: /examples/inheritance/

.. automodule:: inheritance

Large Collections
-----------------

Location: /examples/large_collection/

.. automodule:: large_collection

Nested Sets
-----------

Location: /examples/nested_sets/

.. automodule:: nested_sets

Polymorphic Associations
------------------------

See :ref:`examples_generic_associations` for a modern version of polymorphic associations.

.. _examples_postgis:

PostGIS Integration
-------------------

Location: /examples/postgis

.. automodule:: postgis

Versioned Objects
-----------------

Location: /examples/versioning

.. automodule:: versioning

Vertical Attribute Mapping
--------------------------

Location: /examples/vertical

.. automodule:: vertical

.. _examples_xmlpersistence:

XML Persistence
---------------

Location: /examples/elementtree/

.. automodule:: elementtree