5 Replies Latest reply on Aug 6, 2015 7:09 AM by philmodjunk

    Making a shared database exclusive, on a temporary basis

    BerryHoning

      Title

      Making a shared database exclusive, on a temporary basis

      Post

      I have a labelling program, that is being used by more users. Sometimes when someone is working in it, and creating several labels, another opens the file and deletes by this automatically all the labels made. I need this deletion, because every labelling request is a new one.

      I want user #1 to set the file exclusive to him and when he finishes working on it, making it open again for other users. I want user #2 see a message that user #1 is working in this file.

      How can this be done?

        • 1. Re: Making a shared database exclusive, on a temporary basis
          SteveMartino

          How is the DB being shared?  FileMaker network (peer to peer) or server?  Without really knowing too much about your database and work flow, it sounds like you have a basic design problem, that allows this to happen.  One way is to use a transaction model, where the records being worked on are in a portal of the main record, thus locking other users out of the record until the entire 'transaction' is finished.  You can also look at user privileges, to have this label creation done on a separate table that locks all other users out of that table until the first user is finished with the table. 

          • 2. Re: Making a shared database exclusive, on a temporary basis
            philmodjunk

            If this works the way that I think that it does, you just need to change that "delete all" process. Add a field that auto-enter's the user's account name. set up a script for delete all that first finds all records with the current user's account name and then only deletes them. Now your label table can be used by multiple users without one user's "delete" from deleting another user's label records.

            • 3. Re: Making a shared database exclusive, on a temporary basis
              BerryHoning

              @Steve Martino: it's server-shared. Could well be the case that it is a basic design problem. I started working with Filemaker back in 1993 or so, version 2.1. So these files are very old, from the pre-portal era.

              @PhilModJunk: that could be a solution. I'll try to sort it out tomorrow, and I'll let you know. Thanx.

              • 4. Re: Making a shared database exclusive, on a temporary basis
                BerryHoning

                Just to give you an update. It works, but because I need some extra programming to split the users input (they see each other making labels), I took this solution out again. They need to talk with each other now before entering labels. Like it always was. ;-)

                Normally this is not a problem, but when you have to make 50 labels for samples, you can work some time on making these labels. In stead of making 10 identical labels by copying, which can be done in 20 seconds.

                • 5. Re: Making a shared database exclusive, on a temporary basis
                  philmodjunk

                  You can set up each user with their own found set and then they won't see each other's labels. It's only when you have done a "show all records" that records created by another user automatically appear. So if you create one new record for the new user when they start and then perform a find for that record, they will no longer see the other user's label records.

                  You could also set up a system where the user creates their label records in a portal to that table and then the relationship or a portal filter could limit the visible records to those with the current user's account name.