bugfix book sql