Verified Firebird data layer. Added some missing things and fixed some bugs.