I'd say if

>>     constraints = (
>>         ('check_foo',
>>         Check(field__gte=100) | Check(field__lte=42)
>>         )
>>     )
> 
> This is supported.

then adding this

>>     constraints = (
>>         ('check_foo',
>>         Check(Q(field__gte=100) | Q(field__lte=42))
>>         )
>>     )
> 
> This too I haven't thought of....studying this feasibility.

becomes superfluous.  As long as there's *a* way to do
logical-or'ing together, there's not really an impelling reason
to provide *more* ways to do it (unless this were a perl framework).

>>    CREATE TABLE "appname_manufacturerer" (
>>         ...
>>         CONSTRAINT "appname_manufacturer__check_name"
>>         CHECK ("mfg_name" like 'Merc%%'),
>>         ...
>>    );
> 
> One more item in my todo list now.

I'm not sure if it should use a single or double underscore to
separate them.  I think other constraints only use a single one.
 However, I don't know how this behaves if one has a model or an
app with an underscore in its name (if that's even allowed).  I
suppose if folks do pathological stuff, they deserve the
headaches they get :)

>> 4) do the constraints get dropped properly when doing a DB purge
>> (using "manage.py sqlclear" or "manage.py sqlreset")?
> 
> Yes they do get dropped cleanly.

Good to hear.  Keep up the good work on this fine project!

-tim





--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to