close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Return null values

Thread began 9/05/2013 8:38 am by Meic Delwedd | Last modified 9/05/2013 2:03 pm by Jason Byrnes | 874 views | 4 replies |

Meic Delwedd

Return null values

Hi,

I have been trying to get data assist to return blank/null values as well as events that have passed the current time.

Basically, I have an events database, where when a customer opens the page, the events from the current date onward are displayed.

Now, the customer wants current time to be included in the filter, so if a user visits the website, and events that have been that day are also ignored.

I have managed to get that working, no problem.

My issue is certain events in the DB are over a date range, so no time is set.

It is working BEFORE the time feature has been requested, but now, when I add the current time filter, only records with a time set (i.e. events that are not over a date range) are returned.

Is there a way I can get the below to also include Null records?

$WADbSearch1->addComparison("time",$_GET["time"],"AND",">=",0);

Thanks,

Aled

Sign in to reply to this post

Meic Delwedd

Basically, need the SQL to run something like:

SELECT * FROM `eventtable` WHERE ((`date` >= "2013-09-05") OR (`dateTo` >= "2013-09-05")) AND ((`time` >= '16:51') OR (`time` = ' '))

Got it as far as:

[05-Sep-2013 16:02:39 UTC] AND ((date >= "2013-09-05 00:00:00") OR (dateTo >= "2013-09-05 00:00:00")) AND (time >= '17:02') OR (time = ' ')

Obviously not quite there!

Is there one of wada_search.php's functions that do this for me?

Sign in to reply to this post

Jason ByrnesWebAssist

No, there is not a way for Data Assist Search to achieve this result. Data Assist Search does not allow for both of those conditions, only one or the other.

Sign in to reply to this post

Meic Delwedd

Hi Jason,

That's what I was afraid of!

Thanks for your reply, do you have any suggestions of how we could achieve this?

Aled

Sign in to reply to this post

Jason ByrnesWebAssist

You would need to hand code the search rather than use Data Assist Search, we do not offer support for this.

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...