From time to time, LabVantage may run out of user licenses.  When that happens, no more users can log into the system.

If this happens often, than an increase in the number of user licenses may be necessary.


Target Audience: LV Application Team


General Query of Active Users

To check the number of users, user this SQL query in MS SQL Studio or like.


select c.sysuserid,c.connectdt,c.lastaccesseddt,su.sysuserdesc,cl.connectioncreateddt,cl.connectioncleareddt,cl.concurrentusercount,cl.totalusercount

from connection c

join connectionlog cl on cl.connectionid = c.connectionid

join sysuser su on su.sysuserid = c.sysuserid

where connectioncleareddt is null

order by connectdt desc,sysuserdesc


If the concurrentusercount is at the user license limit, then the system is out of user licenses until someone logs out of the system.

One reason that some users may be logged into LabVantage is because they didn't log out properly.  So, their user account is still using a license.


LabVantage User Connection Application - Preferred

If an admin is logged into the system and can access the System Admin --> Monitoring menu --> Connection Log, then use it for closing connections.

This is always the preferred choice.


If no admins can log into the system, see if any user can log out of the system to free up a license.  

If they can, then have an admin log in right away.  Then, go to and use the Connection Log app to close unneeded or older duplicate user connections.


Through Database Update - Non-preferred

As last resort, if no admin can log in for what ever reason, then an admin with access must update the LabVantage database.

To force quit logged used and reset the number of concurrent users, we need to run a couple of update SQL statements on the LabVantage database.

  1. Check how many users have active connections.
    1. Use the SQL Statement above to check
  2. Update concurrent cleared date so that there are less than 10 users left.  This should leave the user connections with the highest concurrentusercount.
    1. Here is a starting SQL Update than can be modified as needed.

      update connectionlogset connectioncleareddt = {fn Now()}
      where connectioncleareddt is null
      and connectioncreateddt < {fn Now()} -3
  3. Update concurrent user count
    1. Here is a starting SQL Update.  The number to lessen each field by is 1 less than the smallest number of concurrentusercount.
    2. In this update example, the smallest number of concurrentusercount was 41.  So, we need to subtract 40.

      update connectionlog
      set concurrentusercount = concurrentusercount - 40,
              totalusercount = totalusercount - 40
      where connectioncleareddt is null