Solved

GP 2013 R2 Error - A get/change first operation on table 'sysUserDefaults' failed accessing SQL data

Posted on 2016-09-20
4
16 Views
Last Modified: 2016-10-23
We have a user that is unable to login to our test GP server due to the error above. SA can login fine. I tried clearing user access to all companies and then re-adding but did not work. Reset password, verified user is setup correctly. This has happened previously to users when restoring productions data to the test server but former admin did not leave steps to resolve. This user has not logged into the test server since before the last production to test migration so he is the only one experiencing the issue at this time. I did find an article on running the Grant.sql script but am unsure of implications to other users if I do this. Any insight would be appreciated!
0
Comment
Question by:Jason Shaw
  • 3
4 Comments
 
LVL 13

Assisted Solution

by:Norm Dickinson
Norm Dickinson earned 100 total points (awarded by participants)
Comment Utility
I have a client whose software runs on Dynamics GP 13, and when a restore is performed, or a test company refreshed, as our software vendor terms it - we always have to run two particular scripts on the newly refreshed databases. The first goes thru and checks for key integrity, and the second sets ownership of the database to DYNSA. Do you have any such scripts for your software? Do you have a vendor to contact for specific scripts? While the ownership is a one-liner, the first script is two pages typed, and I doubt my script would work for your database.
0
 
LVL 45

Accepted Solution

by:
Vitor Montalvão earned 400 total points (awarded by participants)
Comment Utility
SQL Server doesn't really works with user names but user ids. With that said, when you migrate logins from another SQL Server instance you should assure that the login has the same ID or it won't be able to connect to the migrated database(s).
Luckily you can fix this very easily with the following stored procedure:
EXEC sp_change_users_login 'Auto_Fix', 'LoginName'

Open in new window

NOTE: Replace LoginName with the desired login name.
0
 
LVL 45

Expert Comment

by:Vitor Montalvão
Comment Utility
Jason, a feedback will be appreciated.
Cheers
0
 
LVL 45

Expert Comment

by:Vitor Montalvão
Comment Utility
Recommend to close this question with the above solutions.
0

Featured Post

What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Select2 jquery help 9 40
SQl help with selection 14 41
t-sql complement 8 29
SQL Inner Join Vs SubQueries 9 23
When you hear the word proxy, you may become apprehensive. This article will help you to understand Proxy and when it is useful. Let's talk Proxy for SQL Server. (Not in terms of Internet access.) Typically, you'll run into this type of problem w…
On Sep 22nd 2014 Microsoft released Update Rollup 1 for Microsoft Dynamics CRM 2013 Service Pack 1 and back in July Update Rollup 3 was released.  So we now have:   Update Rollup 1Update Rollup 2Update Rollup 3Service Pack 1Update Rollup 1 for S…
Via a live example, show how to extract information from SQL Server on Database, Connection and Server properties
Via a live example, show how to set up a backup for SQL Server using a Maintenance Plan and how to schedule the job into SQL Server Agent.

728 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

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now