1. Michael Bayer
  2. sqlalchemy
  3. Issues


Issue #1730 closed

add examples to docstrings for every function in sqlalchemy.sql, every method in sqlalchemy.orm.Query

Michael Bayer
repo owner created an issue

No description provided.

Comments (6)

  1. Michael Bayer reporter

    Just a simple example, i.e.::

        Set the from_obj parameter of the query and 
         return the newly resulting Query. This replaces
        the table which this Query selects from with the given table.
        select_from() also accepts class arguments. Though usually 
        not necessary, can ensure that the full selectable of the 
        given mapper is applied, e.g. for joined-table mappers.
             session.query(user.c.id, addresses.c.email).select_from(users.join(addresses))
  2. Log in to comment