私のmdxクエリを実行している間にこのエラーが発生しました。このエラーは本当に理解できません。キューブを何度も繰り返しましたが、私はまだこのエラーが発生します!java.lang.Integerはjava.lang.String例外にキャストできません
Warning: Could not get charToByteConverterClass!
Warning: Could not get charToByteConverterClass!
Warning: Could not get charToByteConverterClass!
Warning: Could not get charToByteConverterClass!
Warning: Could not get charToByteConverterClass!
Warning: Could not get charToByteConverterClass!
Warning: Could not get charToByteConverterClass!
[JPivot] 21 apr 2017 16:48:13,861 ERROR [Session 08BEA8C58E687AE8F99184BC19FA07A1] com.tonbeller.wcf.component.RendererTag#doEndTag: trouble rendering table01
java.lang.ClassCastException: java.lang.Integer cannot be cast to java.lang.String
at mondrian.rolap.RolapMemberBase.getName(RolapMemberBase.java:233)
at mondrian.olap.OlapElementBase.getCaption(OlapElementBase.java:84)
at mondrian.olap.MemberBase.getCaption(MemberBase.java:108)
at mondrian.rolap.DelegatingRolapMember.getCaption(DelegatingRolapMember.java:176)
at com.tonbeller.jpivot.mondrian.MondrianMember.getLabel(MondrianMember.java:79)
at com.tonbeller.jpivot.table.SpanBuilderImpl$RenderSwitch.visitMember(SpanBuilderImpl.java:111)
at com.tonbeller.jpivot.mondrian.MondrianMember.accept(MondrianMember.java:161)
at com.tonbeller.jpivot.table.SpanBuilderImpl.build(SpanBuilderImpl.java:142)
at com.tonbeller.jpivot.table.SpanBuilderDecorator.build(SpanBuilderDecorator.java:34)
at com.tonbeller.jpivot.table.navi.DrillExpandUI$DomDecorator.build(DrillExpandUI.java:81)
at com.tonbeller.jpivot.table.SpanBuilderDecorator.build(SpanBuilderDecorator.java:34)
at com.tonbeller.jpivot.table.navi.DrillExpandUI$DomDecorator.build(DrillExpandUI.java:81)
at com.tonbeller.jpivot.table.SpanBuilderDecorator.build(SpanBuilderDecorator.java:34)
at com.tonbeller.jpivot.table.navi.DrillExpandUI$DomDecorator.build(DrillExpandUI.java:81)
at com.tonbeller.jpivot.table.AxisHeaderBuilderSupport.build(AxisHeaderBuilderSupport.java:63)
at com.tonbeller.jpivot.table.AxisBuilderSupport.buildHeading(AxisBuilderSupport.java:253)
at com.tonbeller.jpivot.table.RowAxisBuilderImpl.buildRow(RowAxisBuilderImpl.java:51)
at com.tonbeller.jpivot.table.TableComponent.buildRows2Dim(TableComponent.java:490)
at com.tonbeller.jpivot.table.TableComponent.render2(TableComponent.java:274)
at com.tonbeller.jpivot.table.TableComponent.render(TableComponent.java:235)
at com.tonbeller.wcf.component.RendererTag.doEndTag(RendererTag.java:137)
at org.apache.jsp.testpage_jsp._jspx_meth_wcf_005frender_005f6(testpage_jsp.java:1398)
at org.apache.jsp.testpage_jsp._jspService(testpage_jsp.java:238)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:728)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:728)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at com.tonbeller.wcf.controller.RequestFilter$MyHandler.normalRequest(RequestFilter.java:139)
at com.tonbeller.wcf.controller.RequestFilter.doFilter(RequestFilter.java:264)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:222)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:123)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:502)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:171)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:99)
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:953)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:408)
at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1023)
at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:589)
at org.apache.tomcat.util.net.AprEndpoint$SocketProcessor.run(AprEndpoint.java:1852)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
[JPivot] 21 apr 2017 16:48:13,956 ERROR [Session 08BEA8C58E687AE8F99184BC19FA07A1] com.tonbeller.wcf.controller.RequestFilter$MyHandler#handleException: exeption
org.apache.jasper.JasperException: javax.servlet.ServletException: javax.servlet.jsp.JspException: java.lang.ClassCastException: java.lang.Integer cannot be cast to java.lang.String
at org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:549)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:455)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:728)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at com.tonbeller.wcf.controller.RequestFilter$MyHandler.normalRequest(RequestFilter.java:139)
at com.tonbeller.wcf.controller.RequestFilter.doFilter(RequestFilter.java:264)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:222)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:123)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:502)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:171)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:99)
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:953)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:408)
at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1023)
at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:589)
at org.apache.tomcat.util.net.AprEndpoint$SocketProcessor.run(AprEndpoint.java:1852)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Caused by: javax.servlet.ServletException: javax.servlet.jsp.JspException: java.lang.ClassCastException: java.lang.Integer cannot be cast to java.lang.String
at org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:908)
at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:841)
at org.apache.jsp.testpage_jsp._jspService(testpage_jsp.java:272)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:728)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)
... 23 more
Caused by: java.lang.ClassCastException: java.lang.Integer cannot be cast to java.lang.String
at mondrian.rolap.RolapMemberBase.getName(RolapMemberBase.java:233)
at mondrian.olap.OlapElementBase.getCaption(OlapElementBase.java:84)
at mondrian.olap.MemberBase.getCaption(MemberBase.java:108)
at mondrian.rolap.DelegatingRolapMember.getCaption(DelegatingRolapMember.java:176)
at com.tonbeller.jpivot.mondrian.MondrianMember.getLabel(MondrianMember.java:79)
at com.tonbeller.jpivot.table.SpanBuilderImpl$RenderSwitch.visitMember(SpanBuilderImpl.java:111)
at com.tonbeller.jpivot.mondrian.MondrianMember.accept(MondrianMember.java:161)
at com.tonbeller.jpivot.table.SpanBuilderImpl.build(SpanBuilderImpl.java:142)
at com.tonbeller.jpivot.table.SpanBuilderDecorator.build(SpanBuilderDecorator.java:34)
at com.tonbeller.jpivot.table.navi.DrillExpandUI$DomDecorator.build(DrillExpandUI.java:81)
at com.tonbeller.jpivot.table.SpanBuilderDecorator.build(SpanBuilderDecorator.java:34)
at com.tonbeller.jpivot.table.navi.DrillExpandUI$DomDecorator.build(DrillExpandUI.java:81)
at com.tonbeller.jpivot.table.SpanBuilderDecorator.build(SpanBuilderDecorator.java:34)
at com.tonbeller.jpivot.table.navi.DrillExpandUI$DomDecorator.build(DrillExpandUI.java:81)
at com.tonbeller.jpivot.table.AxisHeaderBuilderSupport.build(AxisHeaderBuilderSupport.java:63)
at com.tonbeller.jpivot.table.AxisBuilderSupport.buildHeading(AxisBuilderSupport.java:253)
at com.tonbeller.jpivot.table.RowAxisBuilderImpl.buildRow(RowAxisBuilderImpl.java:51)
at com.tonbeller.jpivot.table.TableComponent.buildRows2Dim(TableComponent.java:490)
at com.tonbeller.jpivot.table.TableComponent.render2(TableComponent.java:274)
at com.tonbeller.jpivot.table.TableComponent.render(TableComponent.java:235)
at com.tonbeller.wcf.component.RendererTag.doEndTag(RendererTag.java:137)
at org.apache.jsp.testpage_jsp._jspx_meth_wcf_005frender_005f6(testpage_jsp.java:1398)
at org.apache.jsp.testpage_jsp._jspService(testpage_jsp.java:238)
... 26 more
[JPivot] 21 apr 2017 16:48:14,081 ERROR [Session 08BEA8C58E687AE8F99184BC19FA07A1] com.tonbeller.wcf.controller.RequestFilter$MyHandler#handleException: cause
javax.servlet.ServletException: javax.servlet.jsp.JspException: java.lang.ClassCastException: java.lang.Integer cannot be cast to java.lang.String
at org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:908)
at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:841)
at org.apache.jsp.testpage_jsp._jspService(testpage_jsp.java:272)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:728)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:728)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at com.tonbeller.wcf.controller.RequestFilter$MyHandler.normalRequest(RequestFilter.java:139)
at com.tonbeller.wcf.controller.RequestFilter.doFilter(RequestFilter.java:264)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:222)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:123)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:502)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:171)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:99)
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:953)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:408)
at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1023)
at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:589)
at org.apache.tomcat.util.net.AprEndpoint$SocketProcessor.run(AprEndpoint.java:1852)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Caused by: java.lang.ClassCastException: java.lang.Integer cannot be cast to java.lang.String
at mondrian.rolap.RolapMemberBase.getName(RolapMemberBase.java:233)
at mondrian.olap.OlapElementBase.getCaption(OlapElementBase.java:84)
at mondrian.olap.MemberBase.getCaption(MemberBase.java:108)
at mondrian.rolap.DelegatingRolapMember.getCaption(DelegatingRolapMember.java:176)
at com.tonbeller.jpivot.mondrian.MondrianMember.getLabel(MondrianMember.java:79)
at com.tonbeller.jpivot.table.SpanBuilderImpl$RenderSwitch.visitMember(SpanBuilderImpl.java:111)
at com.tonbeller.jpivot.mondrian.MondrianMember.accept(MondrianMember.java:161)
at com.tonbeller.jpivot.table.SpanBuilderImpl.build(SpanBuilderImpl.java:142)
at com.tonbeller.jpivot.table.SpanBuilderDecorator.build(SpanBuilderDecorator.java:34)
at com.tonbeller.jpivot.table.navi.DrillExpandUI$DomDecorator.build(DrillExpandUI.java:81)
at com.tonbeller.jpivot.table.SpanBuilderDecorator.build(SpanBuilderDecorator.java:34)
at com.tonbeller.jpivot.table.navi.DrillExpandUI$DomDecorator.build(DrillExpandUI.java:81)
at com.tonbeller.jpivot.table.SpanBuilderDecorator.build(SpanBuilderDecorator.java:34)
at com.tonbeller.jpivot.table.navi.DrillExpandUI$DomDecorator.build(DrillExpandUI.java:81)
at com.tonbeller.jpivot.table.AxisHeaderBuilderSupport.build(AxisHeaderBuilderSupport.java:63)
at com.tonbeller.jpivot.table.AxisBuilderSupport.buildHeading(AxisBuilderSupport.java:253)
at com.tonbeller.jpivot.table.RowAxisBuilderImpl.buildRow(RowAxisBuilderImpl.java:51)
at com.tonbeller.jpivot.table.TableComponent.buildRows2Dim(TableComponent.java:490)
at com.tonbeller.jpivot.table.TableComponent.render2(TableComponent.java:274)
at com.tonbeller.jpivot.table.TableComponent.render(TableComponent.java:235)
at com.tonbeller.wcf.component.RendererTag.doEndTag(RendererTag.java:137)
at org.apache.jsp.testpage_jsp._jspx_meth_wcf_005frender_005f6(testpage_jsp.java:1398)
at org.apache.jsp.testpage_jsp._jspService(testpage_jsp.java:238)
... 26 more
これはクエリです: これは完全な誤りである
SELECT {[Measures].[quantita_media], [Measures].[quantita_totale]} ON
COLUMNS,
{([Periodo], [Articolo], [ScontrinoFiscale])} ON ROWS
FROM [Vendite]
これは、PostgreSQLのスキーマです:
CREATE TABLE data_dt (
data character varying(10) NOT NULL,
giorno character varying(10) NOT NULL,
mese character varying(10) NOT NULL,
anno character varying(4) NOT NULL
);
CREATE TABLE prodotto_dt (
nome character varying(30) NOT NULL,
descrizione character varying(30) NOT NULL
);
CREATE TABLE scontrino_dt (
codice integer NOT NULL,
totale integer NOT NULL
);
CREATE TABLE vendita_ft (
data character varying(10) NOT NULL,
nome character varying(30) NOT NULL,
codice integer NOT NULL,
quantita integer NOT NULL
);
ALTER TABLE ONLY data_dt
ADD CONSTRAINT data_dt_pkey PRIMARY KEY (data);
ALTER TABLE ONLY prodotto_dt
ADD CONSTRAINT prodotto_dt_pkey PRIMARY KEY (nome);
ALTER TABLE ONLY scontrino_dt
ADD CONSTRAINT scontrino_dt_pkey PRIMARY KEY (codice);
ALTER TABLE ONLY vendita_ft
ADD CONSTRAINT vendita_ft_pkey PRIMARY KEY (data, nome, codice);
ALTER TABLE ONLY vendita_ft
ADD CONSTRAINT vendita_ft_codice_fkey FOREIGN KEY (codice) REFERENCES scontrino_dt(codice);
ALTER TABLE ONLY vendita_ft
ADD CONSTRAINT vendita_ft_data_fkey FOREIGN KEY (data) REFERENCES data_dt(data);
ALTER TABLE ONLY vendita_ft
ADD CONSTRAINT vendita_ft_nome_fkey FOREIGN KEY (nome) REFERENCES prodotto_dt(nome);
、これは、スキーマワークベンチによって生成された私のxmlキューブです:
<Schema name="New Schema1">
<Cube name="Vendite" cache="true" enabled="true">
<Table name="vendita_ft" schema="public">
</Table>
<Dimension type="StandardDimension" foreignKey="data" highCardinality="false" name="Periodo">
<Hierarchy name="tempo" hasAll="true">
<Table name="data_dt" schema="public">
</Table>
<Level name="giorno" table="data_dt" column="giorno" nameColumn="giorno" type="String" uniqueMembers="false" levelType="Regular" hideMemberIf="Never">
</Level>
<Level name="mese" table="data_dt" column="mese" nameColumn="mese" type="String" uniqueMembers="false" levelType="Regular" hideMemberIf="Never">
</Level>
<Level name="anno" table="data_dt" column="anno" nameColumn="anno" type="String" uniqueMembers="false" levelType="Regular" hideMemberIf="Never">
</Level>
</Hierarchy>
</Dimension>
<Dimension type="StandardDimension" foreignKey="nome" highCardinality="false" name="Articolo">
<Hierarchy name="prodotto" hasAll="true">
<Table name="prodotto_dt" schema="public">
</Table>
<Level name="nome" table="prodotto_dt" column="nome" nameColumn="nome" type="String" uniqueMembers="false" levelType="Regular" hideMemberIf="Never">
</Level>
<Level name="descrizione" table="prodotto_dt" column="descrizione" nameColumn="descrizione" type="String" uniqueMembers="false" levelType="Regular" hideMemberIf="Never">
</Level>
</Hierarchy>
</Dimension>
<Dimension type="StandardDimension" foreignKey="codice" highCardinality="false" name="ScontrinoFiscale">
<Hierarchy name="scontrino" hasAll="true">
<Table name="scontrino_dt" schema="public">
</Table>
<Level name="codice" table="scontrino_dt" column="codice" nameColumn="codice" type="String" uniqueMembers="false" levelType="Regular" hideMemberIf="Never">
</Level>
<Level name="totale" table="scontrino_dt" column="totale" nameColumn="totale" type="Integer" uniqueMembers="false" levelType="Regular" hideMemberIf="Never">
</Level>
</Hierarchy>
</Dimension>
<Measure name="quantita_media" column="quantita" aggregator="avg" visible="true">
</Measure>
<Measure name="quantita_totale" column="quantita" datatype="Integer" aggregator="sum" visible="true">
</Measure>
</Cube>
</Schema>
はい、これは並べ替えようとしてエラーが発生しましたが、残念ながらこれは問題ではありません。 Integer @DiabolicWords – Nicola