fixed search serialization in database
fixed order of header serialization