I think you'd need to install two copies of FileMaker or one copy with a volume license and then use both copies to access the same hosted database. Even then, your system may be very slow to respond while this script runs. I'd schedule such a script to run late at night when, hopefully, no one needs to access the database.
There are a number of different ways to set up a script to run at a specific time of day. The best option depends on your OS, and whether or not the file is hosted over a network by FileMaker Server or not.