adding header sorting to reyring table