Import export decimal

Tweak import/export of decimal fields, and add some testing.