Script control over field indexing

Idea created by mdiehr on Nov 9, 2015

    Many folks are using FileMaker Pro/Server for large databases : I personally have a 3.5GB database with over 10 million records. 


    Recently I was trying to re-import about 4 million records into one table that included a lot of indexed fields.    The first time I tried it locked up my Mac (FMPro was using 77GB of RAM and I had to force-quit it).   The next time I tried it succeeded but took about 12 hours.   The problem?  Field indexes.  I then repeated the import after turning off all field indexes, and it took only 90 minutes.


    There are situations (such as massive imports) where it would be very useful to disable indexing, do the import, then re-enable them.   Right now this can be done but is a manual process.


    Filemaker already supports the SQL DROP INDEX command, so it seems like the code is already there.


    Please give us script steps that can do this (or alternatively, simply extend the ExecuteSQL step to allow the DROP INDEX command)


    Thank you