------
The ``where`` clause can now accept multiple arguments (courtesy AliSayyah):
.. code-block:: python
Concert.select().where(
Concert.venue.name == 'Royal Albert Hall',
Concert.band_1.name == 'Pythonistas'
).run_sync()
It's another way of expressing `AND`. It's equivalent to both of these:
.. code-block:: python
Concert.select().where(
Concert.venue.name == 'Royal Albert Hall'
).where(
Concert.band_1.name == 'Pythonistas'
).run_sync()
Concert.select().where(
(Concert.venue.name == 'Royal Albert Hall') & (Concert.band_1.name == 'Pythonistas')
).run_sync()
Added a ``create`` method, which is an easier way of creating objects (courtesy
AliSayyah).
.. code-block:: python
This still works:
band = Band(name="C-Sharps", popularity=100)
band.save().run_sync()
But now we can do it in a single line using `create`:
band = Band.objects().create(name="C-Sharps", popularity=100).run_sync()
Fixed a bug with ``piccolo schema generate`` where columns with unrecognised
column types were omitted from the output (courtesy AliSayyah).
Added docs for the ``--trace`` argument, which can be used with Piccolo
commands to get a traceback if the command fails (courtesy hipertracker).
Added ``DoublePrecision`` column type, which is similar to ``Real`` in that
it stores ``float`` values. However, those values are stored at greater
precision (courtesy AliSayyah).
Improved ``AppRegistry``, so if a user only adds the app name (e.g. ``blog``),
instead of ``blog.piccolo_app``, it will now emit a warning, and will try to
import ``blog.piccolo_app`` (courtesy aliereno).
-------------------------------------------------------------------------------