Giter Site home page Giter Site logo

a06555 / zoran.db.ip.importer Goto Github PK

View Code? Open in Web Editor NEW

This project forked from zoranmax/zoran.db.ip.importer

0.0 0.0 0.0 484 KB

DB-IP.com free location database data import tool for Microsoft SQL Server.

Home Page: http://www.agile-code.com

C# 100.00%

zoran.db.ip.importer's Introduction

ZORAN.DB.IP.Importer

ZORAN.DB.IP.Importer is a tool that imports into Microsoft SQL Server the freely available geolocation database offered by www.db-ip.com.

Documentation

For more information please check the documentation https://github.com/zoranmax/ZORAN.DB.IP.Importer/wiki or here http://www.agile-code.com/blog/import-db-ip-com-database-data-to-microsoft-sql-server-with-zoran-db-ip-importer-tool/

Downloads

Download the compiled application

How to run the application?

  1. Download the free database from this location http://www.db-ip.com/db/download/city. The database comes in the CSV format.
  2. Change the Connection String in the ZORAN.DB-IP-Importer.exe.config file to point to the Microsoft SQL Server database. This is done by changing the value of the connection string named “DB_IP”
  3. Once again, in the file ZORAN.DB-IP-Importer.exe.config, enter the path to the CSV file by changing the value of the AppSettings value “db-ip-file-path”
  4. Run the two provided scripts dbip_city.sql and dbip_city_stage.sql against your database. This will create two tables (staging and the “live” table). Obviously this should be done only once , the first time you use this application.
  5. Run the application.

Yes, but how does it work?

In order to avoid any complex management of the inserts and updates of the already existing data, I’ve chosen the approach of the staging table and the “live” table.

The importing process operations are as follows:

  1. Read the CSV file (for the time being the file is fully loaded in memory. With the latest CSV files this might be an issue for some as the file has grown significantly).
  2. Truncate the data from the “Staging” table
  3. Load the data from the CSV file to the “Staging” table
  4. In a transaction, move all the data from the “staging” table to the “live” table.

Licence

http://www.apache.org/licenses/LICENSE-2.0

zoran.db.ip.importer's People

Contributors

zoranmax avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.