I’ve been working with a client a lot recently, so when one of their users was not able to log into Microsoft Dynamics GP today, they got in touch.
The problem only affected one user who got the below error message; all other users were unaffected and could log in normally:
The stored procedure smCleanupFilesBeforeLogin returned the following results: DBMS: 0, Microsoft Dynamics GP: 20505.
This sort of issue is covered in a Microsoft KB article.
The first three possibilities listed, could be ruled out as they would have affected more than just one user; the final option, records stuck in either the SACTIVITY or Batch Activity (SY00800) tables.
I used the below script to check for corrupt records (the highlighted section is the user id to check for):
SELECT * FROM ACTIVITY WHERE userid = 'userid'
SELECT * FROM SY00800 WHERE userid = 'userid'
Once I had confirmed the records were present, I used the below scripts to delete the stuck rows:
DELETE FROM ACTIVITY WHERE userid = 'userid'
DELETE FROM SY00800 WHERE userid = 'userid'
What should we write about next?
If there is a topic which fits the typical ones of this site, which you would like to see me write about, please use the form, below, to submit your idea.