Go Back   TechArena Community > Software > Software Development
Become a Member!
Forgot your username/password?
Tags Active Topics RSS Search Mark Forums Read

Sponsored Links



Close ended Database connection in CSharp.

Software Development


Reply
 
Thread Tools Search this Thread
  #1  
Old 12-01-2011
Member
 
Join Date: Jan 2011
Posts: 9
Close ended Database connection in CSharp.
  

I am working as a software developer in a small IT company. Up till now in all my projects I used only normal database connection we normally used in vb6.0. But in current working projects client told me that while coding be careful about one thing that is not to give too much pressure on server if they found that my application is putting lot of pressure on their server interacting with data stored in database than they will refuse my project. I only know the normal method of connectivity. Please reply as soon as possible I want to complete my project as soon as possible.

Reply With Quote
  #2  
Old 12-01-2011
Member
 
Join Date: May 2009
Posts: 503
Re: Close ended Database connection in CSharp.

It is not an issue for which you stopped your process of development. There are two types of connection techniques available in c#. One is open ended connection and second is close ended connection. Open ended connection is one which is you used. In open ended connection you remain in contact of server as long as you are interacting with database. But in close ended connection you take a copy of database on your local machine and close the connection. For taking a copy of database you just need to create one object of dataset in that with the help of data adapter object.eg:- da.fill (dataset object, table name). You can then update the changes you made on your copy to database using data adapterers Update method.
Reply With Quote
  #3  
Old 12-01-2011
Member
 
Join Date: Apr 2009
Posts: 567
Re: Close ended Database connection in CSharp.

Yes! There is an alternative to open ended connection technique that you are using which puts tremendous pressure on your server where you?re all data is placed. Close ended tech. put?s less pressure on server side. Just one thing on which you have to concentrate is not use close ended connections technique when there is a requirement of reflecting the changes in database as soon as you perform some action in your application so be clear when to use what.
Reply With Quote
  #4  
Old 12-01-2011
Member
 
Join Date: May 2009
Posts: 533
Re: Close ended Database connection in CSharp.

Close ended connection will definitely solve your problem regarding connection. There is a same method to use in all type of connections that you establish with server. It may be sqlserver or any other. Method is unique for all types of connections. Just one difference is there that is after taking copy of database on dataset don?t try to put it another database into it use different dataset object for dealing with new database.
Reply With Quote
Reply

  TechArena Community > Software > Software Development
Tags: , , , ,



Thread Tools Search this Thread
Search this Thread:

Advanced Search


Similar Threads for: "Close ended Database connection in CSharp."
Thread Thread Starter Forum Replies Last Post
How to make Database connection in ASP.NET Neil'o Software Development 4 16-11-2011 11:06 AM
Connection failed for the database login Indivar Software Development 5 18-11-2010 12:03 AM
How to make the Database connection in PHP AK_Chopra Software Development 3 05-09-2009 09:35 AM
How to make odbc connection force to close Rixwel Software Development 3 13-08-2009 09:39 AM
How to create Database connection? Majestic Software Development 2 18-11-2008 03:31 PM


All times are GMT +5.5. The time now is 06:36 AM.