Jump to content
Sign in to follow this  
biggles1212

Date Find Issue

Recommended Posts

Hi Guys,

Now if I manually search the date field I can get some record results

ie. */1/2015 (in Australia so 1 is January)

Now I created a script and the calculation puts "*/1/2015" into the date field YET when it gets to "Perform Find [ ]" it returns no records.

Why is there a difference between manually typing it in and searching via a script do you think?

Cheers

Share this post


Link to post
Share on other sites

If you are trying to find all dates in January, use the ellipsis points for a date range:

1/1/2015...31/1/2105

Hope this helps!

 

Share this post


Link to post
Share on other sites

Hey,

Thanks. I tried using that too in my script but nope... Doesn't want to find those records.

I manually type it is still i.e. "1/1/15...31/1/15" and finds the two records.

I just cannot work out what is going on? I have done this tons of times....

Screen Shot 2015-07-27 at 1.28.39 pm.png

Share this post


Link to post
Share on other sites

If you don't show us how those variables are defined, then we can only guess why it doesn't work. Are they even defined in the same script? If not, they are empty.

Also, if you're trying to troubleshoot something, it's best to do so in isolation - so I would remove the search for AircraftID until the main issue is solved.

Another thing you can do is pause the script just before the Perform Find[] step and inspect the criteria entered by the script. Or do Modify Last Find after the script has run to get those criteria back so that you can look at them and compare them to what you enter manually..

  • Like 1

Share this post


Link to post
Share on other sites

A couple more ways to debug:

Make sure the "Date" field is really a date result. (I know...)

Temporarily insert a Show Custom Message [$date1 & "..." & $date2] right before the Enter Find Mode [ ]. This will display what is being passed to FIND. If no values, declare the VARS to global VARS, instead of LOCAL - $$date1 and  $$date2 and adjust your Set Field script.

Wrap the two variables with the GetAsText( ) function: GetAsText($date1) & "..." & GetAsText($date2)

Good luck!

Share this post


Link to post
Share on other sites

Wrap the two variables with the GetAsText( ) function: GetAsText($date1) & "..." & GetAsText($date2)

No, that doesn't do anything.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.