On 24/05/2011 16:55, Alexandre Passant wrote: > I've seen doc at [1], but is there a way to do regex-based renaming of graphs > in Virtuoso ? > > E.g. rename all graphs with URI scheme http://example.org/foo/* into > http://example.org/bar/* > > Thanks > > Alex. > > [1] http://ods.openlinksw.com/wiki/main/Main/VirtTipsAndTricksGuideRenameGraph
Hi, Yes, it should be possible. Consider the following: select distinct( iri_to_id( regexp_replace(id_to_iri(g), 'openlink', 'localhost') ) ) from DB.DBA.RDF_QUAD where regexp_match('openlink', id_to_iri(g)) Converting that to an update is left as an exercise :) HTH, ~Tim -- Tim Haynes Product Development Consultant OpenLink Software <http://www.openlinksw.com/> <http://twitter.com/openlink>