First Draft of queries

Missing history tables stuff, I need to figure out how exactly I am
going to handle those (high priority).  Also need to do requests (low
priority).

I need to do some quick research in how to format the php to return an
object that can easily display the relevant records.  Once I have that
skeleton built, I can build out the remaining functions and integration
can begin.