Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
THRUST SERVICES & TOOLS
CLOUD EDITIONS
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Intelligence (Analytics)
Access a dataset from a data element
slievain
hi everybody,
Here is my issue : I've a dataset with two columns (label_code and label_name) and I would like to print the label_name corresponding to a particular label_code
in a data grid cell using a data element.
I tried different solutions :
- Accessing the dataset from a function defining a data element value.
- Saving every map (label_code and label_name) of the dataset in a persistentglobalvariable and accessing them from the script of a label..
but without success!
Does anyone have an idea to do such a thing?
Find more posts tagged with
Comments
mwilliams
Hi slievain,
Have you tried using the mapping functionality of BIRT? If I'm not understanding correctly, can you include a small sample of data and what you want to display? This way I can understand the problem more clearly. Thanks.
slievain
Here is an example :
Dataset "translated label" :
LABEL | TRANSLATED LABEL
NAME : "nom"
LASTNAME : "prenom"
ADDRESS : "adresse"
...
In a grid cell, I would like to display the translated label corresponding to LASTNAME (for example).
Thanks
bhanley
It looks to me like you are trying to implement localization for all or some of your report. BIRT makes this very easy to do via a properties file for each locale you want to support. This will allow your labels to be translated for multiple locales form the same report design, no need to re-work anything. You create a Properties file named for each locale (i.e. <em class='bbc'>en_US.properties</em>). Then add the file to your resources directory. In that file you can set up the mappings you are looking.<br />
<br />
Otherwise, if the values are always a 1-1 relationship, checkout data mapping as Michael mentioned. Here is a sample on DevShare to help get you started: <a class='bbc_url' href='
http://www.birt-exchange.org/devshare/birt-report-designers/805-data-mapping-example/'>Data
mapping example - Tips & Tricks - BIRT Exchange</a><br />
<br />
Good Luck!