Forum: Building VoltDB Applications

Post: Loading data into VoltDB

Loading data into VoltDB
Nov 5, 2010
Need to load data from flat files into VoltDB?

Linked from this post is an example application that shows how to load data from a file into VoltDB. It handles decimal, integer, string and timestamp data.

Ant script. Requires an environment variable "VOLTDB" be defined and pointing to the location of the VoltDB jar and shared library. Modify the path to the filename to load and the server to connect to in the "client" target.

DDL for example.

Project file for example.

Deployment information for example. Change hostcount, sitesperhost, leader, and kfactor for your environment.

Client application to read file and call insert stored procedure.

Stored procedure to insert a row into load table.

Download the example application here.


csvloader in VoltDB 2.7.2
Jul 1, 2012
A CSV file loader has been added to the VoltDB kit that makes loading data from text files much easier. The csvloader shell command is available in VoltDB 2.7.2 and later and is documented in the Using VoltDB guide.