Re: problem with django tagging application
See the changes listed here: http://code.google.com/p/django-tagging/wiki/BackwardsIncompatibleChanges you may be able to give directly the queryset rather than the model On Thu, Feb 21, 2008 at 1:25 AM, cesco <[EMAIL PROTECTED]> wrote: > Hi, > > I'm using the latest version of the django tagging application (rev. > 132) and I'm having problems with the get_by_model method of the > TaggedItem manager. > > Say I have a QuerySet1 generated as follow: > QuerySet1 = TaggedItem.objects.get_by_model(MyModel, 'tag1') > and a QuerySet2 generated as follow: > QuerySet2 = TaggedItem.objects.get_by_model(MyModel, 'tag2') > > If at this point I try to '&' the two query sets as in: > QuerySet3 = QuerySet1 & QuerySet2 > then I get the following error: > "ambiguous column name: tagging_taggeditem.object_id" > > Do you have any idea of why I'm getting this error and how I could > solve the problem? > For completeness in dpaste is the complete traceback I get: > http://dpaste.com/36177/ > > Any help would be very appreciated. > > Thanks > Francesco > --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
Re: problem with django tagging application
Hi, > Any chance you were using django-tagging previously and recently > updated to trunk? There are backwards incompatible changes - the > relation names have > changed:http://code.google.com/p/django-tagging/wiki/BackwardsIncompatibleCha... I was actually getting the same error before and after the updates. Thanks anyway Francesco --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
Re: problem with django tagging application
Hi > So the SQL that is being constructed by the joined queryset isn't valid. > I'm almost certain the answer to this is "it's fixed in > queryset-refactor, so will one day be fixed in trunk." Thanks for the work you are doing:-) > Pull the results back into Python and merge them manually. Could I ask you to be a bit more specific (not so experienced with python and django)? You mean I should take the two query sets separately and merge them based on the id of the objects in each of the querysets? Thanks again Francesco --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
Re: problem with django tagging application
Any chance you were using django-tagging previously and recently updated to trunk? There are backwards incompatible changes - the relation names have changed: http://code.google.com/p/django-tagging/wiki/BackwardsIncompatibleChanges -Brian On Feb 20, 4:25 pm, cesco <[EMAIL PROTECTED]> wrote: > Hi, > > I'm using the latest version of the django tagging application (rev. > 132) and I'm having problems with the get_by_model method of the > TaggedItem manager. > > Say I have a QuerySet1 generated as follow: > QuerySet1 = TaggedItem.objects.get_by_model(MyModel, 'tag1') > and a QuerySet2 generated as follow: > QuerySet2 = TaggedItem.objects.get_by_model(MyModel, 'tag2') > > If at this point I try to '&' the two query sets as in: > QuerySet3 = QuerySet1 & QuerySet2 > then I get the following error: > "ambiguous column name: tagging_taggeditem.object_id" > > Do you have any idea of why I'm getting this error and how I could > solve the problem? > For completeness in dpaste is the complete traceback I > get:http://dpaste.com/36177/ > > Any help would be very appreciated. > > Thanks > Francesco --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
Re: problem with django tagging application
On Wed, 2008-02-20 at 16:25 -0800, cesco wrote: > Hi, > > I'm using the latest version of the django tagging application (rev. > 132) and I'm having problems with the get_by_model method of the > TaggedItem manager. > > Say I have a QuerySet1 generated as follow: > QuerySet1 = TaggedItem.objects.get_by_model(MyModel, 'tag1') > and a QuerySet2 generated as follow: > QuerySet2 = TaggedItem.objects.get_by_model(MyModel, 'tag2') > > If at this point I try to '&' the two query sets as in: > QuerySet3 = QuerySet1 & QuerySet2 > then I get the following error: > "ambiguous column name: tagging_taggeditem.object_id" So the SQL that is being constructed by the joined queryset isn't valid. I'm almost certain the answer to this is "it's fixed in queryset-refactor, so will one day be fixed in trunk." > Do you have any idea of why I'm getting this error and how I could > solve the problem? Pull the results back into Python and merge them manually. Malcolm -- If it walks out of your refrigerator, LET IT GO!! http://www.pointy-stick.com/blog/ --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
problem with django tagging application
Hi, I'm using the latest version of the django tagging application (rev. 132) and I'm having problems with the get_by_model method of the TaggedItem manager. Say I have a QuerySet1 generated as follow: QuerySet1 = TaggedItem.objects.get_by_model(MyModel, 'tag1') and a QuerySet2 generated as follow: QuerySet2 = TaggedItem.objects.get_by_model(MyModel, 'tag2') If at this point I try to '&' the two query sets as in: QuerySet3 = QuerySet1 & QuerySet2 then I get the following error: "ambiguous column name: tagging_taggeditem.object_id" Do you have any idea of why I'm getting this error and how I could solve the problem? For completeness in dpaste is the complete traceback I get: http://dpaste.com/36177/ Any help would be very appreciated. Thanks Francesco --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---