简体   繁体   中英

Import MS Access 2019 Desktop tables and data into MS SQL Server Developer Edition 2019

Can anyone please suggest a way to import an MS Access 2019 Desktop database (tables and data) into MS SQL Server Developer Edition 2019 to create a new SQL Server database?

I know this question has been asked many times for earlier versions of this software but I am hoping that there may be a 2019+ method for the 2019 versions.

Thanks in advance.

If you looking to just import 1 or 2 tables, then use the SQL server management tools. However, those imports don't even preserve the PK and your indexes. And such a import does not support relationships between tables.

However, if you looking to move up lots of tables, keep + set your PK, keep + set your indexing, and ALSO move up related data between tables?

Then I suggest you use Sql Server Migration Assistant for Access.

The so called SSMA can be found here:

https://www.microsoft.com/en-us/download/details.aspx?id=54255

Note in above, you can download a x86 version, or a x64 bit version. While your local say running copy of SQL server can (and even should be) x64 bits, it is STILL VERY VERY VERY common that your Access/office install may well be x32 bits. As a result, you want to download + choose + run the x86 version of SSMA.

While total free, it is a relative complex package, so try a few test migrations, and I high recommend this package, since as noted, it has smarts for not only moving tables, but also indexing, and even relations between tables.

I also STRONG but STRONG suggest that you change the default mapping for the data types. By default, it will use datetime2 for any Access Date/Time columns, and I STRONG but STRONG but STRONG but STRONG but STRONG suggest you change that default back to using sql server datetime for dates. the default is datetime2 and you REALLY but REALLY but REALLY do not want to use this default.

You can also have it "try" to move up your sql (saved) queries. I in most cases don't do this, but that's another long post here.

However, it can and will attempt to try and move saved queries to sql server views - this I don't recommend in most cases, but each use case I suppose is a different use case.

In summary:

To import a table or maybe 2-3 tables - use the SQL manager.

To import a whole lot of tables, and keep things like relations intact, then use SSMA for access.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM