Yes, these examples helped. I have been able to figure out how to do it. Thanks a lot, David.
Best regards, Kai On Wednesday, 18 May 2022 at 11:36:14 UTC+2 David Price wrote: > Please see examples in the following spec of how to use SPARQL CONSTRUCT > for the most general case of how to infer any triples. There are also > built-in SHACL features you might use. > > https://w3c.github.io/shacl/shacl-af/#rules-examples > > Cheers, > David > > On 18 May 2022, at 10:31, Kai Liu <[email protected]> wrote: > > I have two classes *ClassA *and *ClassB*, with each having an ID > attribute. *ClassA *has an additional relationship *hasB*, which should > point to an instance of *ClassB*, only if the IDs of both instances are > equal. Is it possible to define a SHACL inference rule to auto-generate > this relationship? The pseudo-code is as follows: > > Input: > InstanceA a ClassA. > InstanceA :id "1234". > InstanceB a ClassB. > InstanceB :id "1234". > > Expected output: > InstanceA :hasB InstanceB. > > Any suggestions are much appreciated. Thanks. > > > > -- > You received this message because you are subscribed to the Google Groups > "TopBraid Suite Users" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/topbraid-users/eca2320e-9089-491a-8774-1c7348a72434n%40googlegroups.com > > <https://groups.google.com/d/msgid/topbraid-users/eca2320e-9089-491a-8774-1c7348a72434n%40googlegroups.com?utm_medium=email&utm_source=footer> > . > > > UK +44 (0) 7788 561308 <+44%207788%20561308> > US +1 (336) 283-0808 <(336)%20283-0808> > > -- You received this message because you are subscribed to the Google Groups "TopBraid Suite Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/topbraid-users/7edd0d5c-43d9-4524-999c-884596ae6770n%40googlegroups.com.
