Bug Fix: Apostrophe issues in db queries - minor updates