Community
Participate
Working Groups
Build Identifier: 2.6.1 , 2.5.2, 2.3.2 I have to load the first parameter of the cascade based on the session username value. I have used <method name="beforeOpen"><![CDATA[var username;]]>var username =reportContext.getHttpServletRequest().getSession().getAttribute("username");</method> and <list-property name="parameters"> <structure> <property name="name">param_1</property> <property name="nativeName"></property> <property name="dataType">string</property> <property name="nativeDataType">12</property> <property name="position">2</property> <expression name="defaultValue">username</expression> <property name="isInput">true</property> <property name="isOutput">false</property> </structure> </list-property> and <property name="queryText"> select c.country_name, s.state_name from country c, state s where s.country_id =c.country_id and username = ? </property> But the value is not getting passed. Is there any way to pass the value Reproducible: Always Steps to Reproduce: I have to load the first parameter of the cascade based on the session username value. I have used <method name="beforeOpen"><![CDATA[var username;]]>var username =reportContext.getHttpServletRequest().getSession().getAttribute("username");</method> and <list-property name="parameters"> <structure> <property name="name">param_1</property> <property name="nativeName"></property> <property name="dataType">string</property> <property name="nativeDataType">12</property> <property name="position">2</property> <expression name="defaultValue">username</expression> <property name="isInput">true</property> <property name="isOutput">false</property> </structure> </list-property> and <property name="queryText"> select c.country_name, s.state_name from country c, state s where s.country_id =c.country_id and username = ? </property> But the value is not getting passed. Is there any way to pass the value
Unable to access the session values in parameter page - cascade data set query
Created attachment 201899 [details] jsp and report
Sasikala, Please see attached files. I get session attribute in report initialize method and use it in Dataset parameter. It works. I set this as Fixed, if you still think it has issue, please reopen this bug. Thanks.
Set fixed, if still cannot work with the sample, please reopen it.
Reopen this issue. Session attribute get in beforeOpen isn't available in Dataset Parameter panel, this is a bug.