I am converting MS Access 2000 to MS Access 2010.The issue i am facing is,the MS Access 2010 is very slow (even freezes) after conversion.
Previous Config: MS Access 2000 on XP with Link Tables to Sql server 2000 sitting on Windows 2000
New Config: MS Access 2010 on Windows 7 with Link Tables to Sql server 2000 sitting on Windows 2000
Access under New Config is painfully slow or sometimes hangs and crashes Same situation with a Visual Studio Desktop Application,It runs painfully slow on Win7,while it runs great on XP.
Things I have tried :
Little to no improvement so far.
mdb ) to the Access 2010 or 2007 file format ( . accdb ): In Access 2010, from the File menu, select Open. In Access 2007, click the Office Button, and then click Open.
If you created the web app directly on a site, you can apply an upgrade package to the web app right there. On the site where you want to upgrade your Access web app, click Site Contents. Point to the tile for your web app, click the ellipses (…) that appears next to it, and then click UPGRADE.
Open the database and click File > Save As > Access Database (. accdb) > Save As > Save.
It is hard to reply because the origin of the problem can be multiple. Since the two clients has not the same OS configuration, we cannot exclude that the problem comes from a difference of configuration between the two OS.
First you can discern if the connexion is slow because of the PC, Access or your DB :
Test : direct connection
You can try the direct connexion to SQL server using a direct connexion instead of linked tables. For this, you can create a new Access Project connected to your SQL Server. An Access Project is a type of Access database which directly connect to an SQL Server, without linked table. It uses a native client. You can view tables of your SQL Server database directely in Access, and you can edit them. The extension of an Access Project is not MDB but ADP. Access Projects are hidden in Access 2010 but well supported.
To create an Access Project: go to menu File -> New, then click of the file icon, and then choose "Save as type" : "Microsoft Access Project (*.adp)".
When the ADP is created, it should ask you to enter the parameter for an existing SQL Server database. Enter your parameters.
Then go to the table panel, and try to browse some table and check if it is slow or fast.
If it is slow => then the problem may comes from your PC or the connexion. You can try with another software for testing the direct connection of you have one that can connect to SQL Server.
If it is fast => then the slowness comes from the ACCDB or the ODBC link.
Also check :
Have you tried keeping the connection open? This may only apply to linked tables in another accdb, not sure.
I had this issue a while back so I now keep the connection open as long as Access is running, here's a stripped-down version of my sub for this:
Public Sub updateTables(bClose As Boolean)
Dim dbsCurrent As Database
Dim tdfSingle As TableDef
Dim tdfCollection As TableDefs
Dim sBasePath As String, sPath As String
Set dbsCurrent = CurrentDb
Set tdfCollection = dbsCurrent.TableDefs
Set dbsHold = dbsCurrent
Static dbsOpen As DAO.Database
If bClose Then
dbsOpen.Close
Else
sBasePath = Left(CurrentDb.Name, InStrRev(CurrentDb.Name, "\")) & "SB-Support\"
sPath = GetUNC(sBasePath & "data.dat")
Set dbsOpen = OpenDatabase(sPath, False, False, "MS Access;")
For Each tdfSingle In tdfCollection
If tdfSingle.SourceTableName <> "" Then
If tdfSingle.Fields.Count = 0 Then
tdfSingle.Connect = ";DATABASE=" & sPath
tdfSingle.RefreshLink
End If
End If
Next
End If
Exit Sub
End Sub
I think I originally retrieved it from here: http://www.fmsinc.com/microsoftaccess/performance/linkeddatabase.html
I don't have a SQL server requirement but a quick google gave me this for OpenDatabase for a SQL connection:
Dim cs As String
Dim cn As DAO.Database
Dim ws As DAO.Workspace
Set ws = DBEngine.Workspaces(0)
cs = "ODBC;DRIVER=SQL Server;SERVER=Main\SQLEXPRESS;DATABASE=Workwise;APP=Visual Basic" 'UID=Peter;PWD="
Set cn = ws.OpenDatabase("Workwise", dbDriverNoPrompt, True, cs)
http://www.vbforums.com/archive/index.php/t-572723.html
When it is freezing I would check what queries are actually running in sql-server is happening in sql-server. eg. by running something like this:
select (SELECT text FROM ::fn_get_sql(s1.sql_handle)), *
from sys.sysprocesses s1
I debugged a slow access application once where the access queries were not being very well translated to sql-server. Something simple in an access query caused many inefficient sql-server queries to run. We re-wrote a few of these queries as sql-server views and solved it for us.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With