How to remove a company that is no longer being used in Microsoft Dynamics GP

Article translations Article translations
Article ID: 849249 - View products that this article applies to.
Expand all | Collapse all

INTRODUCTION

This article explains how to remove a company that is no longer being used in Microsoft Dynamics GP.

More information

To remove a company that is no longer being used in Microsoft Dynamics GP, follow these steps:
  1. Follow the appropriate step:
    • If you are using Microsoft Dynamics GP 10.0 or later, click Tools on the Microsoft Dynamics GP menu, point to Utilities, point to System, and then click Delete Company.
    • If you are using Microsoft Dynamics GP 9.0, point to Utilities on the Tools menu, point to System, and then click Delete Company.
    • If you are using Microsoft Business Solutions - Great Plains 8.0, click Setup on the Tools menu, point to System, and then click Company.
    • If you are using a version that is earlier than Microsoft Business Solutions - Great Plains 8.0, click System on the Setup menu, and then click Company.
  2. Click the Company Name lookup.
  3. Click the company that you want to delete, click Select, and then click Delete.
  4. Verify that the company database was removed. To do this, follow the steps for the database that you are using with Microsoft Dynamics GP.

    Microsoft SQL Server 2005 / Microsoft SQL Server 2008 /Microsoft SQL Server 2008 R2 / Microsoft SQL Server 2012
    1. Start SQL Server Management Studio.
    2. Expand the instance of SQL Server for Microsoft Dynamics GP, and then expand Databases.
    3. Verify that the company database was removed. If the company database is listed, right-click the company database, and then click Delete.
    Microsoft SQL Server 2000
    1. Start Enterprise Manager.
    2. Expand the instance of SQL Server for Microsoft Dynamics GP, and then expand Databases.
    3. Verify that the company database was removed. If the company database is listed, right-click the company database, and then click Delete.
    Microsoft SQL Server Desktop Engine (MSDE)
    1. Start Support Administrator Console.
    2. Run the following command to verify that the company database still exists.
      SELECT name FROM MASTER..SYSDATABASES
    3. If the company database is listed, run the following command to delete the database.
      DROP DATABASE XXX
      Note Replace XXX with the database name of the company that you want to delete.

  5. If the database has been manually removed or removed by the DROP script mentioned in step 4-c, then there may be some references from the deleted database still within the DYNAMICS/system database. These references need to be removed. To do this, download the ClearCompanies.sql script from the following link and then follow the steps:
    https://mbs2.microsoft.com/fileexchange/?fileID=d57c52af-2432-486d-9072-e1a1d60563bf


    Microsoft SQL Server 2005 / Microsoft SQL Server 2008 / Microsoft SQL Server 2008 R2 / Microsoft SQL Server 2012
    1. Start SQL Server Management Studio.
    2. Click New Query from the menu bar to start a new query window.
    3. Paste the contents of the ClearCompanies.sql scripts into the empty query window.
    4. Click Execute or press F5 to run the script.

      Note ClearCompanies.sql is a script that is automatically setup to run against the appropriate databases.
    Microsoft SQL Server 2000
    1. Start Query Analyzer.
    2. Click Query and then click New Query to open a blank query window.
    3. Paste the contents of ClearCompanies.sql into this empty query window.
    4. Click on the ‘Execute’ button or press F5 to run the script.

      Note ClearCompanies.sql is a script that is automatically setup to run against the appropriate databases.
  6. Log into Microsoft Dynamics GP to verify the company no longer exists.

Properties

Article ID: 849249 - Last Review: May 24, 2013 - Revision: 6.0
Applies to
  • Microsoft Dynamics GP 2013
  • Microsoft Dynamics GP 2010
  • Microsoft Dynamics GP 10.0
  • System Manager
Keywords: 
kbhowto kbmbsmigrate KB849249

Give Feedback

 

Contact us for more help

Contact us for more help
Connect with Answer Desk for expert help.
Get more support from smallbusiness.support.microsoft.com