Im having a problem where using an Exposed Node:Type Filter, with an Unlocked Operator.

On first load of the view all items are displayed, and the query includes:

WHERE node.type in ('content_type_1','content_type_2','content_type_3')

However as soon as I select a specific item (Content Type 1 for example), the WHERE clause produces a string of zeroes.

WHERE node.type in ('0','0','0')

If I remove the Unlocked Operator the problem goes away.

CommentFileSizeAuthor
#8 Clipboard01.jpg27.52 KBAnonymous (not verified)
#5 views-fix-node.patch766 bytesdawehner

Comments

xtfer’s picture

I can now reproduce this problem on two different sites using both the 6.26 and Dev version of this module...

claudiu.cristea’s picture

I'm facind the same issue... after upgrading to 6.x-2.6.

claudiu.cristea’s picture

The "IN" handler views_handler_filter_in_operator.inc was modified in the near past... I suspect that the bug is there...

nicknickoli’s picture

Also having the same problem. Subscribing

dawehner’s picture

Status: Active » Needs review
StatusFileSize
new766 bytes

This fixes the problem, but i'm not sure whether it fixes all possible issues.

I cannot remember why i named the patch like this... :)

merlinofchaos’s picture

dereine: You should read the comment above the change you make.

merlinofchaos’s picture

Status: Needs review » Needs work
Anonymous’s picture

StatusFileSize
new27.52 KB

I have another variation of the same issue.
With an exposed node type filter, selecting a node type from the dropdown will pass the selected option to the query but the first character gets rewritten.

Examples:
Selecting "Page" from the dropdown results in a query of "WHERE node.type in ('sage')"
Selecting "Product" from the dropdown results in a query of "WHERE node.type in ('sroduct')"
Selecting "Rule" from the dropdown results in a query of "WHERE node.type in ('sule')"

I tested this on multiple drupal sites utilizing views-6.x-2.6, the same error occurs, except the "new" first-character is not always "s".

I hope my observations will be helpful.

merlinofchaos’s picture

I used to see this happen after I had unchecked 'remember' but still had bad values that were no longer relevant in the session. Does this continue to happen after clearing out your session? (Log out and log back in , for example)

esmerel’s picture

Status: Needs work » Closed (fixed)

No updates in more than 6 months