SQL Query for linked WorkItems

Posts: 5
Joined: Thu Oct 26, 2017 4:08 pm

SQL Query for linked WorkItems

Postby rpn » Thu Oct 26, 2017 4:40 pm

I need to trace the WorkItems in a document (CustomerRequirements-Document) down to the tests in different Levels (to ensure coverage).

My Query is like that:

Code: Select all

select * from polarion.WorkItem
where polarion.WorkItem.c_pk in (select * from polarion.lucene_query('WorkItem', 'type:customerrequirement AND document.title:(CustomReqs Platform XY)', 'id'))
AND c_deleted is false AND fk_project = [$project_id];

But the result is missing most of the Items visible via the WebInterface - the result is the same with matching via c_URI instead of c_pk, or with querying STRUCT_WORKITEM_LINKEDWORKITEMS.

STRUCT_WORKITEM_LINKEDWORKITEMSDERIVED is an empty Table, so no luck there, either.

I've read the SQL-Documents in the /sdk/-Folder in our local install, but can't figure it out on my own.

Iam thankful for every hint, on how to get all links from a Workitem out of the database.

Return to “Polarion Application Lifecycle Management (ALM)”

Who is online

Users browsing this forum: No registered users and 2 guests