Automatically unpack, generate and add Danish Motorregister Data to a Mongo Database from an XML File.
This repository contains a .NET Core 2.2 project (C#) that takes a Danish Motorregister XML File (From SKAT) as Input, and will unpack, generate and add each item to a Mongo Database (However this should be easy to change to another DB if so desired).
- Linux or Windows Server
- Mongo DB Database
- Knowledge of .NET/C# for building the project and making changes accordingly
- Make changes to the Database settings in the Project, then build it for your desired OS (Linux, Windows or Mac)
- Host a Linux Server (or Windows server, however I recommend Linux) with a minimum of 100 GB of storage and a decent CPU. This server will be used to unpack and generate the Motorregister Data based on the XML File.
- Host a Mongo DB which is accessible either on the same server or remotely. This should have a minimum storage of around 50-100 GB aswell.
- Install .NET Core 2.2 Runtime on the Server
- Put on the published/build of the .NET Project on the server from step 1.
- Download the latest
.zip
file from SKAT's DMR FTP Serverftp://5.44.137.84/ESStatistikListeModtag/
onto the Linux Server, this will take about 3-4 hours depending on the server's internet speed, however overall this speed is limited by SKAT's servers. - Extract the
.zip
file to the same folder as the program from step 4. - Run the Program / .NET Project on the Server
- You will be prompted to enter the name of the XML File. Enter the name of the downloaded XML File and press enter.
- You will be prompted to enter an amount of how many rows/items that should be proccessed, before these items are saved to the database. You don't wanna put this number too low as that will make the whole process take longer. A good number is to set it to around 1000-2000.
- Wait for the whole thing to finish, this will take about 3-4 hours depending on the server specs like CPU, Disk Speed etc.
- Whenever the program says "Done", the generation is completed.
This project is licensed under the MIT License, therefore a copyright notice is required to be given.
If you want to contact me about this project, you can do so by sending me an e-mail at kevingeeken@gmail.com