okrauth Posted November 9, 2010 Posted November 9, 2010 I have a script that uses The "replace content field" step to blank out a field content in a large database. Sometimes the replace content step takes a long time when records reach several thousands... Does anyone know a more efficient way to blank-out the content of a field in a large database? Thks
bcooney Posted November 9, 2010 Posted November 9, 2010 Needing to do this is quite unusual and suggests a flaw in your structure. Can you describe why you need to do this? And, yes, Replace is probably the fastest way to set a field to empty. However, it will skip any record that is locked.
okrauth Posted November 9, 2010 Author Posted November 9, 2010 Yes. I realized that it is unusual to use the replace field... However, in this situation I am using an external function that sets either a 1 or 0 base on the record parameters.. The problem is that the external function works dynamically so not every time a record parameter would produce a 1 or a 0 that is why I need to blank the record. and I need to save the field content because it is a foreign key in a relationship, so I cannot use it as a calculation.
bcooney Posted November 9, 2010 Posted November 9, 2010 That's not enough details for me. Couldn't you use a onRecordCommit trigger to set a stored field to the unstored?
ryangrg Posted November 11, 2010 Posted November 11, 2010 (edited) Use applescript. I think this should blaze through it. Just open up the layout with the record set in question and run this from the applescript complier or from run applescript script step. Note the syntax isn't tabbed like it should be when compiled. let me know what happens. tell application "FileMaker Pro" tell every record of table "TABLE NAME HERE" of database "DATABASE NAME HERE" set cell "FIELD NAME HERE" to "" end tell end tell Edited November 11, 2010 by Guest
Recommended Posts
This topic is 5127 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 accountSign in
Already have an account? Sign in here.
Sign In Now