NetTalk Central

NetTalk Web Server => Web Server - Ask For Help => Topic started by: broche on August 12, 2014, 01:53:27 PM

Title: Filter Defaults
Post by: broche on August 12, 2014, 01:53:27 PM
NT 8.23
CL 9.0

Am I corretc in the following:

If a filter has been defined on a browse and it fails then all the records will be displayed?

Brian.
Title: Re: Filter Defaults
Post by: kevin plummer on August 12, 2014, 04:05:20 PM
yes if it is "invalid". I'm not sure what you mean by fails.

Title: Re: Filter Defaults
Post by: broche on August 12, 2014, 05:42:20 PM
Yes - Invalid is a better word.
If the Filter is invalid I want to make sure that no records show - is this possible.

Thanks.
Title: Re: Filter Defaults
Post by: Bruce on August 12, 2014, 10:28:49 PM
no it's not possible. The filter is processed by the clarion View engine - which usually passes it on to the back-end. What you get back is what you get back.

cheers
Bruce
Title: Re: Filter Defaults
Post by: Poul on August 13, 2014, 07:54:03 AM
on many of my nettalk browses  i have used

 
Code: [Select]
if loc:FilterWas and EVALUATE( loc:FilterWas) = ''
    ThisView{prop:Filter} = '1=3'
     packetdebugme.append('<tr><13,10><td>' &  'Invalid Search Criteria '  & loc:FilterWas &'</td></tr>'& P_web.CRLF)
    do AddPacket
  end

after "setview"  embed - works for SQL, i have not tried anywhere else ...
Title: Re: Filter Defaults
Post by: Bruce on August 13, 2014, 11:13:41 PM
yes, I can see this would likely do the trick, and the processing cost is minimal.