mirror of
https://github.com/django/django.git
synced 2025-08-04 10:59:45 +00:00
Fixed #32060 -- Added Random database function.
This commit is contained in:
parent
f87b0ecd37
commit
06c5d3fafc
12 changed files with 51 additions and 27 deletions
|
@ -1114,6 +1114,15 @@ It can also be registered as a transform. For example::
|
|||
>>> # Get vectors whose radians are less than 1
|
||||
>>> vectors = Vector.objects.filter(x__radians__lt=1, y__radians__lt=1)
|
||||
|
||||
``Random``
|
||||
----------
|
||||
|
||||
.. class:: Random(**extra)
|
||||
|
||||
.. versionadded:: 3.2
|
||||
|
||||
Returns a random value in the range ``0.0 ≤ x < 1.0``.
|
||||
|
||||
``Round``
|
||||
---------
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue