I created a database in MS SQL Server 2000. Everything was working great until I found that a user can login to the server more than once at the same time. Is there a way to prevent this, especially the first login using a normal login screen and the second login using Query Analyzer?
SQL Server is a data repository and not a full access control system. Your database application should be the one in charge of controlling access to the back-end data. One popular way that I've seen this performed is by having the application login using one set of credentials and then managing the user credentials inside your custom application. This way, when a user attempts to login concurrently, your application can query a "currently logged in" users list and display the appropriate error message. The user's password won't allow him into Query Analyzer so there's no harm in attempting a connection.
Dig Deeper on SQL Server Database Modeling and Design
When encrypting SQL tables that have joins in SQL Server 2000, learn about possible problems that may arise with different data values in those ...
Learn how to set a SQL Server password to an SA login and why you can not set this account for access to separate SQL Server databases.
Get the code to connect SQL Server version 7.0 to Visual Basic 6.0.
Have a question for an expert?
Please add a title for your question
Get answers from a TechTarget expert on whatever's puzzling you.