pgloader loads data into PostgreSQL. The new version is stable enough
nowadays that it’s soon to be released, the last piece of the
3.1.0
puzzle
being full
debian packaging of the tool.
A long time ago we talked about how to Import fixed width data with pgloader, following up on other stories still online at Postgres OnLine Journal and on David Fetter’s blog.
Back then, I showed that using pgloader made it easier to import the data,
but also showed quite poor performances characteristics due to using the
debug
mode in the timings. Let’s update that article with
current pgloader wonders!
As presented at the PostgreSQL Conference Europe the new version of pgloader is now able to fully migrate a MySQL database, including discovering the schema, casting data types, transforming data and default values. Sakila is the traditional MySQL example database, in this article we’re going to fully migrate it over to PostgreSQL.
In our previous article about Loading Geolocation Data, we did load some data into PostgreSQL and saw the quite noticable impact of a user transformation. As it happens, the function that did the integer to IP representation was so naive as to scratch the micro optimisation itch of some Common Lisp hackers: thanks a lot guys, in particular stassats who came up with the solution we’re seeing now.