Joaquin, Great suggestion. I'm not going to use it in this case because we don't currently have a session tracking system.
But the tip about On server open connection is great. I missed that it fires each time a new process begins. I thought it only ran when initially connecting to the server. I really need to go back and re-read some of fundamental commands more often. After playing with this for about 10 minutes I've got a couple of questions: the user ID - how does this number correlate to 4D users? Or does it refer to 'user' in a more general sense of a 'node' connecting to the server? the connection id is some sort of random value I assume but specific to this particular process. On Mon, Jul 3, 2017 at 9:14 AM, Joaquin Mendes Castro via 4D_Tech < 4d_tech@lists.4d.com> wrote: > We did this by using the On server open connection and On server close > connection database methods. Any process launched by a user session shares > an ID ($1) which can be used to track who is doing what. > > When a user logs into the application, we launch an special process which > records this UserSession_ID and our internal User_ID in a table > ([idsrv_CurrentUsers]). Then, on every new process launched, the On server > open connection method does a query on this table with the UserSession_ID > and loads the user's record as the current for this table. Further on, > triggers just have to use the [idsrv_CurrentUsers]User_ID to know who shot > it. > -- Kirk Brooks San Francisco, CA ======================= *The only thing necessary for the triumph of evil is for good men to do nothing.* *- Edmund Burke* ********************************************************************** 4D Internet Users Group (4D iNUG) FAQ: http://lists.4d.com/faqnug.html Archive: http://lists.4d.com/archives.html Options: http://lists.4d.com/mailman/options/4d_tech Unsub: mailto:4d_tech-unsubscr...@lists.4d.com **********************************************************************