Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Finding Records on Timestamp Field

Featured Replies

Hi everyone. Currently i got BeginDate as timestamp, i want to create a report searching based on BeginDate, but because it's timestamp, brings me all, i guess i got to use a wildcard, but im not sure how.

i have:

enter find mode

set field [Cajas::BeginDate;GetAsText(tempvars::BeginDate)

&"..."&GetAsText(tempvars::EndDate)]

perform find.

how should i use the wildcard? do i have to convert the timestamp to a date, and then search?

thanks

You probably first need to break up your timestamp into date and time fields/data seperately . . . try create another calculation field using : LeftWords ( Timestamp ; 1 ). This should give you back just the date, then your idea of entering find and setting this new field with the START and '. . .' and END should work.

Are tempvars::BeginDate and tempvars::EndDate global fields? If not then set them to globals, or capture the data into variable prior to entering find mode.

  • Author

ok, i break up, my timestamp into date, and apparently, it's correct but when i do the find, still brings me all....

also the tempvars::begindate and enddate are globals.

I believe it breaks because it is specified as GetAsText(). FM can't find a date or timestamp that way. If you have two global date fields, you can simply enter the dates so:

Enter Find Mode [ ]

Set Field [ BeginDate ; gBeginDate & ".." & gEndDate

Perform Find [ ]

FileMaker will insert the *:*:* for the time automatically.

The GetAsText() is unnecessary, but it should work with it too. At least it does so with 8.5, so the problem is likely to be something else. Which version introduced wildcards?

Can you put a pause just before Perform Find [ ], and report what you get as the find criteria?

Wildcards were introduced in vs. 8 and I tested using vs. 8. But if the operating systems changed then GetAsText() won't necessarily work. I thought it was unreliable even with time settings. Sorry if I might have mislead here!

Hey John! Maybe it's the moon!

Oh, I think the GetAstext() should definitely be removed. I'm just not convinced it is the cause of the current problem. But we should know soon.

  • Author

i put a show custom dialog, and it's breaking correctly the BeginDate(timestamp) but, for some reason doesn't find me what i want

It should work as expected if those fields are global. Try reindexing your tiemstamp field.

  • Author

it works! thanks for your help

Create an account or sign in to comment

Important Information

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

Account

Navigation

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.