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.

stored procedures

Featured Replies

In FileMaker is it possible to write stored procedures ?

I assume you know about scripts, as these are FM's stored procedures. What specifically are you trying to do?

Steve

  • Author

i need to write some SQL queries and take the result of the queries and run a loop and get count of a particular field based on some conditions. It is kind of a complicated mess. I am trying to figure out how to go about it in FileMaker. Has anyone been in a similar situation ?

Well, with that rough description, you'll get rough answers.

In FMP, what is often done with SQL queries is done via "Find" to

select the set of records of concern... then you can use the fields

of those records in various calculations... or you can iterate through

the found set by using "scripts". Open up ScriptMaker and you'll see

that it offers a fairly general purpose programming language for

processing data.

Why not B)

1) turn the querries into global keys or global concanate keys, Keyword 1 & " " & Keyword 2 & " "& Keyword3 (call it cg_CompoundKey)

2) Count using the Count (::Relationship: field)

Where the Relationship involves the cg_CompoundKey for the left side and an indexed key at right side (which would be the stored CompoundKey for each record)

  • Author

thanks for the suggestion. I will try to think more on Ugo's idea.

  • 4 weeks later...

1st hide your SQL books it will confuse u more....SQL logic is barely used in FM...the closes I got was with Ugo's "joined" fieids approach.However, those scripts are pretty nice althoug "1 step at the time" kind of approach

goto filed...enter...peform find...goto layout...blah blah

whereas u just "run" the stored_proc with all the AND IN WHERE in one nice little statement wink.gif

Ayhow, most definetly spend time looking at those scripts

All the best!

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.