Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Multipule or single user?

Status
Not open for further replies.

l310564

Programmer
Jun 18, 2006
50
GB
Hello,

I think my head is about to explode.

I have a flash application that connects to a asp.net web service. The flash application allows people to logon and query/ update the database through the web service, they can be logged on for hours and continuously be accessing the database.

I think I'm right in saying that every time the flash application queries the web service it creates a new instance of the web service.

My question is that if this is the case is it better to login and then log off the sql server every time any one query is called, or is it better to login once and do all the queries under the one user?

Thanks,
Hugh

If knowlege can create problems it is not through ignorance that we will solve them.

Isaac Asimov
 
You definitely don't want one database connection for each user. If I recall my ASP.NET programming (which I haven't done in a while), it would be best to create an SQL login for the web service application - that way the connection string is always identical. I believe that ADO.NET will cache connections if the connection strings are identical - and because of that you would simply open and close a new connection for each database call (it's not really going to open a new connection - it will check the connection pool to see if one already exists).
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top