?
Solved

.MDB access slow in C# Upgraded to VS 2005 - Now old c# project VERY VERY slow handling Access .mdb files

Posted on 2006-11-24
6
Medium Priority
?
463 Views
Last Modified: 2008-01-09
I have an application which manipulates a fairly large Access database (25000 records, 51Mb). Code snippets include:

Many lines of code missing, just to give you an idea of the code used....
CONN_STRING = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + DATABASE_NAME;
oCONN = new OleDbConnection(CONN_STRING); // Set oCONN object
oCONN.Open(); // Open the oCONN

Saving...
oDA_new = new OleDbDataAdapter(sSQL,oCONN);
oDS_new = new DataSet(); // Create the DataSet
oDA_new.Fill(oDS_new,"Products");
DataRow oDR = oDS_new.Tables["Products"].NewRow();
oDS_new.Tables["Products"].Rows.Add(oDR);
oCB_new = new OleDbCommandBuilder(oDA_new);
oDA_new.Update(oDS_new,"Products");

With the old VS a database with a few thousand updated records would save in around 60 seconds.

With VS2005, the same application takes about 4 hours !!!!!

I ahve not changed any references between versions. Have you any idea why this has slowed so much ? I am now rewritting the program using SQL Server 2005 but until the program is fully developed I wish to use the old version without the 12 hour turn-around !

Help !

Fully qualified answer needed and positive outcome to receive points. Thankyou
0
Comment
Question by:nvms
[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
  • 3
  • 3
6 Comments
 
LVL 41

Expert Comment

by:graye
ID: 18009655
Hummm....   Which version of visual studio was the original program written in VS2002 (Framework v1.0) or VS2003 (Framework v1.1)?   Did you do an "automatic upgrade" or a by-hand rewrite?

BTW:  Since Microsoft gives away SQL Server Express, I'd highly recommend that you convert from Microsoft Access
0
 

Author Comment

by:nvms
ID: 18010571
Thanks for your comments. The original app was written in VS2002 1.1 and a .Net 2.0 upgrade made no difference to performance.

As mentioned in the question "I am now rewritting the program using SQL Server 2005 but until the program is fully developed I wish to use the old version " so a SQL Server Express based project is under development.

Yes it was an automatic upgrade.
0
 
LVL 41

Expert Comment

by:graye
ID: 18011417
Wait, now I'm confused....   I thought it ran fast before the upgrade, and only after the upgrade it slowed down
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:nvms
ID: 18017671
The .Net 2.0 upgrade made no difference (upgrade patch from MS). What DID make a difference was upgrading from VS2002/3.Net to Visual Studio 2005.

I have made great progress with SQL Server 2005 so may cancel this question now anyway. Thanks for your help.
0
 
LVL 41

Accepted Solution

by:
graye earned 1500 total points
ID: 18018722
I've written dozens of VS2002/VS2003 applications that read/write to Microsoft Access.  I've never had any performance problem with "converting" to VS2005.

Do you still have the pre-converted application to run as a test?

Oh well, It doesn't matter now...
0
 

Author Comment

by:nvms
ID: 18024101
Thanks mate, points are yours for taking the effort to help.
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Article by: Ivo
C# And Nullable Types Since 2.0 C# has Nullable(T) Generic Structure. The idea behind is to allow value type objects to have null values just like reference types have. This concerns scenarios where not all data sources have values (like a databa…
Exception Handling is in the core of any application that is able to dignify its name. In this article, I'll guide you through the process of writing a DRY (Don't Repeat Yourself) Exception Handling mechanism, using Aspect Oriented Programming.
Michael from AdRem Software explains how to view the most utilized and worst performing nodes in your network, by accessing the Top Charts view in NetCrunch network monitor (https://www.adremsoft.com/). Top Charts is a view in which you can set seve…
In this brief tutorial Pawel from AdRem Software explains how you can quickly find out which services are running on your network, or what are the IP addresses of servers responsible for each service. Software used is freeware NetCrunch Tools (https…
Suggested Courses
Course of the Month13 days, 3 hours left to enroll

777 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