Re: South doesn't recognize modification in ManytoMany fields

2013-08-14 Thread Arnold Krille
Hi,

On Thu, 15 Aug 2013 03:31:08 +0530 Pradeep Kumar 
wrote:
> I have made a model change from
> standard = models.ManyToManyField(Standard)
> to
> standard = models.ManyToManyField(Standard, blank = True, null = True)
> South schemamigration for this app doesn't recognize the change ?

I don't see a difference between these two? Both say that you want to
have zero or more connections from each item in your model to the items
of Standard. And zero or more connections from each Standard-item to
items in your model.

M2M are done with an intermediate table. But why do you want to add
lines in that table that have an entry to your model but no entry for
'Standard'? Its the same as if no entry in the intermediate.

I think what django (and south) do is just ignore blank- and
null-parameters.

Have fun,

Arnold


signature.asc
Description: PGP signature


Re: South doesn't recognize modification in ManytoMany fields

2013-08-14 Thread Mike Dewhirst

On 15/08/2013 8:01am, Pradeep Kumar wrote:

I have made a model change from

standard = models.ManyToManyField(Standard)

to

standard = models.ManyToManyField(Standard, blank = True, null =
True)

South schemamigration for this app doesn't recognize the change ?


I think it is probably not necessary to migrate that change because the 
ORM probably controls Null. Blank is definitely an ORM thing. It depends 
I suppose on the defaults used with your database.


I would guess you would see an error if the ORM contradicted the 
database settings for that column.


If the column in question is already set for Not null = False, what is 
there for South to do?


Mike



http://stackoverflow.com/questions/18243039/south-migrating-foriegn-key-many-to-many-field-to-null-true-blank-true-doesnt



Similar to the question link below, it's unanswered !

South migrations and changes to many-to-may fields


 any idea? Please help !

-- 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. For more options, visit
https://groups.google.com/groups/opt_out.


--
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.
For more options, visit https://groups.google.com/groups/opt_out.


South doesn't recognize modification in ManytoMany fields

2013-08-14 Thread Pradeep Kumar
I have made a model change from

standard = models.ManyToManyField(Standard)

to

standard = models.ManyToManyField(Standard, blank = True, null = True)

South schemamigration for this app doesn't recognize the change ?

http://stackoverflow.com/questions/18243039/south-migrating-foriegn-key-many-to-many-field-to-null-true-blank-true-doesnt


Similar to the question link below, it's unanswered !

South migrations and changes to many-to-may
fields

any idea? Please help !

-- 
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.
For more options, visit https://groups.google.com/groups/opt_out.