How to display value of enumeration of work item in BIRT?
I would like to create the report displaying workitem with custom value which is enumeration type. I found on https://jazz.net/wiki/bin/view/Main/DataWarehouseSnapshotSchemas20 following two tables:
Enumerations and Live_Workitem_Cnt. However I completely have no idea how to connect them. Is there any third table I should use? Which columns I should join?
Thanks in advance for all replies :)
Accepted answer
In common there are 2 ways: using hash array and joining tables. Both examples are described here:
Comments
Hi Tal,
Here are my String key and String val values for Live_Workitem_Cnt:
30261
|
Test AVP Pipeline
|
|
severity.literal.l3
|
AVPpipeline.workitemtype.clientname
|
|
30261
|
Test AVP Pipeline
|
|
severity.literal.l3
|
Contracttype
|
Contracttype.literal.l2
|
30261
|
Test AVP Pipeline
|
|
severity.literal.l3
|
avppipeline.workitemtype.country
|
Country.literal.l8
|
30261
|
Test AVP Pipeline
|
|
severity.literal.l3
|
avppipeline.workitemtype.probability
|
avppipeline.workitemenum.probability.literal.050
|
30261
|
Test AVP Pipeline
|
|
severity.literal.l3
|
situation.workItemType.product2
|
Product.literal.l17
|
30261
|
Test AVP Pipeline
|
|
severity.literal.l3
|
AVPpipeline.workitemtype.salescontact
|
|
30261
|
Test AVP Pipeline
|
|
severity.literal.l3
|
AVPpipeline.workitemtype.imt
|
IMT.literal.l24
|
30261
|
Test AVP Pipeline
|
|
severity.literal.l3
|
AVPpipeline.workitemtype.AVLcontacts
|
|
30261
|
Test AVP Pipeline
|
|
severity.literal.l3
|
situation.workItemType.product
|
Product.literal.l13
|
30261
|
Test AVP Pipeline
|
|
severity.literal.l3
|
situation.workItemType.products
|
|
30261
|
Test AVP Pipeline
|
|
severity.literal.l3
|
AVPpipeline.workitemtype.AVPsales
|
|
You see for example following values
I tried already displaying list of all enumerations (from Enumeration table) but this table is empty. Is there any tutorial on jazz.net how to do that (step by step)?
One other answer
Comments
In LIVE_WORKITEM_CNT dataset STRING_VAL returns literal id value.
In ENUMERATIONS dataset LITERAL_ID returns literal id in same format.
All you have to do is to take care of different project areas (they may have different enumeration lists for same attribute)
1 vote
Thanks Vladimir. Now I have different issue. my Enumerations dataset is empty. I have no data there despite not using any filters.
Any ideas?
Is it empty in BIRT Designer Preview or while generating report in RTC?
In first case check you have specified ENUMERATION_ID sa parameter and optionally project area, without ENUMERATION_ID data set may fetch no data.
It is empty in BIRT Designer Preview. What do you mean by specifying ENUMERATION_ID?
I just wanted to display list of all enumerations. I created new Data source from workitems_snapshot. Then I created Simple Dataset and selected all columns from Enumerations table. That's all what I have done. I cannot see any data in the table created from this dataset and no data in results preview for this data set.
Please let me know if I am doing something wrong.
To get list of ENUMERATION_ID you must use PROJECT_AREA_ITEMID as parameter and set it. This data set cannot fetch all enumerations in repository, for all project areas. It's just the way it works - selec Project Area, then select ENUMERATION_ID you need and get list of literals\names.
P.S. In my previous comment it's wrong - ENUMERATION_ID parameter is optional, but PROJECT_AREA_ITEMID is mandatory to make it work.
1 vote
Comments
James Moody
JAZZ DEVELOPER Jan 28 '13, 10:21 a.m.LIVE_WORKITEM_CNT will return literal IDs of custom attribute values in STRING_VAL (given a STRING_KEY which identifies the custom attribute). You want to take that literal ID and map it into something human readable. For that you use the ENUMERATIONS table (which is also a live view) - ENUMERATIONS requires that you pass the project area (since enumerations and their values are scoped to a project area); you can then also supply the enumeration ID and the literal ID, and the data set will give you the literal value (label) so you can include it in your report. I don't believe we have any out-of-the-box examples of using this table, sorry.