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

Script for Export

Featured Replies

I have two related databases, A and B. A is my main database and one record from here can be related to many files in B. I can see all the information I need through a portal.

I need to be able to export the most recent "amount" and "date" from B (both on the same record), from the main record in A. If I try to do this from A now, it exports all the related dates and amounts.

The way I proposed to go about this was to create two fields in A that show the most recent date and gift, and then export those fields. But I'm not sure how to write the script(s) to get the most recent record isolated, and then bring that information into A. Make sense?

Thanks for your help!

Create a layout with a portal in A containing "Date" and "Amount" from B. Sort by "Date" in descending order.

Create calc fields in A that are equal to the related "Date" and "Amount" fields in B. Put those fields in the layout.

When you export, the most recent date info should be exported.

HTH,

Dan

  • Author

Thanks for the advice. It worked well and I got the amount I needed, however, the date field did not work. I got an unrecognizable number. Not important, as the amount from the correct date was essential, but though you might be interested. Thanks again!

Dezza

Filemaker does not STORE dates in human readable format, it stores them as a number.

Make sure that the current layout has the date formatted as you want it and in the Export dialog there is an option to format data using the current layout, select this checkbox.

The other option is to make a calculated TEXT field with the DateToText (DateField) function, which will convert the date number to a MM/DD/YYYY format.

Create an account or sign in to comment

Important Information

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

Account

Navigation

Search

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.