Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Microsoft Office > Access and Access VBA > Access VBA
|
Access VBA Discuss using VBA for Access programming.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Access VBA section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old December 21st, 2006, 03:24 PM
Friend of Wrox
 
Join Date: Oct 2004
Posts: 564
Thanks: 0
Thanked 4 Times in 4 Posts
Default Access to SQL Server locking problem

I have an MS Access database which uses SQL Server 2005 as a backend.

I am doing most of my querying with either an ADODB connection, or using the DoCmd.RunSQL

What is happening though is that these queries are timing out - does anyone have any experience with locking problems using either of these, or have any suggestions about how I might resolve this problem?

Thanks

Mike

Mike
EchoVue.com
__________________
Mike
EchoVue.com
 
Old December 21st, 2006, 06:23 PM
Friend of Wrox
 
Join Date: Oct 2004
Posts: 564
Thanks: 0
Thanked 4 Times in 4 Posts
Default

OK - got it fixed, but here is the kicker...

I put Primary Keys on all the Primary Key fields at the end of last week. The idea was to improve performance!! With 20 users out of work, and sheer desperation, I removed all the keys - It's now faster and actually working.

Mike
EchoVue.com
 
Old December 22nd, 2006, 08:10 AM
Friend of Wrox
 
Join Date: Mar 2004
Posts: 3,069
Thanks: 0
Thanked 10 Times in 10 Posts
Default

Sometimes I don't use PK's or any referential integrity in SQL and do my business rules with the Access interface, at least to prevent SQL Server from throwing weird errors at the users.

Also, I usually create views on the server and then call data from them. If I need to do an update, I use ADO and make them directly back to the effected tables with code.



mmcdonal





Similar Threads
Thread Thread Starter Forum Replies Last Post
Locking in Access DB linked to SQL Server backend gibbers Access 3 April 24th, 2007 03:20 PM
Locking on a Remote Server jscuderi SQL Server 2000 2 May 10th, 2006 04:30 PM
SQL Server Database Locking with Access thatoneguy SQL Server 2000 3 September 7th, 2005 08:05 PM
Access 97 Table locking problems timmaher Access VBA 1 November 5th, 2003 11:05 AM
SQL in Access and in SQL Server mikko SQL Server 2000 1 July 29th, 2003 06:17 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.