I, too, have been experiencing this problem since upgrading to FileMaker 12. I use a FileMaker database with scripts that populate data with values from SQL queries, pull the data, and then I also delete the record. I upgraded from FileMaker 10 to FileMaker
12 a couple weeks ago, and have been getting this random error ever since. We do use FileMaker server, and while I'm not sure exactly what is happening, I have been able to reduce the occurrence by inserting delays after the scripts and SQL queries, before
switching tables with 'show window', etc..
Maybe try inserting 'delay 2' after your scripts, just to give FileMaker a chance to catch up, before moving on. Like Simon suggested, you could also use 'try/on error'. I know this isn't a very elegant solution, and I'd love another myself, but this seems
to be working, for now. Your 'someone else is already accessing the data' error might not actually be someone else at all. It could be your computer attempting to access the table while a script is still running. I am the only person who ever accesses the
particular table I'm referring to, and as I said, I have been getting this error since the switch to FileMaker 12.
The odd thing is that this error seems to be related to scripts taking longer to process with FileMaker 12. While most things seem faster with 12, are scripts taking longer to process, or is FileMaker 12 just dealing with them in a different manner
than it did in FileMaker 10?
On Apr 30, 2012, at 5:04 AM, Marion Dickten wrote:
Hi,
On 30 May 2012, at 08:38, Marion Dickten wrote:
I am using AppleScripts to insert and delete records in a FileMaker database. Since this is a database other people access at the same time (remotely opened), we often run into access problems. Is there a way to create a database record
that is locked for access except for the creating script? I have been thinking of transactions but what I've found by googling so far doesn't sound encouraging.
(There are also some scripts created within FileMaker using FileMaker's own scripting language, and they give me the same problem.)
Semi-random thoughts:
- Are you using FileMaker Server to host the database? If not, this may help.
- Are you creating the record via the script and then adding in data? Is this the problem? Have you tried creating the record with the data as a single action?
- Can you not catch errors and retry?
Well, as for using FileMaker Server, I would have to ask. I'm pretty much of a newbie about FileMaker and I simple use what I'm told to, I am only asked to do the AppleScripting.
The problem is usually deleting a record, but sometimes it seems that inserting data is also a problem.
Let me be as specific as I can. The database was created and is maintained by someone else. Most of the fields in the table are calculated by FileMaker scripts, sometimes rather intricate ones. The whole purpose of creating a new record is to insert one value
into one special cell and have all the rest calculated. Then we pull the calculated values out via AppleScript and put them into another document. So the table is usually empty. We create a record, let FileMaker populate it, look at the results, and delete
it again.
The chief problem is that it is *not* an exception which interrupts the script, it is a regular dialog put up by FileMaker stating that we can't be allowed access because someone else is already accessing the data.
Marion
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list ( email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden
|