fixed ordering of replies in index view as well as thread view, also cleaned up improper sqlite datatypes in .sql schema