Php Create Array From Sql Results To File