Export the oids from DB