refactoring get_rdf_statements