DeltaRocked Posted October 12, 2010 Posted October 12, 2010 mdbcon.au3 This is to assist migration of of MDB database to MSSQL / SQL.Many methods exist but this is the fastest except for the Disk IO.Once the csv files are created, use Bulk Insert T-SQL to transfer the data from csv to the actual DB. This was created cause I was frustrated with the available solutions. This is the simplest approach to assist you in migrating DB from MDB to SQL.usage:mdbcon.exe path_to.mdb password In case password for the specific MDB doesn’t exist thenmdbcon.exe path_to.mdb After completion csv files will be created in the path containing the mdb files. What this utility does : This will enumerate all the tables and create individual csv files in this format, with the tablename being the identifier. Filename.mdb.table_name.csv Errors: In case of any errors, proper messages will be directed to the STD_Console. Eg. 1: File does not exist, when the provided filename does not exist. 2: MDB requires a password, when password is not provided or password is incorrect and the mdb is password protected. 3: Incorrect parameters are passed, then help will be shown. The said CSV files are to be used by the “bulk insert” t-sql.Flaws:There exists a flaw in this code, when the number of records increases the speed slows down and this is due to the inhenrent flaw of MS Windows DISK IO. How to over come the flaw:Write data into the file after 1000 (or as per the limit of the characters stored by a variable) records . This will ensure lesser disk IOs and it will be very very fast.I was bored so didnt write the code for this, but its simple and not at all complicated.regardsDeltarocked.
ptrex Posted October 12, 2010 Posted October 12, 2010 @deltarocked ?? What about this ?? http://www.microsoft.com/sqlserver/2005/en/us/migration.aspx Rgds, ptrex Contributions :Firewall Log Analyzer for XP - Creating COM objects without a need of DLL's - UPnP support in AU3Crystal Reports Viewer - PDFCreator in AutoIT - Duplicate File FinderSQLite3 Database functionality - USB Monitoring - Reading Excel using SQLRun Au3 as a Windows Service - File Monitor - Embedded Flash PlayerDynamic Functions - Control Panel Applets - Digital Signing Code - Excel Grid In AutoIT - Constants for Special Folders in WindowsRead data from Any Windows Edit Control - SOAP and Web Services in AutoIT - Barcode Printing Using PS - AU3 on LightTD WebserverMS LogParser SQL Engine in AutoIT - ImageMagick Image Processing - Converter @ Dec - Hex - Bin -Email Address Encoder - MSI Editor - SNMP - MIB ProtocolFinancial Functions UDF - Set ACL Permissions - Syntax HighLighter for AU3ADOR.RecordSet approach - Real OCR - HTTP Disk - PDF Reader Personal Worldclock - MS Indexing Engine - Printing ControlsGuiListView - Navigation (break the 4000 Limit barrier) - Registration Free COM DLL Distribution - Update - WinRM SMART Analysis - COM Object Browser - Excel PivotTable Object - VLC Media Player - Windows LogOnOff Gui -Extract Data from Outlook to Word & Excel - Analyze Event ID 4226 - DotNet Compiler Wrapper - Powershell_COM - New
DeltaRocked Posted October 12, 2010 Author Posted October 12, 2010 (edited) On 10/12/2010 at 9:53 AM, 'ptrex said: @deltarocked?? What about this ?? http://www.microsoft.com/sqlserver/2005/en/us/migration.aspxRgds,ptrexyup gone through SSMA but doesnt suit my needs.We have over a million deployments of MSAccess mdb and we are migrating the main application's database from MS Access to MSSQL, so cant expect my end-user (A System Admin - which again is a huge number) to download SSMA and do a click through for all the deployments. Plus data retention is important.So that answers my *frustration* and the need for a command line tool. Though this tools doesnt do the complete migration but atleast it breaks the ice. What can be done to this code :add additional routine to identify data types and stored procedures and create a replica of the same on MSSQL etc etc etc. For me this is not an important part, as the initial script which was used to create the mdb is already present and the same is being used for MSSQL. RegardsDeltarocked Edited October 12, 2010 by deltarocked
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now