Fix write_attribute method
Tests for binary column bug - postgres adapter