Solved

Good Advice

Posted on 2002-04-24
2
172 Views
Last Modified: 2010-05-02
I'm looking for some good advice from somebody that has used VB.NET with Oracle 8. Is using the disconnected data-set truely the way to go?? Or is there more overhead in connecting to the Database with each call to the database.
0
Comment
Question by:thenrich
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 5

Expert Comment

by:rkot2000
ID: 6966800
For a small number of clients you can keep your connection open,
But if you have large number of clients you need to open and close your connection.
Plus read this on connection pooling:
Pooling Connections
Applications often have different users performing the same type of database access. For example, in ASP.NET Web applications many users might be querying the same database to get the same data. In those cases, the performance of the application can be enhanced by having the application share, or "pool," connections to the data source. The overhead of having each user open and close a separate connection can otherwise have an adverse effect on application performance.
If you are using the OleDbConnection class, connection pooling is handled automatically by the provider, so you do not need to manage it yourself. If you are using the SqlConnection class, connection pooling is managed implicitly, but also provides options that allow you to manage pooling yourself. For more information, see Connection Pooling for the SQL Server .NET Data Provider.
0
 
LVL 6

Accepted Solution

by:
esolve earned 50 total points
ID: 6966810
Hi I am not a pro with .NET yet but could share some light on the subject...

A DataSet object is truly disconnected, meaning you would only have to go and connect once to get the data from the database and then again to update the changes in the dataset back to the datasource.

When connecting to an Oracle database make sure to use the OLEDBConnection and OLEDBCommand Classes.

Just remember that ADO.NET consist of Dataset classes and provider classes.
1. The Dataset classes are used to build a disconnected database structure in memory. They contain:
DataRelation, DataColumn, DataRow, DataTable classes in order to achieve this.
2. The provider Classes is XxxConnection eg. SQLConnection or OLEDBConnection and
XxxCommand eg. SQLCommand or OLEDBCommand

In your case you will also need the DataAdapter class to fill the Dataset. The DataAdapter class will also be used to update changes back to the database. This is achieved through calling any of its command classes nl. SELECT, INSERT, UPDATE, DELETE (DataAdapter Contains these 4 command classes by default)

There is probably more overhead in coding the Dataset, but that is it...

Good Luck

0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you have ever used Microsoft Word then you know that it has a good spell checker and it may have occurred to you that the ability to check spelling might be a nice piece of functionality to add to certain applications of yours. Well the code that…
Most everyone who has done any programming in VB6 knows that you can do something in code like Debug.Print MyVar and that when the program runs from the IDE, the value of MyVar will be displayed in the Immediate Window. Less well known is Debug.Asse…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Suggested Courses
Course of the Month7 days, 23 hours left to enroll

617 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question