Added query support to files