Uploading Files

Even though your "database" includes the word "data", data isn't the only thing we categorize and track. We often need to track discrete files and FileMaker is perfectly adept at doing this. In fact, FileMaker's container field is ideally suited to store all kinds of different files.

The problem, however, is simply throwing a container field onto your layout is never really a good idea. If you allow users to simply drop anything into a container, then you'll surely end up with a collection of duplicate files and files which may not even need to be in the database.

The best method for properly managing uploaded files is to make sure you control what gets in and how it gets in. This isn't going to be handled with your simple addition of a container field to the same table tracking your contact information. This is best suited with a couple of gateway keepers. Filtering based on extensions and preventing duplicates are two methods you implement into a highly optimized uploading method.

In the associated video and technique file you'll have access to all the instruction and code needed to start you on the path to implementing the proper and ideal way for managing file uploads into a FileMaker database solution.

AttachmentSize
UploadingFiles.zip1.61 MB

Comments

I always love learning the techniques you have to offer and I use your various techniques in my solutions. For this one you have here I have tried before. If the files to be uploaded are large (Example: full resolution photos taken on iPhone), inserting the file in to a global field first then obligatory create in the actual table as the next step is actually significantly slower in the WAN environment than just obligatory create directly. I love all the considerations you have for screening out only acceptable file types or extensions before accepting it in the database. I 100% agree with it. But writing the binary file in to the global field is still quite a bit of wait even thought it is a local disk operation. Just sharing my own experience. I would love to know if there is a way to achieve the best of both worlds in the WAN environment.

FileMaker Dreamer & Designer

There seems to be a bug (revealed by Vince Menanno in his "Being optimist in the pessimistic world") with global fields causing communication with server even when they are not supposed to. Having the global container field in a locally stored FileMaker file (which can be done dynamically thanks to dynamic data sources), can resolve the performance issue.