close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Coding Issue

Thread began 5/14/2019 8:22 am by vernon webb | Last modified 5/15/2019 12:05 pm by Ray Borduin | 446 views | 6 replies |

vernon webb

Coding Issue

The following code confuses me as it all seems to reference the same thing.

$searchWADAtimes_1->setSearch(array("type"=>"Value", "comparison"=>"IS NOT", "join"=>"AND"), array("times.internalRating"), "s", "" .(isset($_GET["excludeRS5"])?"NULL":"") ."");
$searchWADAtimes_1->setSearch(array("type"=>"Value", "comparison"=>"<>", "join"=>"AND"), array("times.internalRating"), "s", "" .(isset($_GET["excludeRS5"])?"WA_BLANK":"") ."");
$searchWADAtimes_1->setSearch(array("type"=>"Edit", "comparison"=>"<>", "join"=>"AND"), array("times.internalRating"), "s", "excludeRS5");

On RSAVVY, under TIME MANAGEMENT > SEARCH there is a "With Rating" checkbox. All appears to be working fine, I'm just not sure why all that is needed and if something doesn't need to be there. What I am trying to do is create an opposite of that "Without Rating" whereas if it's not checked, it gives everything. The checkbox would now be excludeRS7. So I guess the question is tow fold. How would I create the opposite and why all that extra stuff, do I need it all?

Sign in to reply to this post

Ray BorduinWebAssist

It looks like the second and third rows are repeats and wouldn't both need to be there. The first and second row make more sense because the first one accounts for null in the column.

Sign in to reply to this post
Did this help? Tips are appreciated...

vernon webb

OK so I figured it out. So how do I make it return the opposite?
This returns anything that has a internalRating:

$searchWADAtimes_1->setSearch(array("type"=>"Value", "comparison"=>"<>", "join"=>"AND"), array("times.internalRating"), "s", "" .(isset($_GET["excludeRS5"])?"WA_BLANK":"")  ."");


I've created a checkbox that says Without Rating, which is "excludeRS7"

Sign in to reply to this post

Ray BorduinWebAssist

If you change:
"comparison"=>"<>"

to:
"comparison"=>"="

That should be the opposite.

Sign in to reply to this post
Did this help? Tips are appreciated...

vernon webb

One would think, however, if I do a search on Time Management, and select 2019-05-01 to 2019-05-01 I come up with 105 records. If I do "With Rating" I get 8 records. If I do "Without Rating" I get 10 records. The opposite should be 96 records.

Sign in to reply to this post

Ray BorduinWebAssist

The search wasn't accounting for NULL values. I've updated the page to fix the problem.

Sign in to reply to this post
Did this help? Tips are appreciated...

vernon webb

Thank you sir.

Sign in to reply to this post

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...