Yes, it is possible, but you will have to add related_name to each of
the relationships to the same table. See here:
http://www.djangoproject.com/documentation/models/m2m_and_m2o/

Also I would suggest you to rename "created" to "creator" and "access"
to "accessors", although it is not a big deal.

Good luck!
Aidas Bendoraitis [aka Archatas]

On 7/25/06, PythonistL <[EMAIL PROTECTED]> wrote:
>
> Is possible to have ManyToMany and OneToMany relation like this?
>
> class User(meta.Model):
>       Login=meta.CharField(maxlength=50,unique=True)
>        Email=meta.EmailField(_('e-mail address'),blank=True)
>
> class Gallery(meta.Model):
>     Title = meta.CharField(_("title"), maxlength=80)
>     created = meta.ForeignKey(User)
>     access=meta.ManyToManyField(User)
>
>
> Thank you for help
> L.
>
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to