if you use LATERAL keyword it might work:
SELECT * WHERE
{
VALUES ?g { <https://example.com/a> }
LATERAL {
GRAPH ?g
{
?s a :blah .
BIND(CONCAT(STR(?g), "/b") AS ?gb )
}
}
}
On 06.11.24 13:25, Lorenz Buehmann wrote:
Hi,
according to the algebra
(base <http://example/base/>
(prefix ((: <http://purl.org/dc/elements/1.1/>)
(rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>)
)
(join
(table (vars ?g)
(row [?g <https://example.com/a>])
)
(graph ?g
(extend ((?gb (concat (str ?g) "/b")))
(bgp (triple ?s rdf:type :blah)))))))
I guess ?g is not in scope of the graph pattern during evaluation,
thus, STR fails, thus CONCAT fails, thus ?gb is unbound
Lorenz
On 06.11.24 13:05, Mikael Pesonen wrote:
Hi, why is this bind not working? This returns an empty column for
?ga. What is the correct way to add ?gb?
SELECT * WHERE
{
VALUES ?g { <https://example.com/a> }
GRAPH ?g
{
?s a :blah .
BIND(CONCAT(STR(?g), "/b") AS ?gb )
}
}
--
Lorenz Bühmann
Research Associate/Scientific Developer
Email buehm...@infai.org
Institute for Applied Informatics e.V. (InfAI) | Goerdelerring 9 | 04109
Leipzig | Germany