improve bulk import to database