Added __isset magic method
Fix couple of bugs related to __isset method.

1. The relationships method does not exist when there aren't any relationships defined. So be a bit more cautious before calling the function.
2. Be more cautious before saying a $key exists. Added the extra check so empty() works correctly.
Allow empty relationships for HasOne and BelongsTo.
Implement orderBy method on Query object
Half-assed implementation of orderBy.
Fixes