Random records locked in linked SharePoint list (1 Viewer)

Mr. B

"Doctor Access"
Local time
Yesterday, 19:12
Joined
May 20, 2009
Messages
1,932
Using Access 2010 and SharePoint 2010

We have been using linked SharePoint list in an Access 2010 application for a few months now. We have been able to work through several issues and have been successful with the implementation of using Access to update records in the SharePoint list using VBA to iterate through recodsets.

We have occasionally had a situation where one record in the SharePoint list would not let us update any fields using the same VBA code. Because this seemed to only affect one single record, when we had identified the record, we simply added code to exclude that one record. However, as of today, we suddenly are having this same issue with multiple, random records. These records will be one single record in the recordset or they may be 4 or 5 records in sequence. No error is reported from VBA but the execution of the code just stops. If I step through the process, it locks up when it tries to assign the first value to the first field that it is supposed to write a value to.

What is even more strange, is that the same records that we cannot write to from Access (directly in the lined table or through VBA) can be modified from the datasheet view in the SharePoint site.

I though I would see if any of you have experienced anything like this. It almost seems that the link from Access to the SharePoint list is not allowing the editing of random records for no apparent reason.

Any thoughts or assistance will be appreciated.
 

Mr. B

"Doctor Access"
Local time
Yesterday, 19:12
Joined
May 20, 2009
Messages
1,932
After working on this for sometime and trying various "fixes", I finally figured out that to resolve these write conflicts and record locking issues the "Cashing Web Service and SharePoint tables" option must be deselected.

From the File option on the Ribbon, select the Options option and then select the "Current Database" option. The last option at the bottom of that page is the "Cashing Web Service and SharePoint tables" check box. By default, this option is checked. Clear both of the sub-options and then uncheck the "Cashing Web Service and SharePoint tables" option. That will stop the random record locking and the other weird data related issues.

Just though someone else working with Access 2010 linked to SharePoint 2010 list would like to know about this.

Issue resolved.
 
Last edited:

falk225

New member
Local time
Yesterday, 17:12
Joined
Feb 1, 2012
Messages
1
Jut though someone else working with Access 2010 linked to SharePoint 2010 list would like to know about this.

Issue resolved.

You were right! I had a similar problem with random but specific records causing access to stop responding when I tried to edit them either in code or via tables linked shortcut in access. I could edit them via the sharepoint web interface jsut fine. It didn't seem to make any difference when I unchecked all the options that you spoke of, but when I checked the option and unchecked both sub options my problems disappeared as magically as they had appeared. I am so happy! Thanks for sharing your experience!
 

Mr. B

"Doctor Access"
Local time
Yesterday, 19:12
Joined
May 20, 2009
Messages
1,932
Thanks for the feedback. It is good to know that someone was able to benefit from my experiences with this. I really struggled with it for a while.
 

jerem

Registered User.
Local time
Today, 08:12
Joined
May 1, 2012
Messages
118
Thank you for the solution... But I'm still struggling with it. I have an update query that does not work because of lock violation.
Well, actually it works if I run the query manually but if I run it from a form I get the lock violation issue.
I have unchecked the Cashing Web Service and also made sure that Default record locking is set to "No locks" in the Client Settings.
Any idea what the problem might be?
 

Mr. B

"Doctor Access"
Local time
Yesterday, 19:12
Joined
May 20, 2009
Messages
1,932
Is your form is linked to the same record that you are trying to update? If so, that would be where you are getting your error.
 

jerem

Registered User.
Local time
Today, 08:12
Joined
May 1, 2012
Messages
118
Yes it is. It works very well in a local or linked table environment but not with Sharepoint. Why is that? What is the solution? Thank you for your help.
 

Mr. B

"Doctor Access"
Local time
Yesterday, 19:12
Joined
May 20, 2009
Messages
1,932
I am somewhat confused as to exactly what you are attempting to do. From what I am understanding , you have a form that is open to a record and you are then attempting to run a query that will update that same record. If this is the case then that would explain why you would be getting the record locking error.

The issue is related to the way SharePoint deals with the records. Keep in mind that SharePoint is really an SQL server database and therefore it manages record locking in a different way than the MS Access native database engine does.

Hope this helps.
 

jerem

Registered User.
Local time
Today, 08:12
Joined
May 1, 2012
Messages
118
The situation is exactly as you describe it. What would the work around be in that case? Should my macro close the form first and then execute the update query? Any other way?

Another question (and apologies if it's not directly related to the thread) is there a way to keep table macros when moving tables to sharepoint lists or are they just gone?

I know that if using Access Services with a web database, table / data macros work, but a web database is not an option for me (no vba programming available). So my question really is related to client FE with linked Sharepoint lists.
 
Last edited:

jerem

Registered User.
Local time
Today, 08:12
Joined
May 1, 2012
Messages
118
Btw, I'm using SharePoint Online (365), which is the same as Foundation I believe...
 

jerem

Registered User.
Local time
Today, 08:12
Joined
May 1, 2012
Messages
118
Can anybody help? Record Lock when an Update Query runs on a record in a SP list when that record is open in an Access Form. What would the work around be? Thank you!
 

dadonnel

New member
Local time
Yesterday, 20:12
Joined
Jan 24, 2014
Messages
1
After many hours of :banghead: I found that one of the records that I was trying to update had a value for a choice field that was no longer an option. This caused the whole query to fail.

KEY FINDING: The update query didn't have anything to do with that choice field, but the incompatible value there still caused the error when updating other fields.
 

jerem

Registered User.
Local time
Today, 08:12
Joined
May 1, 2012
Messages
118
I removed my update queries and replaced them by coding.
 

musicloverlch

New member
Local time
Yesterday, 19:12
Joined
Aug 23, 2018
Messages
1
I have removed all validation on my SharePoint list. Literally every field is "Single Line of Text" or "Number" and it continues to lock up on random records. Is there anything else I can try? I'm pulling my hair out.
 

richardashelton

New member
Local time
Yesterday, 17:12
Joined
Mar 29, 2019
Messages
3
I am having this issue with MS SQL server linked table records. I will try this fix.
 

Users who are viewing this thread

Top Bottom