简体   繁体   中英

result return empty for the path in sparql

why the result of path2 is empty?

When I try to concat two paths in one iri, it returns null. Why is the result of path2 empty?

PREFIX xx:   <http://xx.xx/xxx/xx#>                     
SELECT * {
bind(IRI(xx:A.B/xx:B.C) as $path1)
bind(IRI(concat(str(xx:A.B), "/", str(xx:B.C))) as $path2)
  bind(IRI(str("http://xx.xx/xxx/xx#A.B/http://xx.xx/xxx/xx#B.C")) as $path3)
}

"http://xx.xx/xxx/xx#AB/http://xx.xx/xxx/xx#BC"

is not a legal IRI because it has two # . A URI can have only one fragment.

In $path1:: / is numeric divide.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM