NetTalk Central

Author Topic: Filtering a dropList  (Read 3408 times)

terryd

  • Hero Member
  • *****
  • Posts: 759
    • View Profile
    • Davcomm
    • Email
Filtering a dropList
« on: May 14, 2014, 01:57:16 AM »
In the "start of Option Filter & Order" embed point of an application I have
     IF p_web.getSessionLevel() <= 4 !Dealers
          WOR:OrderStatusID_OptionView{prop:filter} = p_web.CleanFilter(WOR:OrderStatusID_OptionView,'WOS:DisplayOrder <= 2 ')
      END
Which works fine. It only displays the WOS:DisplayOrder = 1 and     WOS:DisplayOrder = 2 records.
I now want to also display WOS:DisplayOrder = 5
I tried
     IF p_web.getSessionLevel() <= 4 !Dealers
          WOR:OrderStatusID_OptionView{prop:filter} = p_web.CleanFilter(WOR:OrderStatusID_OptionView,'WOS:DisplayOrder <= 2 AND WOS:DisplayOrder = 5 ')
      END
but nothing is displayed in the drop down.

What is the correct command?
Terry Davidson
Windows 10 64 bit/Windows7 64bit
Clarion 9.1.11529/Clarion10 12567
Nettalk 913
Nettalk 1015
StringTheory267/Winevent515/XFiles298/MessageBox239/Cryptonite186

kevin plummer

  • Hero Member
  • *****
  • Posts: 1195
    • View Profile
    • Production Accounting and Software Payroll
Re: Filtering a dropList
« Reply #1 on: May 14, 2014, 03:57:50 AM »
on the template tick the box to send the filter to debug view

jari@softmade.fi

  • Full Member
  • ***
  • Posts: 134
    • View Profile
    • Email
Re: Filtering a dropList
« Reply #2 on: May 14, 2014, 04:37:12 AM »
WOS:DisplayOrder <= 2 AND WOS:DisplayOrder = 5 is impossible

Regards Jari

debzidoodle

  • Jr. Member
  • **
  • Posts: 98
    • View Profile
    • Email
Re: Filtering a dropList
« Reply #3 on: May 14, 2014, 05:07:43 AM »
Quote
WOS:DisplayOrder <= 2 AND WOS:DisplayOrder = 5 is impossible

I think you are wanting this
Code: [Select]
WOS:DisplayOrder <= 2 OR WOS:DisplayOrder = 5

terryd

  • Hero Member
  • *****
  • Posts: 759
    • View Profile
    • Davcomm
    • Email
Re: Filtering a dropList
« Reply #4 on: May 14, 2014, 10:00:58 PM »
Thanks everyone. I can't believe after 30 years I can make a stupid mistake line using AND when I should use OR.
Maybe sometimes there are stupid questions.
against stupidity the gods themselves contend in vain
« Last Edit: May 14, 2014, 10:14:25 PM by terryd »
Terry Davidson
Windows 10 64 bit/Windows7 64bit
Clarion 9.1.11529/Clarion10 12567
Nettalk 913
Nettalk 1015
StringTheory267/Winevent515/XFiles298/MessageBox239/Cryptonite186