/
Migrate System33 MDB to SQL Server
Migrate System33 MDB to SQL Server
Steps below as described by John to migrate System33.mdb to SQL Server database
Step-by-step guide
Note: Microsoft Access 2010 is required to perform these steps. MS Access 2007 will not communicate with SQL Server 2012. Versions of MS Access > 2010 have this functionality to upsize DB removed.
- Create SQL Server Database using SQL Server Management Studio / command line.
- Open Microsoft SQL Server Management Studio and log in as an administrative user.
- Right-click on the Database folder, and select New Database in the context menu:
- Enter the database name (in this example System33). If you wish to change the path where SQL server will create they files on the filesystem, change the Path option in the Database files for the data & log files:
- Click on OK to create database
- Open Microsoft SQL Server Management Studio and log in as an administrative user.
- Create a 32-bit ODBC DSN to SQL Server database using SQL Server Native client. Name the DSN to something unique for the migration (i.e. ir_system33_msv)
- Take copy of System33.mdb you are upsizing so to not disturb production system from possible DB locks on database during migration
- Open copy of System33.mdb you created in step 3 in Microsoft Access 2010.
- In the Database Tools menu, click on SQL Server button in the toolbar:
- Choose Use existing database in the upsizing wizard, and click on Next:
- In the popup window which is displayed, click on Machine Data Source, and select the ODBC connection you created in step2, and click OK:
- For the SQL Server login details, either use Trusted Connection (if it has been setup while creating the database), or enter in a SQL Server user account to access the database (in this example, the sa account is used). Click OK to continue:
- Select the option to migrate all tables to SQL Server:
- Note: For final migration, some tables maybe excluded, including the following:
- AuthToken
- OrganisationDefinitions
- OrganisationDefinitions_Old
- CompanyDefinitions
- CountryDefinitions
- DataTypeMap
- ETL_LogDirectory
- ETL_Schedule
- ETL_ScheduleLog
- StateDefinitions
- Note: For final migration, some tables maybe excluded, including the following:
- Click Next:
- Ensure that the option No application changes is selected, then click Next:
- Click Finish to start the data migration process:
- Once the data migration has been completed, Access will display a report. Close it, there is no useful information provided.
- Choose Use existing database in the upsizing wizard, and click on Next:
- Close Microsoft Access.
- Open Open Microsoft SQL Server Management Studio and log in as an administrative user.
- Expand the Databases folder, System33 database, and the Tables folder:
- Check some tables which are known to have AutoNumber columns (like Companies / Mappings), and check that the data migration has converted these to Identity Columns. To check this, do the following:
- Right-Click on the table (in this example, Companies) and in the context menu, select Script Table as \ CREATE To \ New Query Editor Window:
- In the query editor window, find the column known as an autonumber column, and check its datatype is INT IDENTITY(1,1) (in this case, company_id):
- Repeat task on other tables.
- Execute the following query to check that the identity column seed (last number issued by server) is correct:
SELECT TABLE_NAME, COLUMN_NAME, IDENT_CURRENT(TABLE_NAME) AS IdentitySeedValue
FROM INFORMATION_SCHEMA.COLUMNS
WHERE TABLE_SCHEMA = 'dbo'
AND COLUMNPROPERTY(OBJECT_ID(TABLE_NAME), COLUMN_NAME, 'IsIdentity') = 1
ORDER BY TABLE_NAME
- Right-Click on the table (in this example, Companies) and in the context menu, select Script Table as \ CREATE To \ New Query Editor Window:
- Run DB Upgrade MSV_DBUpgradeV0 This updates the System33 database with some configuration changes.
- Run DB Upgrade MSV_DBUpgradeV1 This updates the Setup database with some configuration changes.
- Run DB Upgrade MSV_DBUpgradeV2 This updates the databases with some reconfiguration of Organisation User-Defined fields.
- Run Datafix program FixIRConnections to view any duplicate connection entries in table System33.dbo.Connections. If any have been found, run program with -d switch to remove them.
Note: The following tables have NTEXT columns and may require modifications:
Table Name | Column Name | Notes |
---|---|---|
_marker_SaaS_Upg | upgrade_note | |
AuthToken | Token | May be dropped |
CompanyReports | ||
connection_createviews | XTspecialSQL | |
connection_createviews2 | XTspecialSQL | May be dropped |
connection_createviews2015-1 | XTspecialSQL | May be dropped |
connection_createviews3 | XTspecialSQL | May be dropped |
connection_createviews4 | XTspecialSQL | May be dropped |
connection_createviews5 | XTspecialSQL | May be dropped |
connection_createviews6 | XTspecialSQL | May be dropped |
connection_createviews7 | XTspecialSQL | May be dropped |
connection_createviewsX | XTspecialSQL | May be dropped |
Countries | cnotes | |
custom_menus | menu_description | |
Dashboards | report_ids | |
DashboardsX | report_ids | May be dropped |
DashboardsX | May be dropped | |
DashboardsY | report_ids | May be dropped |
DashboardsY | May be dropped | |
DashboardsZ | report_ids | May be dropped |
DashboardsZ | May be dropped | |
EmailReports | reporturl | |
EmailReports | ||
EmailReports | extra_desc | |
HelpTopics | help_body | |
HtmlTemplates | template_header | |
HtmlTemplates | template_footer | |
HtmlTemplates | template_css | |
mapping_tables | mapping_whereclause | |
mapping_tables | mapping_sql | |
Mappings | html_description | |
mass_reports_to_email | header | |
mass_reports_to_email | footer | |
mass_reports_to_email | datasource | |
partner_messages | message | |
Paste Errors | reporturl | |
preset_mapping_tables | mapping_sql | |
published_schemas | schema_xml | |
Schema_report_quantities | quantity_formula | |
Schema_report_quantities | quantity_formula_dnm | |
UserReports | reporturl | |
UserReports | ||
UserReportsX | reporturl | May be dropped |
UserReportsX | May be dropped |
Related articles
, multiple selections available,