added comments in ordering fields code