On Fri, Mar 21, 2014 at 5:43 AM, Russell Keith-Magee <
russ...@keith-magee.com> wrote:

>
> On Thu, Mar 20, 2014 at 6:50 PM, Venkatraman S <venka...@gmail.com> wrote:
>
>>
>> On Sat, Mar 15, 2014 at 7:11 AM, Russell Keith-Magee <
>> russ...@keith-magee.com> wrote:
>>
>>>
>>> On Sat, Mar 15, 2014 at 7:19 AM, Jonathan Baker <
>>> jonathandavidba...@gmail.com> wrote:
>>>
>>>> Does that mean that the default="" functionality is implemented by the
>>>> ORM, instead of in the database layer?
>>>>
>>>> This is correct - Django's "default" argument is an API level default,
>>> not a database level default.
>>>
>>>
>> @Russ, any specific reasons for this choice?
>>
>
> Honestly - not a clue. It was like that when I got here, so the reasons
> are probably lost in the depths of time. :-)
>
> Trying to reverse engineer the decision, the most likely reason is that
> Django has allowed callable defaults; if you define a callable in your
> Django model as a default, there's no way to pass this down to the database
> (or, at least, not an easy way).
>
>
This helped me in one of the cases just now and it was an Aha moment!
 Never realized that this feature would be so darn useful. Thanks devs.

-V
@venkasub <http://about.me/venkasub>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAN7tdFSNenu0YWOaipq-fK-G_5NhitQQGMCJfPzexXMteBy7BA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to