rkass068 Posted December 1, 2014 Posted December 1, 2014 Hello, I currently have 3 databases running on filemaker server through a dedicated server. I understand form the filemaker server settings we can set the maximum amount of users that are allowed to be connected to the server. However, is there a way to set the amount of maximum users allowed to connect to a specific database? In one of the databases I would only like to to allow 1 user to connect to the database at a time. Giving priority to the first connection. Is this possible?
Wim Decorte Posted December 1, 2014 Posted December 1, 2014 Not through a server configuration or setting. But you can use the Get(UserCount) function as part of your on-open scripts: http://www.filemaker.com/help/13/fmp/en/html/func_ref2.32.95.html
Claus Lavendt Posted December 1, 2014 Posted December 1, 2014 There is no settings in FMS, that allows you to individually set the number of users allowed to connect to each file. You can create a part of the startup script in each file, a routine, that checks for how many users that is connected to the file and based on that, create actions to either allow or disallow access to more users. ...as always, Wim jumps in with a great answer, which is basically the same as I was typing at the same time....
rkass068 Posted December 1, 2014 Author Posted December 1, 2014 Hahahahah yes, Wim is quick to respond and has responded to all of my questions. Thank you Wim! and thank you Claus. Sounds good I will make a startup script to only allow the first user to connect to that specific database. Also, is there a script that can find which users are currently connected to a database hosted by server?
Claus Lavendt Posted December 1, 2014 Posted December 1, 2014 Also, is there a script that can find which users are currently connected to a database hosted by server? Nope... not by username or other information.... In FMS admin console, you can see a list of currently connected users. Here you can see their usernames and ip addresses. However, you can not access that information from within the FM file itself... That is.... One way of achieving this would be by having a utility file on the server, use a plugin and acquire information from FMS log files, which can provide such information. That is, however a pretty involving way.... The other way, is to create internal logging table, where you write an entry every time a user login to the solution. That could be a part of the startup script. Be aware, that you can not track, if a user gets disconnected. Even if you write a logout script, that will not always be triggered, if the user gets disconnected. That will only work, if the user choose to exit the solution the "correct" way, so that this logout script will run....
Steven H. Blackwell Posted December 2, 2014 Posted December 2, 2014 Sounds good I will make a startup script to only allow the first user to connect to that specific database. Bear in mind that there are many ways an Opening Script can be bypassed. So your reliability level here may be somewhat diminished. Steven
Recommended Posts
This topic is 3985 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