| 124 | | When you save an Django object, some pre-processing will occur on the the data |
|---|
| 125 | | that is in the object. For example, if your model has a ``DateField`` with |
|---|
| 126 | | ``auto_now=True`` set, the pre-save phase will alter the data in the object |
|---|
| 127 | | to ensure that the date field contains the current date stamp. |
|---|
| 128 | | |
|---|
| 129 | | Although these automated changes can be very useful, there will be times when |
|---|
| 130 | | you just want to save the data as-is. In these cases, you can invoke a *Raw Save* |
|---|
| 131 | | by passing ``raw=True`` as an argument to the ``save()`` method:: |
|---|
| | 124 | **New in Django development version** |
|---|
| | 125 | |
|---|
| | 126 | When you save an Django object, some pre-processing might occur on the the |
|---|
| | 127 | object's data before it's saved to the database. For example, if your model has |
|---|
| | 128 | a ``DateField`` with ``auto_now=True`` set, the pre-save phase will alter the |
|---|
| | 129 | data in the object to ensure that the date field contains the current date |
|---|
| | 130 | stamp. |
|---|
| | 131 | |
|---|
| | 132 | Although these automated changes can be useful, sometimes you just want to save |
|---|
| | 133 | the data as-is. In these cases, you can invoke a **raw save** by passing |
|---|
| | 134 | ``raw=True`` as an argument to the ``save()`` method:: |
|---|