Once you've created your instance, you will need to create your data table. This
is something you'll only probably do once, but it's written as a function to make
it easier (and to run integration tests on it).

Depending upon your chosen database type (eg, Mongo), you may not actually need
to run this. However, it's probably best to run it.

objCurrency.createTable(function(err, result) {
// err should be null
// result should be true
});

If you have some form of migration script of your own, you can use the actual
query directly. You'll find this in /lib/db/DB_TYPE/store.js.

Now we've got our data table created, we can start importing some data. The
feed is from the European Central Bank, which publishes it in XML format. Again
there is a method that you can execute, imaginatively titled import().

objCurrency.import(function(err, importCount) {
// err should be null
// importCount should be a number, at least 0
});

This is probably best run as a cron job. The feed gets updates at about 2pm in
Central European Time - UTC + 1 (UTC + 2 in the summer). Also, the feed is only
updated on weekdays, so not much point in querying it on a Saturday or Sunday.

This program is free software: you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free Software
Foundation, either version 3 of the License, or (at your option) any later
version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE. See the GNU General Public License for more details.