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)
birt:param tag: need help
Venny
Hello All,<br />
<br />
<br />
I am working with IBM and using birt tool to generate a report on one of my assignments. I am facing problem with what am trying to accomplish. Here is a general overview of my requirement. <br />
<br />
I am creating two jsp pages say index.jsp and display.jsp. <br />
<br />
On index.jsp, am taking an input from the user say customer number and on display.jsp, am embedding a birt report having a variable CustNum. <br />
<br />
I want the birt report on display.jsp page to take value that was entered by user in index.jsp and generate a report for that Customer only. <br />
<br />
My understanding is I need to use the birt:param tag to set the value of the report parameter. But it just wont work. <br />
<br />
Here is the code for display.jsp<br />
<br />
<% String CustNum = request.getParameter("CustNum");<br />
out.println(Integer.parseInt(CustNum));<br />
%> <br />
<br />
<birt:viewer id="birtViewer" <br />
reportDesign="testBirt.rptdesign"<br />
pattern="run"<br />
height="450"<br />
width="900"<br />
format="html" <br />
showParameterPage="False" <br />
baseURL="/birt"><br />
<strong class='bbc'> <birt:param name="CustId" value="<%=CustNum%>" ></birt:param> </strong><br />
</birt:viewer><br />
<br />
I tried using birt:param outside the viewer tag but i wont do anything. Inside the viewer tag, it gives an java lang error.<br />
<br />
Any help would be much appreciated. I am kind of stuck on this since yesterday.<br />
<br />
Thanks
Find more posts tagged with
Comments
mwilliams
I haven't done this before. What's your BIRT version? I'll give it a go.