Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Intelligence (Analytics)
Need help accesing Data sets from the java code( for my own custom report item )
hmkumar
I am trying to create my custom report item line dotbar, rotated text thats available out there. I want to access Data sources and Data sets present within a report context from the java code at the generation/presentation layer.
First, I want to get a list of all data sources and data sets.
Then I have to process records(row wise) in data sets.
Find more posts tagged with
Comments
johnw
The Line Bar and Rotated text items do not require any additional scripting to implement. Just drop them in your table and go.<br />
<br />
If you are looking to access you data sources and data sets to do some dynamic report item generation, this must be done in the onPrepare events. You cannot access data (rows) during the phase. So, for example, you can't reference a Data Set and iterate through rows. The best you can do with that is access the data in something like the onFetch event, and change conditional highlighting.<br />
<br />
There is a small workaround, where you can create a Dynamic Report Parameter populated off of a data set, and during the onPrepare phase, use a Parameter Extraction task to get access to the values, but you will be limited to a single column.<br />
<br />
John<br />
<br />
<blockquote class='ipsBlockquote' data-author="'hmkumar'" data-cid="66586" data-time="1279661712" data-date="20 July 2010 - 02:35 PM"><p>
I am trying to create my custom report item line dotbar, rotated text thats available out there. I want to access Data sources and Data sets present within a report context from the java code at the generation/presentation layer. <br />
First, I want to get a list of all data sources and data sets.<br />
Then I have to process records(row wise) in data sets.<br /></p></blockquote>
hmkumar
Thanks for helping me with my question. I will try to explain what I have been trying to achieve.<br />
I want to create a reportItem (drag n drop from palette). I want to pass a dataset's name as input to that control. And I will access the data set record by record to generate HTML Content (Output string) and I could use OUTPUT_MODE HTML_TEXT OR IMAGE_WITH_MAP. I thought rotatedText is a good starting point to start modifying and building on top of it.<br />
<br />
I am curious how I should get access to the data sets within that report's context. Please let me know.<br />
<br />
I tried going through the part of code responsible for creating preview results in Data set Editor. Is that the right way to approach it ?<br />
<br />
Thanks,<br />
Hari<br />
<blockquote class='ipsBlockquote' data-author="'johnw'" data-cid="66588" data-time="1279662912" data-date="20 July 2010 - 02:55 PM"><p>
The Line Bar and Rotated text items do not require any additional scripting to implement. Just drop them in your table and go.<br />
<br />
If you are looking to access you data sources and data sets to do some dynamic report item generation, this must be done in the onPrepare events. You cannot access data (rows) during the phase. So, for example, you can't reference a Data Set and iterate through rows. The best you can do with that is access the data in something like the onFetch event, and change conditional highlighting.<br />
<br />
There is a small workaround, where you can create a Dynamic Report Parameter populated off of a data set, and during the onPrepare phase, use a Parameter Extraction task to get access to the values, but you will be limited to a single column.<br />
<br />
John<br /></p></blockquote>