Jump to content

This topic is 2032 days old. Please don't post here. Open a new topic instead.

Recommended Posts

This should be easy for someone to answer. I have looked around on my own but haven't come across an answer. What is the maximum character limit for a script parameter in FM13? And, this may be a silly follow up question but I want to make sure, is that limit the same for scripts being run on FM Server 13? Thanks in advance.

Link to post
Share on other sites

Script parameters invoke the calculation engine so i think this rule would apply:

 

Size of calculation formula: Maximum of 30,000 characters, including text and numbers, any referenced fields, operators, functions and parentheses.

 

http://help.filemaker.com/app/answers/detail/a_id/11889/kw/text%20limit/session/L3RpbWUvMTQyMDgwOTUzMS9zaWQvbk9VZm0qYm0%3D

 

Without actually knowing i would guess that "any referenced fields" means the content of any referenced fields not the references themselves

Link to post
Share on other sites

Size of calculation formula: Maximum of 30,000 characters, including text and numbers, any referenced fields, operators, functions and parentheses.

 

That's the limit for the size of the calculation formula - not for the result. And, to my understanding, the content of the referenced fields is irrelevant when constructing the formula - otherwise a field that contains more than 30,000 characters could not be used in a calculation at all.

 

The tech specs do not specify any limit for the content of a script parameter (or a variable). One could surmise that the size is limited only by available memory - but that's just a guess. 

Link to post
Share on other sites

That's the limit for the size of the calculation formula - not for the result. And, to my understanding, the content of the referenced fields is irrelevant when constructing the formula - otherwise a field that contains more than 30,000 characters could not be used in a calculation at all.

 

The tech specs do not specify any limit for the content of a script parameter (or a variable). One could surmise that the size is limited only by available memory - but that's just a guess. 

This calls out for someone with a lot of time on their hands to do some testing.  :)

Link to post
Share on other sites

The maximum is 999,999 characters. 

 

Calls to scripts with 1,000,000+ characters will fail without throwing an error.

 

I discovered this when developing EasySync. (It passes payloads to the server using script params.)

 

-- Tim

Link to post
Share on other sites

I'm needing to figure this one out because I've run into a similar issue to the one Tim describes. Scripts failing without error. This seems to coincide with extraordinarily long script parameters.

 

Also, Tim, it's very ironic that you would come across my particular post on this. The job I'm working on, believe it or not, is breaking out pieces of your FMEasyAudit to improve my own audit log that i'm making for my company's product database. There are potentially 100K+ record audits that will be logged daily and your use of SQL calls is working really well. Great job on that. I have my audit log set up as a separate database file on the server, but I've been able to use your basic approach to increase performance by orders of magnitude.

 

Which brings me to my specific problem. Passing extremely long lists of modified fields to the audit log database to be parsed. The SQL statement that loops through finding any and all modified records produces monumental text strings when I've just finished importing 50,000 records with 30+ fields each. These text strings are then saved as a $Variable and that variable is sent to the audit log database on the server as a script parameter. The way i've been getting around the failures so far is by simply pushing logs for a predetermined number of records at a time. Rather than all 50,000 at once I'll send them 100 at time, or something like that. 

 

If I could find out the exact maximum limits of a script parameter I could set that (or something near it) as the rate at which I pass logs. This would maximize the speed of the operation.

Link to post
Share on other sites

The max that I was seeing was hit when passing params via Perform Script on Server. I had assumed that it was the same when passing them with the standard Perform Script, but apparently not...

Jdu98a, you might want to take a look at this blog post, which very briefly describes a technique that we are calling "Fireball." http://www.timdietrich.me/blog/fireball-intro/Depending on how you are implementing your audit trail, you might be able use this technique (or something similar) to handle passing large numbers of records, or large payloads in general. It would need to be hosted with FMS for this technique to work, as it uses CWP XML.

Tim

Link to post
Share on other sites

