Hello,
I am trying to pull data from the table "HVTN SDMC Lab/Assay Data Status Tracker" using the labkey python API. The table is located at:
https://atlas.scharp.org/cpas/list/HVTN/Tools and Reports/SCHARP LDO/Assay Tracker/grid.view?listId=24
I have version 3.0.0 of the labkey package installed, and I have tried various combinations of variables which throw different errors. For example:
labkey_server = "atlas.scharp.org"
project_name = "HVTN" # Project folder name
context_path = "cpas"
api = APIWrapper(labkey_server, project_name, context_path, use_ssl=True)
schema = "lists"
table = "HVTN SDMC Lab/Assay Data Status Tracker"
result = api.query.select_rows(schema, table)
returns the error QueryNotFoundError: "404: The specified query 'HVTN SDMC Lab/Assay Data Status Tracker' does not exist in schema 'lists'"
(full traceback attached).
When viewing the page on my browser (I'm using Chrome), the header says:
Lists / HVTN SDMC Lab/Assay Data Status Tracker
HVTN SDMC Lab/Assay Data Status Tracker [folder image] Assay Tracker
(see attached screenshot).
So I have also tried
labkey_server = "atlas.scharp.org"
project_name = "Assay Tracker" # Project folder name
context_path = "cpas"
api = APIWrapper(labkey_server, project_name, context_path, use_ssl=True)
schema = "lists"
table = "HVTN SDMC Lab/Assay Data Status Tracker"
result = api.query.select_rows(schema, table)
But then I get QueryNotFoundError: '404: No such project: /Assay Tracker'
.
Going through https://github.com/LabKey/labkey-api-python I couldn't find any utilities that would list projects or tables within a schema -- is there such a method available? I'm sorry I know this is more of a question about the structure of the database I'm trying to access, but I can't figure out how to figure out that structure and thus the appropriate method arguments. Can you advise?
Thank you so much!
Beatrix