added buy log to history db