This topic is 2032 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Similar Content

    • By HOnza
      The "swiss army knife" plug-in is now compatible with iOS App SDK 19 and can execute macOS and Windows system scripts asynchronously
       
      Prague, CZ -- June 23, 2020 -- 24U Software announces the version 3.1 of 24U Toolbox Plug-In for FileMaker, toolbox of the most useful calculation functions for daily use. This update adds compatibility with iOS App SDK 19 and makes it possible to execute macOS and Windows system scripts asynchronously (without waiting for result).

      Version 3.1 brings:
      Function Toolbox_DoSystemScript can be called asynchronously Support for iOSAppSDK 19 added Fixed issue when 3 or more serial numbers are registered which caused FileMaker to freeze Compatibility and performance fixes  
      About 24U Toolbox Plug-In
      24U Toolbox Plug-In is a robust FileMaker Pro plug-in which allows FileMaker Pro databases to:
      Execute FileMaker or System shell scripts to automate tasks inside/outside of FileMaker Pro Execute SQL commands to develop faster and keep your solution clean Match & replace regular expressions to find & replace text fast using patterns Merge data values into text while maintaining styling to quickly and easily apply templates Lookup DNS name for IP & vice versa to find out who is connecting from wher Get current public IP to know more about clients and discover potential security attacks Define global keyboard shortcuts to avoid unnecessarily excessive use of script triggers Obtain precise microsecond timestamps to measure nearly unmeasurable chunks of time Get the type of a FileMaker variable to let your scripts make the right decisions Share variables between databases to avoid creating too many external data sources Get rich text as HTML to generate crystal clean HTML and CSS Support for iOS App SDK and FileMaker Cloud makes the plug-in work on the whole FileMaker Platform  
      System Requirements and Compatibility:
      24U Toolbox Plug-In 3.1 requires any Intel Mac since 2008, 2048 MB RAM, Mac OS X 10.10 Yosemite, FileMaker Pro 15. Recommended is any Intel Mac, 4 GB RAM, Mac OS X 10.10 Yosemite, FileMaker Pro 16 Advanced or newer (including FileMaker 19).
      1 GHz processor, 2048 MB RAM, Windows 8.1 and FileMaker Pro 15 are minimum requirements for using the plug-in on the Windows platform. 1.6 GHz processor, 4 GB RAM, Windows 8.1 or newer, FileMaker Pro 16 Advanced or newer (including FileMaker 19) are recommended.
      For using 24U Toolbox Plug-In 3.1 with iOS are required macOS 10.12, FileMaker Pro or Pro Advanced (for creating FileMaker solutions), Xcode8 (Swift 3.0), iOS 10.0, developer.apple.com account (for testing and deployment on device) and FileMaker iOSAppSDK 18
       
      Availability and Pricing
      24U Toolbox Plug-In 3.1 is immediately available for download free of charge as a fully functional 14-days trial version, which can be activated after purchasing a license. Licenses for 24U Toolbox Plug-In start at US$49 per user, $499 per server. Volume discounts are available for 5 or more users. iOS app licence for Toolbox Plug-In starts at US $499 for up to 20 users.
      More information: https://www.24usoftware.com/Toolbox/
      Download: https://www.24uSoftware.com/Toolbox#download
      Buy: https://www.24uSoftware.com/Toolbox#buy
       
      About 24U Software
      With customers in 75 countries and 29 years of experience with the Claris FileMaker platform, 24U excels in developing new or taking care of existing custom apps, optimizing their performance, identifying and resolving potential issues and liabilities, improving reliability, stability and scalability, integrating them with other systems including various hardware devices, and extending them beyond expectation.
       
      As a Claris Platinum Partner, 24U helps global businesses around the world to maintain sustainable growth by working with their in-house developers or completely taking care of the maintenance and development of their business solutions.
       
      ###
       
      (c)2020 24U s.r.o. All rights reserved. 24U and 24U Software are trademarks of 24U s.r.o. Claris and FileMaker area trademarks of Claris International, Inc., registered in the U.S. and other countries. All other trademarks are the property of their respective owners. Pricing and availability are subject to change without notice.
    • By dmcs
      Hi. I had a really weird problem last night that was pervasive through all files I was working on, served, local, and even a new file I created to try to test the issue. It was totally crippling and driving me crazy. I had gone into a script and selected the Go to Layout command, but when I tried to select a layout, none appeared, even though there were plenty of layouts in the table. I dismissed it as a temporary glitch and tried a Set Field command, needing to set a field to a calculation, and again, found the system locked up in such a way as I had never seen before. It would not let me enter a calculation! I closed and re-opened the file. No dice. I restarted Filemaker. Nope. I rebooted my entire computer. Nope. I tried working on a local file. Still - no layouts could be chosen in ANY file! I tried making a *new* file. Nope! I was desperate, and just about posted asking for help when I thought to disable all plug-ins, just to make sure, and voila - that did it. As soon as I disabled the 360Works FTPeek and 360Works WebAssistant plugins, full functionality in the script workspace was restored! I thought maybe it was just a coincidence. I re-enabled the plug-ins and checked again. It still worked, with the plug-ins re-enabled, so - maybe I was just having a bad day, but then when I went back in this morning, again - with the plug-ins re-enabled, again - I couldn't select any layouts or make any calculations in Script Workspace, so right away I disabled the plug-ins, again, and again, that fixed it, so I'm pretty sure there's something going on with the plug-ins. I also had 360Works Email installed, but had disabled it the day before any of this started to test functionality on the server, so that one was never enabled, and that's probably the first time I've ever disabled that one while still having the other's enabled. Other than that, I haven't changed anything about my system for quite awhile. I'm actually running 16, so maybe this won't be a problem when we upgrade to 17, but for anyone else who hits this roadblock - disable your plug-ins.


    • By john renfrew
      This has long been an issue, I have no idea why it happens and it is making life quite difficult
      Win Server 2012 FMS 16 (current but this happens on other configurations)
      With ScriptMaster installed 
      run a script which resets the server ( SMReset) and then loads jars and functions return to you the result of SMGetRegisteredModules and show it in a dialog box
      run another script on the server which just returns to you the result of SMGetRegisteredModules and show it in a dialog box
       
      dialog 1 SHOWS the modules you installed
      dialog 2 is EMPTY
      fmsadmin restart fmse
      do the above again, same result
       
      this means you can not do a test on the server to see if a particular function is loaded before you want to use it.... in fact there is no test you can do to see if the ScriptMaster has fallen over as far as I can tell.
       
      Any solutions???
    • By JMart
      Hi gurus,
      I am sure I’m missing something simple, but for the life of me I can’t figure this out. I have a database with tickets. What I want is when a new ticket is created I want to see a popover (see attached) then I want the user to type in the top box and as they type I want to filter the list below (a portal) and once they client is shown they would select it and a ticker is created for the client. I sound a script and modified to fit my needs but can’t get it to work. Can someone stretch a helping hand?
      BTW the filtering is working but its not reflecting in the popover its reflecting on the layout.


    • By Hoytopher
      Hi all,
      I'm an FM novice who has a functioning database, and I'm trying to add layers of functionality to it. One feature I'm trying to design is a script to search through a Gmail outbox with certain keywords.
      In URLs, "%" translates to "%25". Filemaker appears to do this automatically - In Gmail syntax, you need to write "in%3Asent" to have the Gmail search bar contain "in:sent" which searches my outbox. Here's my current code for Go to URL:
      This "%" bit translates to "%25". I've tried "\%", I've tried creating a string, x, then having it open x, but no matter what I cannot get "%" to show up as-is, it always translates to "%25". Is there any way around this? I've tried subtracting text, but I just can't seem to get it to work. Any bright ideas? I can't find an answer to this specific question of disabling URL string substitution.
  • Who Viewed the Topic

    2 members have viewed this topic:
    eyepro  chrisellen 

×
×
  • Create New...

Important Information

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