write inputcurrency to db