October 19, 200421 yr I am importing folders full of images into my db. Some fields related to the photos will have the same value for all photos in the folder. Is there a way to specify a value that will be set for all records in that import? If not, how do I set a value across multiple records in one action?
October 20, 200421 yr Have two tables: 1) folder 2) photo. The primary key is in the folder table; the foreign key is in photo table. The fields which have the same value for all photos in a folder belong in the folder table. This is a one-to-many relationship (parent to child) so your Relationship Graph should reflect that.
October 20, 200421 yr Try the Replace command to set a value in a field for the found set. If this is to be used in a multi-user environment, then a Set Field script step in a loop is better as it allows for error trapping if a record is locked.
October 24, 200421 yr Author After using the import function many times I don't think that it is possible to populate fields other than things like photo name, path etc (when importing a directory full of images). In SQL, I would want to do a UPDATE photos title = 'new title name' WHERE photo_category = 'oregon' That is the kind of operation I am needing to do. Sorry - I'm a Filemaker newbie so the suggestions above don't male sense to me.
October 25, 200421 yr Hi, apwalton. The UPDATE command in SQL is almost exactly analogous to the Replace Contents script step that Ender suggested. Make sure you use Replace Contents and not Perform Find/Replace. The script would first return a found set (perform a find for "oregon" in the field photo_category) and would then replace the contents of title with "new title name". Jerry
Create an account or sign in to comment