Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RDF API does not include composite references #4546

Open
1 task done
svandenhoek opened this issue Dec 5, 2024 · 1 comment · May be fixed by #4566
Open
1 task done

RDF API does not include composite references #4546

svandenhoek opened this issue Dec 5, 2024 · 1 comment · May be fixed by #4566
Assignees
Labels
api:rdf bug Something isn't working

Comments

@svandenhoek
Copy link
Contributor

Have you checked if this issue already exists?

  • yes

Molgenis EMX2 version

Software version: v11.38.0-SNAPSHOT. Database version: 23.

Description

When having a schema such as:
Scherm­afbeelding 2024-12-05 om 16 32 53

When creating data in the composite table and referring to that row in the ref table, the RDF API does not include that reference:

<http://localhost:8080/test/api/rdf/Composite?a=1&b=2> a Test:Composite, qb:Observation;
  qb:dataSet Test:Composite;
  rdfs:label "1 2";
  <http://localhost:8080/test/api/rdf/Composite/column/a> "1";
  <http://localhost:8080/test/api/rdf/Composite/column/b> "2";
  <http://localhost:8080/test/api/rdf/Composite/column/mg_draft> false;
  fdp-o:metadataIssued "2024-12-05T16:33:27"^^xsd:dateTime;
  dcterms:issued "2024-12-05T16:33:27"^^xsd:dateTime;
  <http://localhost:8080/test/api/rdf/Composite/column/mg_insertedOn> "2024-12-05T16:33:27"^^xsd:dateTime;
  fdp-o:metadataModified "2024-12-05T16:33:27"^^xsd:dateTime;
  <http://localhost:8080/test/api/rdf/Composite/column/mg_updatedOn> "2024-12-05T16:33:27"^^xsd:dateTime .

<http://localhost:8080/test/api/rdf/Ref?id=1> a Test:Ref, qb:Observation;
  qb:dataSet Test:Ref;
  rdfs:label "1";
  <http://localhost:8080/test/api/rdf/Ref/column/id> "1";
  <http://localhost:8080/test/api/rdf/Ref/column/mg_draft> false;
  fdp-o:metadataIssued "2024-12-05T16:34:09"^^xsd:dateTime;
  dcterms:issued "2024-12-05T16:34:09"^^xsd:dateTime;
  <http://localhost:8080/test/api/rdf/Ref/column/mg_insertedOn> "2024-12-05T16:34:09"^^xsd:dateTime;
  fdp-o:metadataModified "2024-12-05T16:34:09"^^xsd:dateTime;
  <http://localhost:8080/test/api/rdf/Ref/column/mg_updatedOn> "2024-12-05T16:34:09"^^xsd:dateTime .

Reproduction steps

  1. Go to http://localhost:8080/
  2. Create schema as shown in screenshot (create database without a template)
  3. Go to http://localhost:8080/test/tables/#/Composite and create new row (a=1, b=2)
  4. Go to http://localhost:8080/test/tables/#/Ref and create new ro (id=1, ref item from step 3)
  5. Go to http://localhost:8080/test/api/rdf/ and check output

Expected behaviour

The following triple should be included:

<http://localhost:8080/test/api/rdf/Ref?id=1> <http://localhost:8080/test/api/rdf/Ref/column/ref> <http://localhost:8080/test/api/rdf/Composite?a=1&b=2> .

System configuration

No response

@svandenhoek svandenhoek added bug Something isn't working api:rdf labels Dec 5, 2024
@svandenhoek svandenhoek self-assigned this Dec 5, 2024
@svandenhoek
Copy link
Contributor Author

REFBACKS to composite keys cause errors in RDF API, such as:

{
  "errors" : [
    {
      "message" : "RDF export failed due to an exception: Query failed: : column a0.reused in resources.resource does not exist. "
    }
  ]
}

@svandenhoek svandenhoek linked a pull request Dec 16, 2024 that will close this issue
3 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api:rdf bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant