working import and export, but need some tweeks