(side note) preferably the local name of a URI should not start with a
number but a letter or underscore.

What do you mean by human-readable here? For large technical systems it's
simply not feasible to encode meaning into the URI and I might even
consider it an anti-pattern.

There are some community efforts that have introduced single letters and
number sequences for vocabulary development like CIDOC CRM which was later
also adopted by community projects like wikidata. But instance data
typically doesn't have that requirement and can be random but has to be
syntax compliant of course.

I am sure Andy can elaborate on the details of the encoding here.




On Fri, Nov 24, 2023 at 9:31 AM Laura Morales <[email protected]> wrote:

> Thank you a lot. FILTER(STR(?id) = "...") works, as suggested by Andy. I
> do recognize though that it is a hack, and that URLs should probably not
> have a [.
>
> But now I have trouble understanding UTF8 addresses. I would use random
> alphanumeric URLs everywhere if I could, or I would %-encode everything.
> But nodes IDs (URLs) are supposed to be valid, human-readable URLs because
> they're used online. Jena, and browsers, work fine with IRIs (which are
> UTF8), but the way special characters are used is not the same. For example
> it's perfectly fine in my graph to have a URL fragment, such as
> http://example.org/foo#bar but these URLs are not usable with a browser
> because the fragment is a local reference (local to the browser) that is
> not sent to the server. Which means in practice, that if I want to stay out
> of trouble I should not create a graph with IDs
>
> http://example.org/book#1
> http://example.org/book#2
> http://example.org/book#3
>
> in the case that I want to use these URLs with a web browser. Viceversa,
> browsers are perfectly fine with a [ in the path, but Jena is stricter.
>
> So, if I want to use UTF8 addresses (IRIs) in my graph, and if I don't
> want to %-encode them because I want them to be human-readbale (also
> because they are much easier to read/edit manually), what is the list of
> characters that MUST be %-encoded?
>
>
> > Sent: Friday, November 24, 2023 at 9:55 AM
> > From: "Marco Neumann" <[email protected]>
> > To: [email protected]
> > Subject: Re: Querying URL with square brackets
> >
> > Laura, see jena issue #2102
> > https://github.com/apache/jena/issues/2102
> >
> > Marco
>


-- 


---
Marco Neumann

Reply via email to