Skip to Content

How can i filter by excluding values from a data source?

Nov 24, 2016 at 12:11 AM


avatar image
Former Member

I have a BW query with the following results:

  • first Item
  • second item
  • otheri tems (group of 3 items)
  • not assigned (group of many items)

I do not want "not assigned" items

I checked on internet ( excluding filter ) and i have to put "!" before tha value like that:

!value1; ! value!;

in the input by string area for exluding values but it doesn't work with any item i would like to remove from the list.

I tried to do also a workaround where i filter the graphic object (listbox, crosstab and dropdown menu) with the following code (in global script area):

/*removing all items, and adding only the items i need but it's not dynamic */
LISTBOX_1.addItem("CG0A13", "APEROL");


I have checked also that only the crosstab mantains a hierarchy and filters of query BW, in the listbox and dropdown menu i see all the value

I would like to get:

  • 1) firstItem
  • 2) seconditem
  • 3)otheritems (group of 3 items)
  • 4) not assigned
  • instead i get:

    • 1) firstItem
    • 2) seconditem
    • 3)thirditem
    • 4)fourthitem
    • ...
    • 120) lastitem
    • 10 |10000 characters needed characters left characters exceeded
      * Please Login or Register to Answer, Follow or Comment.

      2 Answers

      Tammy Powlas
      Nov 24, 2016 at 02:47 AM

      Have you checked your syntax, similar to what Victor describes in this thread?

      10 |10000 characters needed characters left characters exceeded
      avatar image
      Former Member Nov 24, 2016 at 11:34 AM

      I tried by input string :

      • setfilterExt ("id_structure", "!keyvalue");
      • setfilterExt ("name_structure", "!keyvalue");

      by global script:

      • DS_1.setFilterExt("name_structure",
      • var filterExt = "CG0A13";
        selectedValues.forEach(function(valueElement, index) {  
        filterExt = filterExt + "!" + valueElement + ";";
        BRAND.setFilterExt("0MATERIAL__0PRODH2", filterExt);<br>

      but nothing happens!


      10 |10000 characters needed characters left characters exceeded