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)
Sorting in BIRT
Jac
Hi,
I am having a report where i am showing data from the database(Its displayed as a table).I need to perform sorting in ascending and descending order on clicking the column name.Can this be done?Please help me.Looking forward from you.
Thanks,
Jac
Find more posts tagged with
Comments
mwilliams
Hi Jac,<br />
<br />
Check out this post from the devShare. It may help you out.<br />
<br />
<a class='bbc_url' href='
http://www.birt-exchange.org/devshare/designing-birt-reports/265-birt-resort-columns-after-report-has-been-run/#description'>BIRT
: Resort Columns After Report Has Been Run - Tips & Tricks - BIRT Exchange</a>
Jac
Hi,<br />
<br />
Thanks for your response.But it seems not working.I am getting the following error.<br />
<br />
The following items have errors:<br />
<br />
<br />
<br />
Label (id = 20):<br />
+ There are errors evaluating script "importPackage (Packages.org.eclipse.birt.report.model.api.simpleapi);if ( params["paramsSortOrder"].value != null ){var sortCondition = SimpleElementFactory.getInstance().createSortCondition();switch (params["paramsSortOrder"].value){case "name" :sortCondition.setKey("row["customerName"]");break;}sortCondition.setDirection("asc");this.addSortCondition(sortCondition);}":<br />
TypeError: Cannot find function addSortCondition. (/report/body/table[
@id="
;15"]/header/row[
@id="
;16"]/cell[
@id="
;19"]/label[
@id="
;20"]/method[
@name="
;onPrepare"]#1).<br />
<br />
<br />
<br />
<br />
Table (id = 15):<br />
+ An exception occurred during processing. Please see the following message for details:<br />
Cannot set the string value (asc) to parameter 17.<br />
Cannot set preparedStatement parameter string value.<br />
SQL error #1: Parameter index out of bounds. 17 is not between valid values of 1 and 16<br />
<br />
exception.error ( 1 time(s) )<br />
detail : org.eclipse.birt.report.engine.api.EngineException: An exception occurred during processing. Please see the following message for details:<br />
Cannot set the string value (asc) to parameter 17.<br />
Cannot set preparedStatement parameter string value.<br />
SQL error #1: Parameter index out of bounds. 17 is not between valid values of 1 and 16<br />
<br />
<br />
Data (id = 142):<br />
+ An exception occurred during processing. Please see the following message for details:<br />
Cannot set the string value (asc) to parameter 17.<br />
Cannot set preparedStatement parameter string value.<br />
SQL error #1: Parameter index out of bounds. 17 is not between valid values of 1 and 16<br />
<br />
I am stuck ,i donot know how to fix it.Please help me.<br />
<br />
Thanks,<br />
Jac<br />
<br />
<blockquote class='ipsBlockquote' data-author="mwilliams"><p>Hi Jac,<br />
<br />
Check out this post from the devShare. It may help you out.<br />
<br />
<a class='bbc_url' href='
http://www.birt-exchange.org/devshare/designing-birt-reports/265-birt-resort-columns-after-report-has-been-run/#description'>BIRT
: Resort Columns After Report Has Been Run - Tips & Tricks - BIRT Exchange</a></p></blockquote>
Jac
Hi,<br />
<br />
Thanks for your response.But it seems not working.I am getting the following error.<br />
<br />
The following items have errors:<br />
<br />
Label (id = 20):<br />
+ There are errors evaluating script "importPackage (Packages.org.eclipse.birt.report.model.api.simpleapi);if ( params["paramsSortOrder"].value != null ){var sortCondition = SimpleElementFactory.getInstance().createSortCondition();switch (params["paramsSortOrder"].value){case "name" :sortCondition.setKey("row["customerName"]");break;}sortCondition.setDirection("asc");this.addSortCondition(sortCondition);}":<br />
TypeError: Cannot find function addSortCondition. (/report/body/table[
@id="
;15"]/header/row[
@id="
;16"]/cell[
@id="
;19"]/label[
@id="
;20"]/method[
@name="
;onPrepare"]#1).<br />
<br />
Table (id = 15):<br />
+ An exception occurred during processing. Please see the following message for details:<br />
Cannot set the string value (asc) to parameter 17.<br />
Cannot set preparedStatement parameter string value.<br />
SQL error #1: Parameter index out of bounds. 17 is not between valid values of 1 and 16<br />
<br />
exception.error ( 1 time(s) )<br />
detail : org.eclipse.birt.report.engine.api.EngineException: An exception occurred during processing. Please see the following message for details:<br />
Cannot set the string value (asc) to parameter 17.<br />
Cannot set preparedStatement parameter string value.<br />
SQL error #1: Parameter index out of bounds. 17 is not between valid values of 1 and 16<br />
<br />
<br />
Data (id = 142):<br />
+ An exception occurred during processing. Please see the following message for details:<br />
Cannot set the string value (asc) to parameter 17.<br />
Cannot set preparedStatement parameter string value.<br />
SQL error #1: Parameter index out of bounds. 17 is not between valid values of 1 and 16<br />
<br />
I am stuck ,i donot know how to fix it.Please help me.<br />
<br />
Thanks,<br />
Jac<br />
<br />
<blockquote class='ipsBlockquote' data-author="mwilliams"><p>Hi Jac,<br />
<br />
Check out this post from the devShare. It may help you out.<br />
<br />
<a class='bbc_url' href='
http://www.birt-exchange.org/devshare/designing-birt-reports/265-birt-resort-columns-after-report-has-been-run/#description'>BIRT
: Resort Columns After Report Has Been Run - Tips & Tricks - BIRT Exchange</a></p></blockquote>
Jac
Can anyone help me to do sorting by both ascending and descending by column name?
mwilliams
Jac,
What version of BIRT are you using?
Jac
Hi Micheal,<br />
<br />
I am using BIRT 2.3.1<br />
<br />
Thanks,<br />
Jac<br />
<br />
<blockquote class='ipsBlockquote' data-author="mwilliams"><p>Jac,<br />
<br />
What version of BIRT are you using?</p></blockquote>
mwilliams
Jac,
Take a look at this report design.
Sapphie
Thanks for this sample design file, which I have downloaded and run successfully.
I want to be able to let the user sort on more than one column, eg on the CHECKNUMBER column in this report, which is a string. I tried to replicate this with another parameter called sortOrder1 and used that in the hyperlink for the CHECKNUMBER column but it didn't work.
Can I only sort by one column per report this way or do I need to specify some sort of ASC/DESC sorting as the other column is a string?
Thanks
Lee
(still very new to all this)
Sapphie
I suppose I could two multiple copies of the same report, differing only by sort order and then hyperlinking from one to the other but there must be a simpler way?
Lee
mwilliams
Wow, this is from a long time ago!
So, you want to be able to specify 2 columns to sort by? Sort by column x first, then sort that result by column y? Is this what you're wanting? If so, will there always be 2 columns selected? Or will one be optional?
Sapphie
Thanks for the reply Michael; well just proves I did a forum search before asking!
I do not need to to sort by two columns but imagine the scenario where I might want to give the user the ability to sort by any of the available column headings, so for each heading to have a hyperlink that sorts by just that column, the columns could be numeric, string, date etc.
For now I just wanted to try this on two columns, one numeric, one string.
Lee
mwilliams
Lee,
So, you want a link at the top of each column that will sort that given column? I think I have an old example that does this. I'll look for it if that's correct.
mwilliams
Lee,
I couldn't find the old design. I think I lost it in an OS upgrade a while back. Essentially all you'd have to do is create another hidden parameter that passes the column name on the click, then change the value of the sortkey in the script on the table that sets the sort.
Let me know if you have questions.
Sapphie
Michael
Ok, thanks, I'll try to give that a go!
Lee
mwilliams
Lee,
Let me know if you get stuck and would like an example.
Sapphie
Michael
Ok, I think I understand now. I was missing the fact that your sample also had an onPrepare script as well as the expression for the column hyperlink!
I have a version now that does what I want.
Not terribly intuitive and I was hoping to get away from coding :-) as I am trying BIRT as a replacement for soeme PHP-driven reports. However, good to see the kinds of things that we can do. I just need to understand more I guess.
Lee
mwilliams
Lee,
You could probably also use the expression builder when you add a sort condition in the sort tab in the property editor for the table, but it would still involve some minor scripting to build the sort key from your parameter. If you didn't want ascending and descending sorting, this might be an easier option, though.
Eswar B
Hi Michael,
Thanks for the sample DynamicSort file..
It is working fine with one column. If I want to sort all the columns in a table is there any way.
What I have to add/change in the onPrepare script.
Regards
Eswar
mwilliams
What do you mean by sorting all the columns? Can you explain a little bit more on this?
Eswar B
In the example you mentioned you are sorting it for the last column and I want to sort all the columns and I did it by assigning keys for all the columns and it worked fine in the report preview.
But when I called it using JSP through the tomcat server the functionality is not working. Whenever i click on the column it is refreshing and not displaying any report.
mwilliams
Can you make a sample report using the sample database that does not work when you run it on the tomcat server? This way I can see what you're doing and also run and test on the report. Thanks!
Eswar B
<blockquote class='ipsBlockquote' data-author="'mwilliams'" data-cid="79146" data-time="1309207668" data-date="27 June 2011 - 01:47 PM"><p>
Can you make a sample report using the sample database that does not work when you run it on the tomcat server? This way I can see what you're doing and also run and test on the report. Thanks!<br /></p></blockquote>
<br />
Hi Michael,<br />
<br />
I have attached the report which you have posted with my modifications in the beforeOpen script.<br />
<br />
What I am intended to do is The parameter will be sent from jsp page using the <birt:parameterPage> tag and submitted to it then the report will be generated according to the values it takes from the JSP page when I run it on tomcat server. <br />
<br />
The concern is when I execute the run the jsp page on server the report is generated and when I click on the column to sort it is not sorting and it is not displaying any value.<br />
<br />
<br />
hope you understood my problem.<br />
<br />
Thanks ...<br />
Eswar
Eswar B
Amy one please give me a solution for the above post
thanks in advance
mwilliams
In the report you attached, I added a check for null in the beforeOpen script of the dataSet where you edit your query and then deployed it on Tomcat and it worked as expected for me. The only column with a sort hyperlink on it is the last one and when I click on it, it changes from ascending to descending.
madhur
I modified the DynamicSort.rptdesign to add sorting to all the four columns. (my file is attached with this.)<br />
I removed the customer_number parameter as it was giving an error.<br />
<br />
Updated the onPrepare script like this (added cases for all the table columns)<br />
<br />
if ( params["SortOrder"].value != 0 ){ <br />
importPackage(Packages.org.eclipse.birt.report.model.api.simpleapi);<br />
sortCondition = SimpleElementFactory.getInstance().createSortCondition(); <br />
switch (params["SortOrder"].value) { <br />
case 1 : <br />
sortCondition.setKey("row[\"AMOUNT\"]");<br />
sortCondition.setDirection("asc"); <br />
break; <br />
case 2 : <br />
sortCondition.setKey("row[\"AMOUNT\"]");<br />
sortCondition.setDirection("desc"); <br />
break;<br />
<br />
case 3 : <br />
sortCondition.setKey("row[\"CUSTOMERNUMBER\"]");<br />
sortCondition.setDirection("asc"); <br />
break; <br />
case 4 : <br />
sortCondition.setKey("row[\"CUSTOMERNUMBER\"]");<br />
sortCondition.setDirection("desc"); <br />
break;<br />
<br />
<span style='color: #0000FF'>case 5 : <br />
sortCondition.setKey("row[\"PAYMENTDATE\"]");<br />
sortCondition.setDirection("asc"); <br />
break; <br />
case 6 : <br />
sortCondition.setKey("row[\"PAYMENTDATE\"]");<br />
sortCondition.setDirection("desc"); <br />
break; <br />
<br />
case 7 : <br />
sortCondition.setKey("row[\"CHECKNUMBER\"]");<br />
sortCondition.setDirection("asc"); <br />
break; <br />
case 8 : <br />
sortCondition.setKey("row[\"CHECKNUMBER\"]");<br />
sortCondition.setDirection("desc"); <br />
break; </span><br />
<br />
} <br />
<br />
this.addSortCondition(sortCondition);}<br />
<br />
And added Hyperlinks for all the table headings<br />
<br />
And for each SortOrder parameter in these added the relevant values like this <br />
if (params["SortOrder"].value == 0){<br />
5}<br />
else if (params["SortOrder"].value == 5){<br />
6}<br />
else{<br />
5}<br />
<br />
If anyone looking for the basic steps...this can be useful<br />
<a class='bbc_url' href='
http://digiassn.blogspot.com/2007/05/birt-strong-suit-is-in-realm-of-online.html'>http://digiassn.blogspot.com/2007/05/birt-strong-suit-is-in-realm-of-online.html</a>
;
hmca
hi,<br />
<br />
Kindly anyone suggest how to fix this error:<br />
<br />
i am trying to implement sorting in column header(Asc and desc )order<br />
<br />
org.eclipse.birt.report.engine.api.EngineException: There are errors evaluating script "if (params["rptprmSortOrder"].value != null ) <br />
{ importPackage(Packages.org.eclipse.birt.report.engine.api.script.element); importPackage(Packages.org.eclipse.birt.report.model.api.simpleapi); <br />
var sortCondition = StructureScriptAPIFactory.createSortCondition(); <br />
switch (params["rptprmSortOrder"].value) { <br />
case 1 : sortCondition.setKey("row[\"usr_id\"]"); sortCondition.setDirection("ASC"); break; <br />
case 2 : sortCondition.setKey("row[\"usr_id\"]"); sortCondition.setDirection("DESC"); break; }<br />
var sortKey = sortCondition.getStructure(); <br />
this.addSortCondition( SimpleElementFactory.getInstance().createSortCondition(sortKey)); } ": <br />
<br />
<span style='color: #FF0000'><strong class='bbc'>Wrapped org.eclipse.birt.report.model.api.metadata.PropertyValueException: The value <br />
of the property "Sort Key" is required. (/report/body/table[
@id="
;10"]/method[
@name="
;onPrepare"]#22) (Element ID:10) at </strong></span><br />
<br />
<br />
org.eclipse.birt.report.engine.executor.ExecutionContext.addException(ExecutionContext.java:1237) at <br />
org.eclipse.birt.report.engine.api.impl.ScriptedDesignHandler.processOnPrepareScript(ScriptedDesignHandler.java:267) at <br />
org.eclipse.birt.report.engine.api.impl.ScriptedDesignHandler.handleOnPrepare(ScriptedDesignHandler.java:136) at <br />
org.eclipse.birt.report.engine.api.impl.ScriptedDesignVisitor.visitTable(ScriptedDesignVisitor.java:306) at org.eclipse.birt.report.model.api.DesignVisitorImpl<br />
$Forwarder.visitTable(DesignVisitorImpl.java:1100) at org.eclipse.birt.report.model.elements.TableItem.apply(TableItem.java:91) at <br />
org.eclipse.birt.report.model.api.DesignVisitorImpl.apply(DesignVisitorImpl.java:127) at <br />
org.eclipse.birt.report.engine.api.impl.ScriptedDesignVisitor.visitReportDesign(ScriptedDesignVisitor.java:108) at org.eclipse.birt.report.model.api.DesignVisitorImpl<br />
$Forwarder.visitReportDesign(DesignVisitorImpl.java:1222) at org.eclipse.birt.report.model.elements.ReportDesign.apply(ReportDesign.java:65) at <br />
org.eclipse.birt.report.model.api.DesignVisitorImpl.apply(DesignVisitorImpl.java:127) at org.eclipse.birt.report.engine.api.impl.EngineTask.prepareDesign(EngineTask.java:1876) at <br />
org.eclipse.birt.report.engine.api.impl.RunAndRenderTask.doRun(RunAndRenderTask.java:99) at <br />
org.eclipse.birt.report.engine.api.impl.RunAndRenderTask.run(RunAndRenderTask.java:77) at <br />
org.eclipse.birt.report.service.ReportEngineService.runAndRenderReport(ReportEngineService.java:929) at <br />
org.eclipse.birt.report.service.BirtViewerReportService.runAndRenderReport(BirtViewerReportService.java:973) at <br />
org.eclipse.birt.report.service.actionhandler.BirtGetPageAllActionHandler.__execute(BirtGetPageAllActionHandler.java:131) at <br />
org.eclipse.birt.report.service.actionhandler.AbstractBaseActionHandler.execute(AbstractBaseActionHandler.java:90) at <br />
org.eclipse.birt.report.soapengine.processor.AbstractBaseDocumentProcessor.__executeAction(AbstractBaseDocumentProcessor.java:47) at <br />
org.eclipse.birt.report.soapengine.processor.AbstractBaseComponentProcessor.executeAction(AbstractBaseComponentProcessor.java:143) at <br />
org.eclipse.birt.report.soapengine.processor.BirtDocumentProcessor.handleGetPageAll(BirtDocumentProcessor.java:183) at sun.reflect.GeneratedMethodAccessor36.invoke(Unknown <br />
Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at <br />
org.eclipse.birt.report.soapengine.processor.AbstractBaseComponentProcessor.process(AbstractBaseComponentProcessor.java:112) at <br />
org.eclipse.birt.report.soapengine.endpoint.BirtSoapBindingImpl.getUpdatedObjects(BirtSoapBindingImpl.java:66) at sun.reflect.GeneratedMethodAccessor28.invoke(Unknown Source) <br />
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at <br />
org.apache.axis.providers.java.RPCProvider.invokeMethod(RPCProvider.java:397) at org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:186) at <br />
org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:323) at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32) at <br />
org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118) at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83) at <br />
org.apache.axis.handlers.soap.SOAPService.invoke(SOAPService.java:454) at org.apache.axis.server.AxisServer.invoke(AxisServer.java:281) at <br />
org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:699) at <br />
org.eclipse.birt.report.servlet.BirtSoapMessageDispatcherServlet.doPost(BirtSoapMessageDispatcherServlet.java:265) at javax.servlet.http.HttpServlet.service(HttpServlet.java:727) <br />
at org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:327) at javax.servlet.http.HttpServlet.service(HttpServlet.java:820) at <br />
org.eclipse.birt.report.servlet.BirtSoapMessageDispatcherServlet.service(BirtSoapMessageDispatcherServlet.java:122) at org.eclipse.equinox.http.registry.internal.ServletManager<br />
$ServletWrapper.service(ServletManager.java:180) at org.eclipse.equinox.http.servlet.internal.ServletRegistration.service(ServletRegistration.java:61) at <br />
org.eclipse.equinox.http.servlet.internal.ProxyServlet.processAlias(ProxyServlet.java:126) at org.eclipse.equinox.http.servlet.internal.ProxyServlet.service(ProxyServlet.java:60) at <br />
javax.servlet.http.HttpServlet.service(HttpServlet.java:820) at org.eclipse.equinox.http.jetty.internal.HttpServerManager<br />
$InternalHttpServiceServlet.service(HttpServerManager.java:317) at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:511) at <br />
org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:390) at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182) at <br />
org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765) at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152) at <br />
org.mortbay.jetty.Server.handle(Server.java:326) at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:542) at org.mortbay.jetty.HttpConnection<br />
$RequestHandler.content(HttpConnection.java:939) at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:756) at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:<br />
212) at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404) at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:409) at <br />
org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:582) Caused by: org.eclipse.birt.core.exception.CoreException: There are errors evaluating script "if <br />
(params["rptprmSortOrder"].value != null ) { importPackage(Packages.org.eclipse.birt.report.engine.api.script.element); <br />
importPackage(Packages.org.eclipse.birt.report.model.api.simpleapi); var sortCondition = StructureScriptAPIFactory.createSortCondition(); switch (params["rptprmSortOrder"].value) <br />
{ case 1 : sortCondition.setKey("row[\"usr_id\"]"); sortCondition.setDirection("ASC"); break; case 2 : sortCondition.setKey("row[\"usr_id\"]"); sortCondition.setDirection("DESC"); <br />
break; } var sortKey = sortCondition.getStructure(); this.addSortCondition( SimpleElementFactory.getInstance().createSortCondition(sortKey)); } ": Wrapped <br />
org.eclipse.birt.report.model.api.metadata.PropertyValueException: The value of the property "Sort Key" is required. (/report/body/table[
@id="
;10"]/method[
@name="
;onPrepare"]#22) <br />
at org.eclipse.birt.report.engine.javascript.JavascriptEngine.evaluate(JavascriptEngine.java:295) at org.eclipse.birt.core.script.ScriptContext.evaluate(ScriptContext.java:154) at <br />
org.eclipse.birt.report.engine.executor.ExecutionContext.evaluate(ExecutionContext.java:781) at <br />
org.eclipse.birt.report.engine.executor.ExecutionContext.evaluate(ExecutionContext.java:761) at <br />
org.eclipse.birt.report.engine.executor.ExecutionContext.evaluate(ExecutionContext.java:743) at <br />
org.eclipse.birt.report.engine.api.impl.ScriptedDesignHandler.processOnPrepareScript(ScriptedDesignHandler.java:259) ... 60 more Caused by: <br />
org.mozilla.javascript.WrappedException: Wrapped org.eclipse.birt.report.model.api.metadata.PropertyValueException: The value of the property "Sort Key" is required. (/report/body/<br />
table[
@id="
;10"]/method[
@name="
;onPrepare"]#22) at org.mozilla.javascript.Context.throwAsScriptRuntimeEx(Context.java:1773) at <br />
org.mozilla.javascript.MemberBox.invoke(MemberBox.java:183) at org.mozilla.javascript.NativeJavaMethod.call(NativeJavaMethod.java:247) at <br />
org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:66) at org.mozilla.javascript.gen.c597._c0(/report/body/table[
@id="
;10"]/method[
@name="
;onPrepare"]:22) at <br />
org.mozilla.javascript.gen.c597.call(/report/body/table[
@id="
;10"]/method[
@name="
;onPrepare"]) at org.mozilla.javascript.ContextFactory.doTopCall(ContextFactory.java:398) at <br />
org.mozilla.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:3065) at org.mozilla.javascript.gen.c597.call(/report/body/table[
@id="
;10"]/method[
@name="
;onPrepare"]) at <br />
org.mozilla.javascript.gen.c597.exec(/report/body/table[
@id="
;10"]/method[
@name="
;onPrepare"]) at <br />
org.eclipse.birt.report.engine.javascript.JavascriptEngine.evaluate(JavascriptEngine.java:290) ... 65 more Caused by: <br />
org.eclipse.birt.report.model.api.metadata.PropertyValueException: The value of the property "Sort Key" is required. at <br />
org.eclipse.birt.report.model.api.elements.structures.SortKey.validate(SortKey.java:345) at <br />
org.eclipse.birt.report.model.command.AbstractPropertyCommand.checkItem(AbstractPropertyCommand.java:259) at <br />
org.eclipse.birt.report.model.command.AbstractPropertyCommand.checkItem(AbstractPropertyCommand.java:115) at <br />
org.eclipse.birt.report.model.command.ComplexPropertyCommand.addItem(ComplexPropertyCommand.java:106) at <br />
org.eclipse.birt.report.model.command.ComplexPropertyCommand.addItem(ComplexPropertyCommand.java:165) at <br />
org.eclipse.birt.report.model.api.SimpleValueHandle.addItem(SimpleValueHandle.java:562) at org.eclipse.birt.report.model.simpleapi.MultiRowItem.addSortCondition(MultiRowItem.java:<br />
163) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at <br />
sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.mozilla.javascript.MemberBox.invoke(MemberBox.java:<br />
161) ... 74 more<br />
<br />
Thanks in advance
mwilliams
Hi hmca,
Can you recreate this with a sample report, using the sample database, so I can see everything you're doing and test on your report? Thanks!
hmca
hai williams,
thanks for your Reply.
I just recreate the design . its working fine(Sorting Asc,desc) in Preview,but in browser initial page was loaded properly while clicking the Column header for sorting, i got the following error.
- There is no report design object available.
org.eclipse.birt.report.exception.ViewerException: There is no report design object available.
at org.eclipse.birt.report.context.ViewerAttributeBean.__init(ViewerAttributeBean.java:226)
at org.eclipse.birt.report.context.BaseAttributeBean.init(BaseAttributeBean.java:233)
at org.eclipse.birt.report.context.ViewerAttributeBean.<init>(ViewerAttributeBean.java:118)
at org.eclipse.birt.report.context.BirtContext.__init(BirtContext.java:44)
at org.eclipse.birt.report.context.BaseContext.<init>(BaseContext.java:69)
at org.eclipse.birt.report.context.BirtContext.<init>(BirtContext.java:30)
at org.eclipse.birt.report.servlet.ViewerServlet.__getContext(ViewerServlet.java:150)
at org.eclipse.birt.report.servlet.BirtSoapMessageDispatcherServlet.doGet(BirtSoapMessageDispatcherServlet.java:151)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
at org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:327)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at org.eclipse.birt.report.servlet.BirtSoapMessageDispatcherServlet.service(BirtSoapMessageDispatcherServlet.java:122)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.eclipse.birt.report.filter.ViewerFilter.doFilter(ViewerFilter.java:68)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
at java.lang.Thread.run(Unknown Source)
thanks..
mwilliams
This is when deployed to jboss?