fixed some database issues, and worked on library re-search