Add also the own productcode to the tags.
So at product with productcode 0000 have 0000,1111,2222,3333
Then, on product 0000, you will get all resources which have the tag 0000,1111,2222 or 3333 but not the current product, with my snippet-call.
It will allways search for products, which have one of the tags, of the current resource.
Isn't it that, what you want?
take this snippet-call
[[TaggerGetRelatedWhere? &groups=`1`]]
make sure, you use the correct tagger-group-id
and post here, what it returns.
this snippet
https://github.com/modxcms/Tagger/blob/master/core/components/tagger/elements/snippets/taggergetrelatedwhere.snippet.php
takes the tags of the current resource and creates a query, to get all resources, which have one of the tags of the current resource.
I added this snippet to tagger for exactly that, to get resources, which have related tags.
if you are inside another getResources - tpl, you can try:
[[TaggerGetRelatedWhere? &groups=`1` &resources=`[[+id]]`]]
{"id:not IN":[67],"0":"EXISTS (SELECT 1 FROM `modx_tagger_tag_resources` r WHERE r.tag IN (2) AND r.resource = modResource.id)"}
yeah. The current resource is 67 and has only one tag, which is the tag with id 2
This will get all resources, which have also the tag with that same id.
well, you forgot the &where=
&where=`[[TaggerGetRelatedWhere? &groups=`1`&resources=`[[+id]]`]]`