Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
When the query used to retrieve terms to build the value form for a "Taxonomy: Term ID" filter is rewritten, only a single term is returned in the options.
The rewritten query use SELECT *
and when it is rewritten to contains a LEFT JOIN
(for instance, by the Private Taxonomy module), the columns of the additional tables are added to the results. In this case, this cause the tid
of the terms object returned by db_fetch_object
to be null. So at the end, only the last DB result will be present in the build $options
array.
Comment | File | Size | Author |
---|---|---|---|
#8 | views-1040744-8.patch | 981 bytes | earlofsandwich |
#1 | views-1040744.patch | 1.15 KB | pbuyle |
Comments
Comment #1
pbuyle CreditAttribution: pbuyle commentedThe attached patch fix this by restricting the results to the columns from the
term_data
table.Comment #2
janis_lv CreditAttribution: janis_lv commentedthank you, this fixed my problem too.
Comment #3
dawehnerIn general a critical bug is a big which breaks a site with a WSOD.
This then should exist for many users.
Here we have a critical issue with just two users. Anyway this still makes sense.
Could you check whether there is a change needed for 7.x-3.x?
Comment #4
pbuyle CreditAttribution: pbuyle commented7.x-3.x code uses the new DB API, so there is no change needed.
Comment #5
rickmanelius CreditAttribution: rickmanelius commentedI can confirm this now works, but a refresh is required and it took a few minutes to take hold.
I'd ask for this to be committed to the trunk because it really borked a lot of features I had on our production site and I'd hate to lose this fix in the next update.
Comment #6
dawehnerPatch looks fine
Commited to 6.x-3.x
Comment #8
earlofsandwich CreditAttribution: earlofsandwich commentedReopening this issue as it is also apparent in views 6.x-2.x (at least 2.14 upwards) - I noticed it happening when using Forum Access and my exposed filters stopped working for anonymous users.
I have created a patch for v6.x-2.16. It's my very first patch and I had to use a Windows box, so please be gentle.
Comment #9
dawehnerI actually thought that this patch is only worth for 6.x-3.x, but i think now it's important for 6.x-2.x as well.
So just used the previous patch. Thanks for providing the patch!
Comment #11
scooper CreditAttribution: scooper commentedI had a similar problem, posted here: http://drupal.org/node/1361044 . No one replied, then fortunately I found this issue. I applied the patch and my problem is now fixed also - using Views 6.x-2.16. The problem was introduced with Views 6.x-2.14.
What's the procedure to request that this patch be included in the next release of Views?
Comment #12
justindavis CreditAttribution: justindavis commentedHas this patch been committed to the 6.x-2.x series?
Comment #13
Jim Kirkpatrick CreditAttribution: Jim Kirkpatrick commentedOur server has 2.16 on it, and we had the "Illegal choice detected" on our panels pane views with TID passed as an exposed filter. I needed to manually apply the patch in #8 to get rid of the message...
So either our FTP messed up when I updated Views, or this patch has not yet made it to a proper release. In either case I'm re-opening this for clarity's sake.
Thanks.
Comment #14
dawehnerYou either have to download views 2.x-dev or wait for a future views 6.x-2.17
Comment #16
batdesign CreditAttribution: batdesign commentedReopening as the previously mentioned dev branch is now not available (don't know when it disappeared or why) and no sign of 6.x-2.17 yet.
Can we add this patch and release at least a 2.x-dev?
Comment #17
RedRat CreditAttribution: RedRat commentedYeah, we really need a working solution for this nasty bug, because a lot of sites still using Views 2.x version.
Comment #19
salvis#8 has been committed allright.
The problem is #14:
No 6.x-2.17 has ever been created and the -dev version has been hidden. We're left with a buggy 6.x-2.16 and no upgrade path.
Comment #20
pcorbett CreditAttribution: pcorbett commented#8: views-1040744-8.patch queued for re-testing.
Comment #21
RedRat CreditAttribution: RedRat commentedStill nobody can approve this trivial two-char patch?!
Comment #22
salvisIt is approved and committed, but there is no release package (not even the -dev package) fresh enough to contain the fix.
Comment #23
Chris Matthews CreditAttribution: Chris Matthews as a volunteer commentedThe Drupal 6 branch is no longer supported, please check with the D6LTS project if you need further support. For more information as to why this issue was closed, please see issue #3030347: Plan to clean process issue queue