You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@jena.apache.org by Claude Warren <cl...@xenei.com> on 2016/03/31 14:41:44 UTC

changing the namespace on all nodes in a model

I have a case where the some data I am reading has invalid namespace
characters (e.g. urn:java.package.name# )  I want to change them to valid
namespace names (e.g. urn:java-package-name#).  Is there a way to do this
within Jena or am I better served by writing the graph out and doing a
find/replace on the string?

Thx,
Claude

-- 
I like: Like Like - The likeliest place on the web
<http://like-like.xenei.com>
LinkedIn: http://www.linkedin.com/in/claudewarren

Re: changing the namespace on all nodes in a model

Posted by Dave Reynolds <da...@gmail.com>.
There is ResourceUtils#renameResource but for global changes, especially 
on large volumes of data, doing file level edits can be easier.

Dave

On 31/03/16 13:51, Don Rolph wrote:
> I always do this by doing a find/replace on the ttl file.
>
> On Thu, Mar 31, 2016 at 8:41 AM, Claude Warren <cl...@xenei.com> wrote:
>
>> I have a case where the some data I am reading has invalid namespace
>> characters (e.g. urn:java.package.name# )  I want to change them to valid
>> namespace names (e.g. urn:java-package-name#).  Is there a way to do this
>> within Jena or am I better served by writing the graph out and doing a
>> find/replace on the string?
>>
>> Thx,
>> Claude
>>
>> --
>> I like: Like Like - The likeliest place on the web
>> <http://like-like.xenei.com>
>> LinkedIn: http://www.linkedin.com/in/claudewarren
>>
>
>
>

Re: changing the namespace on all nodes in a model

Posted by Don Rolph <do...@gmail.com>.
I always do this by doing a find/replace on the ttl file.

On Thu, Mar 31, 2016 at 8:41 AM, Claude Warren <cl...@xenei.com> wrote:

> I have a case where the some data I am reading has invalid namespace
> characters (e.g. urn:java.package.name# )  I want to change them to valid
> namespace names (e.g. urn:java-package-name#).  Is there a way to do this
> within Jena or am I better served by writing the graph out and doing a
> find/replace on the string?
>
> Thx,
> Claude
>
> --
> I like: Like Like - The likeliest place on the web
> <http://like-like.xenei.com>
> LinkedIn: http://www.linkedin.com/in/claudewarren
>



-- 

73,
AB1PH
Don Rolph