Scenario:
view set up with a contextual filter (biblio field "secondary title", compare image-0)
- Auto preview with contextual filter:
each value of "Bergischer Kalender" and "Rheinisch-Bergischer Kalender"
results in a valid result (see images 1 and 2)
- switching the contextual filter field to "allow multiple values" (image 3)
results in:
a) input "Rheinisch-Bergischer Kalender"
Result list is still valid (see image 4)
b) input "Bergischer Kalender)
Result list is empty (see image 5)
c) any syntax using "," or "+" combining both strings leads to empty output

Comments

Baber Javed’s picture

Subscribe, having same issue

dawehner’s picture

it would be kind of cool if you could display the running sql as well. You can enable this in the admin settings of views under admin/structure/views/settings.

schildi’s picture

of course, sorry

flag contextual filter field to "allow multiple values" NOT set

SELECT biblio.biblio_type AS biblio_tid, biblio.biblio_year AS biblio_biblio_year, biblio.biblio_volume AS biblio_biblio_volume, biblio.biblio_pages AS biblio_biblio_pages, node.nid AS nid, node.title AS node_title, biblio.biblio_alternate_title AS biblio_biblio_alternate_title, biblio.vid AS biblio_vid, CONCAT(LPAD('',3-CHAR_LENGTH(SUBSTRING_INDEX(REPLACE(biblio_pages,' ','-'),'-',1)),'000'),biblio_pages) AS bgv_biblio_pages
FROM
{node} node
LEFT JOIN {biblio} biblio ON node.vid = biblio.vid
LEFT JOIN {biblio_types} biblio_types ON biblio.biblio_type = biblio_types.tid
WHERE (( (biblio.biblio_secondary_title = 'Bergischer Kalender') )AND(( (node.status = '1') AND (node.type IN  ('biblio')) AND (biblio_types.tid IN  ('102')) )))
ORDER BY biblio_biblio_year DESC, biblio_biblio_volume ASC, bgv_biblio_pages ASC
LIMIT 250 OFFSET 0

flag contextual filter field to "allow multiple values" set

SELECT biblio.biblio_type AS biblio_tid, biblio.biblio_year AS biblio_biblio_year, biblio.biblio_volume AS biblio_biblio_volume, biblio.biblio_pages AS biblio_biblio_pages, node.nid AS nid, node.title AS node_title, biblio.biblio_alternate_title AS biblio_biblio_alternate_title, biblio.vid AS biblio_vid, CONCAT(LPAD('',3-CHAR_LENGTH(SUBSTRING_INDEX(REPLACE(biblio_pages,' ','-'),'-',1)),'000'),biblio_pages) AS bgv_biblio_pages
FROM 
{node} node
LEFT JOIN {biblio} biblio ON node.vid = biblio.vid
LEFT JOIN {biblio_types} biblio_types ON biblio.biblio_type = biblio_types.tid
WHERE (( (biblio.biblio_secondary_title IN  ('Bergischer', 'Kalender')) )AND(( (node.status = '1') AND (node.type IN  ('biblio')) AND (biblio_types.tid IN  ('102')) )))
ORDER BY biblio_biblio_year DESC, biblio_biblio_volume ASC, bgv_biblio_pages ASC
LIMIT 250 OFFSET 0

the difference is, that in the case "allow multiple values" the string "Bergischer Kalender" is split into a set of words.
Hint for avoiding confusion: The sequence CONCAT ... is set up to force sorting number (stored as strings) the right way by prepending zero digits ( "5-8" => 005-8")

dawehner’s picture

Status: Active » Closed (duplicate)

This seems to be more or less a duplicate of #1042546: Allow to replace spaces by dashes in links. The underlying problem is that there is no difference between "+" and " ", if you parse the url.