getIDs from every table in the database