Solved

Dynamics GP 2010 - Remove Old Users Imported From Version 9.0

Posted on 2014-01-31
1
643 Views
Last Modified: 2014-02-03
Hello,

I have several users within GP 2010 that are no longer valid.  We upgraded from GP 9.0 to GP 2010 and elected not to migrate the existing users (thus new users were created).  The old users remain inside GP and I would like to remove them if possible.

Going to Tools->Setup->System->User and deleting one of the old users results in an error message that reads "This user does not have a corresponding SQL login.  To create a SQL login, enter a password and choose save."  

Since the SQL login does not exist, I followed this Microsoft KB article http://support.microsoft.com/kb/919345.  The article says to run 'DROP USER <user>' against the DYNAMICS database and the company database.  When I execute the query, SQL throws an error that reads "The database principal owns a schema in the database, and cannot be dropped."  

Can I delete the schemas that are owned by the users that I want to delete and then execute the 'DROP USER <user>' query for each user that I want to delete?

Thank you
0
Comment
Question by:TacomaVA
1 Comment
 
LVL 39

Accepted Solution

by:
lcohan earned 500 total points
ID: 39824467
"Can I delete the schemas that are owned by the users that I want to delete and then execute the 'DROP USER <user>' query for each user that I want to delete?"

I would rather change the Schema owner than drop is because it may contain some used objects and at least by doing this if anything gets broken do to missing priviledges they can be added later.

How to change schema owner - see below and check the script that does it for all objects per schema:

http://stackoverflow.com/questions/1146599/how-do-i-change-db-schema-to-dbo
0

Featured Post

Enabling OSINT in Activity Based Intelligence

Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

Join & Write a Comment

I wrote this interesting script that really help me find jobs or procedures when working in a huge environment. I could I have written it as a Procedure but then I would have to have it on each machine or have a link to a server-related search that …
JSON is being used more and more, besides XML, and you surely wanted to parse the data out into SQL instead of doing it in some Javascript. The below function in SQL Server can do the job for you, returning a quick table with the parsed data.
Viewers will learn how to use the SELECT statement in SQL to return specific rows and columns, with various degrees of sorting and limits in place.
Viewers will learn how to use the SELECT statement in SQL and will be exposed to the many uses the SELECT statement has.

706 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

19 Experts available now in Live!

Get 1:1 Help Now