Searching date fields

For HanDBase related topics that are not specific to one platform.

Searching date fields

Postby exmpro » Mon Oct 15, 2018 4:34 pm

I have a database of future events. Each record has a (date) field for the start of the relevant event,
and a date field for the end of that event.
I want to be able to search all events taking place on any particular date in the future.
This future date will vary with each search, and the records found will lie in the period between
their start and end dates.
Any suggestions as to how I can do this?
exmpro
 
Posts: 18
Joined: Tue Jun 09, 2009 5:04 am

Re: Searching date fields

Postby glenwf » Wed Oct 17, 2018 11:25 am

Since nobody is answering, I think Conditional Fields would get you there. Look in the manual for "Conditional Fields", and there are examples of downloads that use them. It will take several fields correctly done, but I think you need to do:

if beginning date is less than or equal to xxx
and
if end date is greater than or equal to xxx
then

That should give you a list. I think it could be set up as a "view" that could be edited to enter a certain date to look for before you looked at the list, or a field to input the date you are interested in or a form that would accept that date for the result and put it in that field. So two ways - set up a form, or just change the options in a view???

I don't know for sure this will get you there because I haven't played with Conditional Fields much, but they are very useful and you will learn a lot experimenting with them and I think they can be made to do what you want. I hope somebody gives you a more definite answer soon, but this is something to work on.
glenwf
 
Posts: 185
Joined: Wed May 20, 2009 5:34 pm
Location: Roseville, CA

Re: Searching date fields

Postby ddhsoftwareadmin » Wed Oct 17, 2018 9:08 pm

exmpro wrote:I have a database of future events. Each record has a (date) field for the start of the relevant event,
and a date field for the end of that event.
I want to be able to search all events taking place on any particular date in the future.
This future date will vary with each search, and the records found will lie in the period between
their start and end dates.
Any suggestions as to how I can do this?


Actually the filter function sounds like the best fit for your need. If you tap the menu and choose the Filter option you'll see you can filter on a date and choose a custom date range. If you choose the custom date range, you can choose a from and to date and you'll get only a list of those records that fall within the date range you picked!
ddhsoftwareadmin
Site Admin
 
Posts: 365
Joined: Tue Dec 09, 2008 2:13 pm

Re: Searching date fields

Postby exmpro » Sat Nov 03, 2018 3:50 pm

Just got round to reading your repilies on the forum...I thought I would get an email notification when someone reacted, but nothing came.
Anyway: the filter option seems to produce the required results. I wonder if this can be incorporated into a form or a view to streamline the operation each time.
Thanks so far
Michael
exmpro
 
Posts: 18
Joined: Tue Jun 09, 2009 5:04 am

Re: Searching date fields

Postby curtterp » Sat Nov 03, 2018 4:47 pm

Yes, you can use views to set up different filters to easily switch.
Have a good day

Curt
I am not a DDHSoftware employee, just a long time HanDBase user.... from Palm to Windows Mobile to Android, to iOS. Thanks to DDH, the database files transferred to each platform without a problem.
curtterp
 
Posts: 717
Joined: Tue May 26, 2009 6:41 pm
Location: Northern IL

Re: Searching date fields

Postby TITYRAFSE » Sun Nov 11, 2018 1:07 pm

ddhsoftwareadmin wrote:
exmpro wrote:I have a database of future events. Each record has a (date) field for the start of the relevant event,
and a date field for the end of that event.
I want to be able to search all events taking place on any particular date in the future.
This future date will vary with each search, and the records found will lie in the period between
their start and end dates.
Any suggestions as to how I can do this?


Actually the filter function sounds like the best fit for your need. If you tap the menu and choose the Filter option you'll see you can filter on a date and choose a custom date range. If you choose the custom date range, you can choose a from and to date and you'll get only a list of those records that fall within the date range you picked!

I figure Conditional Fields would get you there. Look in the manual for "Contingent Fields", and there are models of downloads that utilization them. It will take a few fields accurately done, however I think you have to do:

in the event that starting date is not exactly or equivalent to xxx

also,

in the event that end date is more prominent than or equivalent to xxx

at that point

That should give you a rundown. I figure it could be set up as a "see" that could be altered to enter a specific date to search for before you took a gander at the rundown, or a field to include the date you are occupied with or a frame that would acknowledge that date for the outcome and placed it in that field. So two different ways - set up a frame, or simply change the alternatives in a view???
TITYRAFSE
 
Posts: 3
Joined: Fri Nov 09, 2018 12:55 pm


Return to HanDBase General Discussion

Who is online

Users browsing this forum: Bing [Bot] and 1 guest

cron